{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.AlexaBusiness.ResolveRoom
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Determines the details for the room from which a skill request was
-- invoked. This operation is used by skill developers.
--
-- To query ResolveRoom from an Alexa skill, the skill ID needs to be
-- authorized. When the skill is using an AWS Lambda function, the skill is
-- automatically authorized when you publish your skill as a private skill
-- to your AWS account. Skills that are hosted using a custom web service
-- must be manually authorized. To get your skill authorized, contact AWS
-- Support with your AWS account ID that queries the ResolveRoom API and
-- skill ID.
module Amazonka.AlexaBusiness.ResolveRoom
  ( -- * Creating a Request
    ResolveRoom (..),
    newResolveRoom,

    -- * Request Lenses
    resolveRoom_userId,
    resolveRoom_skillId,

    -- * Destructuring the Response
    ResolveRoomResponse (..),
    newResolveRoomResponse,

    -- * Response Lenses
    resolveRoomResponse_roomSkillParameters,
    resolveRoomResponse_roomArn,
    resolveRoomResponse_roomName,
    resolveRoomResponse_httpStatus,
  )
where

import Amazonka.AlexaBusiness.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newResolveRoom' smart constructor.
data ResolveRoom = ResolveRoom'
  { -- | The ARN of the user. Required.
    ResolveRoom -> Text
userId :: Prelude.Text,
    -- | The ARN of the skill that was requested. Required.
    ResolveRoom -> Text
skillId :: Prelude.Text
  }
  deriving (ResolveRoom -> ResolveRoom -> Bool
(ResolveRoom -> ResolveRoom -> Bool)
-> (ResolveRoom -> ResolveRoom -> Bool) -> Eq ResolveRoom
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ResolveRoom -> ResolveRoom -> Bool
$c/= :: ResolveRoom -> ResolveRoom -> Bool
== :: ResolveRoom -> ResolveRoom -> Bool
$c== :: ResolveRoom -> ResolveRoom -> Bool
Prelude.Eq, ReadPrec [ResolveRoom]
ReadPrec ResolveRoom
Int -> ReadS ResolveRoom
ReadS [ResolveRoom]
(Int -> ReadS ResolveRoom)
-> ReadS [ResolveRoom]
-> ReadPrec ResolveRoom
-> ReadPrec [ResolveRoom]
-> Read ResolveRoom
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ResolveRoom]
$creadListPrec :: ReadPrec [ResolveRoom]
readPrec :: ReadPrec ResolveRoom
$creadPrec :: ReadPrec ResolveRoom
readList :: ReadS [ResolveRoom]
$creadList :: ReadS [ResolveRoom]
readsPrec :: Int -> ReadS ResolveRoom
$creadsPrec :: Int -> ReadS ResolveRoom
Prelude.Read, Int -> ResolveRoom -> ShowS
[ResolveRoom] -> ShowS
ResolveRoom -> String
(Int -> ResolveRoom -> ShowS)
-> (ResolveRoom -> String)
-> ([ResolveRoom] -> ShowS)
-> Show ResolveRoom
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ResolveRoom] -> ShowS
$cshowList :: [ResolveRoom] -> ShowS
show :: ResolveRoom -> String
$cshow :: ResolveRoom -> String
showsPrec :: Int -> ResolveRoom -> ShowS
$cshowsPrec :: Int -> ResolveRoom -> ShowS
Prelude.Show, (forall x. ResolveRoom -> Rep ResolveRoom x)
-> (forall x. Rep ResolveRoom x -> ResolveRoom)
-> Generic ResolveRoom
forall x. Rep ResolveRoom x -> ResolveRoom
forall x. ResolveRoom -> Rep ResolveRoom x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ResolveRoom x -> ResolveRoom
$cfrom :: forall x. ResolveRoom -> Rep ResolveRoom x
Prelude.Generic)

-- |
-- Create a value of 'ResolveRoom' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'userId', 'resolveRoom_userId' - The ARN of the user. Required.
--
-- 'skillId', 'resolveRoom_skillId' - The ARN of the skill that was requested. Required.
newResolveRoom ::
  -- | 'userId'
  Prelude.Text ->
  -- | 'skillId'
  Prelude.Text ->
  ResolveRoom
newResolveRoom :: Text -> Text -> ResolveRoom
newResolveRoom Text
pUserId_ Text
pSkillId_ =
  ResolveRoom' :: Text -> Text -> ResolveRoom
ResolveRoom'
    { $sel:userId:ResolveRoom' :: Text
userId = Text
pUserId_,
      $sel:skillId:ResolveRoom' :: Text
skillId = Text
pSkillId_
    }

-- | The ARN of the user. Required.
resolveRoom_userId :: Lens.Lens' ResolveRoom Prelude.Text
resolveRoom_userId :: (Text -> f Text) -> ResolveRoom -> f ResolveRoom
resolveRoom_userId = (ResolveRoom -> Text)
-> (ResolveRoom -> Text -> ResolveRoom)
-> Lens ResolveRoom ResolveRoom Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoom' {Text
userId :: Text
$sel:userId:ResolveRoom' :: ResolveRoom -> Text
userId} -> Text
userId) (\s :: ResolveRoom
s@ResolveRoom' {} Text
a -> ResolveRoom
s {$sel:userId:ResolveRoom' :: Text
userId = Text
a} :: ResolveRoom)

-- | The ARN of the skill that was requested. Required.
resolveRoom_skillId :: Lens.Lens' ResolveRoom Prelude.Text
resolveRoom_skillId :: (Text -> f Text) -> ResolveRoom -> f ResolveRoom
resolveRoom_skillId = (ResolveRoom -> Text)
-> (ResolveRoom -> Text -> ResolveRoom)
-> Lens ResolveRoom ResolveRoom Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoom' {Text
skillId :: Text
$sel:skillId:ResolveRoom' :: ResolveRoom -> Text
skillId} -> Text
skillId) (\s :: ResolveRoom
s@ResolveRoom' {} Text
a -> ResolveRoom
s {$sel:skillId:ResolveRoom' :: Text
skillId = Text
a} :: ResolveRoom)

instance Core.AWSRequest ResolveRoom where
  type AWSResponse ResolveRoom = ResolveRoomResponse
  request :: ResolveRoom -> Request ResolveRoom
request = Service -> ResolveRoom -> Request ResolveRoom
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy ResolveRoom
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ResolveRoom)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse ResolveRoom))
-> Logger
-> Service
-> Proxy ResolveRoom
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ResolveRoom)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe [RoomSkillParameter]
-> Maybe Text -> Maybe Text -> Int -> ResolveRoomResponse
ResolveRoomResponse'
            (Maybe [RoomSkillParameter]
 -> Maybe Text -> Maybe Text -> Int -> ResolveRoomResponse)
-> Either String (Maybe [RoomSkillParameter])
-> Either
     String (Maybe Text -> Maybe Text -> Int -> ResolveRoomResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object
-> Text -> Either String (Maybe (Maybe [RoomSkillParameter]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RoomSkillParameters"
                            Either String (Maybe (Maybe [RoomSkillParameter]))
-> Maybe [RoomSkillParameter]
-> Either String (Maybe [RoomSkillParameter])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [RoomSkillParameter]
forall a. Monoid a => a
Prelude.mempty
                        )
            Either
  String (Maybe Text -> Maybe Text -> Int -> ResolveRoomResponse)
-> Either String (Maybe Text)
-> Either String (Maybe Text -> Int -> ResolveRoomResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RoomArn")
            Either String (Maybe Text -> Int -> ResolveRoomResponse)
-> Either String (Maybe Text)
-> Either String (Int -> ResolveRoomResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RoomName")
            Either String (Int -> ResolveRoomResponse)
-> Either String Int -> Either String ResolveRoomResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable ResolveRoom

instance Prelude.NFData ResolveRoom

instance Core.ToHeaders ResolveRoom where
  toHeaders :: ResolveRoom -> ResponseHeaders
toHeaders =
    ResponseHeaders -> ResolveRoom -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AlexaForBusiness.ResolveRoom" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON ResolveRoom where
  toJSON :: ResolveRoom -> Value
toJSON ResolveRoom' {Text
skillId :: Text
userId :: Text
$sel:skillId:ResolveRoom' :: ResolveRoom -> Text
$sel:userId:ResolveRoom' :: ResolveRoom -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"UserId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
userId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"SkillId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
skillId)
          ]
      )

instance Core.ToPath ResolveRoom where
  toPath :: ResolveRoom -> ByteString
toPath = ByteString -> ResolveRoom -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Core.ToQuery ResolveRoom where
  toQuery :: ResolveRoom -> QueryString
toQuery = QueryString -> ResolveRoom -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newResolveRoomResponse' smart constructor.
data ResolveRoomResponse = ResolveRoomResponse'
  { -- | Response to get the room profile request. Required.
    ResolveRoomResponse -> Maybe [RoomSkillParameter]
roomSkillParameters :: Prelude.Maybe [RoomSkillParameter],
    -- | The ARN of the room from which the skill request was invoked.
    ResolveRoomResponse -> Maybe Text
roomArn :: Prelude.Maybe Prelude.Text,
    -- | The name of the room from which the skill request was invoked.
    ResolveRoomResponse -> Maybe Text
roomName :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ResolveRoomResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ResolveRoomResponse -> ResolveRoomResponse -> Bool
(ResolveRoomResponse -> ResolveRoomResponse -> Bool)
-> (ResolveRoomResponse -> ResolveRoomResponse -> Bool)
-> Eq ResolveRoomResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ResolveRoomResponse -> ResolveRoomResponse -> Bool
$c/= :: ResolveRoomResponse -> ResolveRoomResponse -> Bool
== :: ResolveRoomResponse -> ResolveRoomResponse -> Bool
$c== :: ResolveRoomResponse -> ResolveRoomResponse -> Bool
Prelude.Eq, ReadPrec [ResolveRoomResponse]
ReadPrec ResolveRoomResponse
Int -> ReadS ResolveRoomResponse
ReadS [ResolveRoomResponse]
(Int -> ReadS ResolveRoomResponse)
-> ReadS [ResolveRoomResponse]
-> ReadPrec ResolveRoomResponse
-> ReadPrec [ResolveRoomResponse]
-> Read ResolveRoomResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ResolveRoomResponse]
$creadListPrec :: ReadPrec [ResolveRoomResponse]
readPrec :: ReadPrec ResolveRoomResponse
$creadPrec :: ReadPrec ResolveRoomResponse
readList :: ReadS [ResolveRoomResponse]
$creadList :: ReadS [ResolveRoomResponse]
readsPrec :: Int -> ReadS ResolveRoomResponse
$creadsPrec :: Int -> ReadS ResolveRoomResponse
Prelude.Read, Int -> ResolveRoomResponse -> ShowS
[ResolveRoomResponse] -> ShowS
ResolveRoomResponse -> String
(Int -> ResolveRoomResponse -> ShowS)
-> (ResolveRoomResponse -> String)
-> ([ResolveRoomResponse] -> ShowS)
-> Show ResolveRoomResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ResolveRoomResponse] -> ShowS
$cshowList :: [ResolveRoomResponse] -> ShowS
show :: ResolveRoomResponse -> String
$cshow :: ResolveRoomResponse -> String
showsPrec :: Int -> ResolveRoomResponse -> ShowS
$cshowsPrec :: Int -> ResolveRoomResponse -> ShowS
Prelude.Show, (forall x. ResolveRoomResponse -> Rep ResolveRoomResponse x)
-> (forall x. Rep ResolveRoomResponse x -> ResolveRoomResponse)
-> Generic ResolveRoomResponse
forall x. Rep ResolveRoomResponse x -> ResolveRoomResponse
forall x. ResolveRoomResponse -> Rep ResolveRoomResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ResolveRoomResponse x -> ResolveRoomResponse
$cfrom :: forall x. ResolveRoomResponse -> Rep ResolveRoomResponse x
Prelude.Generic)

-- |
-- Create a value of 'ResolveRoomResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'roomSkillParameters', 'resolveRoomResponse_roomSkillParameters' - Response to get the room profile request. Required.
--
-- 'roomArn', 'resolveRoomResponse_roomArn' - The ARN of the room from which the skill request was invoked.
--
-- 'roomName', 'resolveRoomResponse_roomName' - The name of the room from which the skill request was invoked.
--
-- 'httpStatus', 'resolveRoomResponse_httpStatus' - The response's http status code.
newResolveRoomResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ResolveRoomResponse
newResolveRoomResponse :: Int -> ResolveRoomResponse
newResolveRoomResponse Int
pHttpStatus_ =
  ResolveRoomResponse' :: Maybe [RoomSkillParameter]
-> Maybe Text -> Maybe Text -> Int -> ResolveRoomResponse
ResolveRoomResponse'
    { $sel:roomSkillParameters:ResolveRoomResponse' :: Maybe [RoomSkillParameter]
roomSkillParameters =
        Maybe [RoomSkillParameter]
forall a. Maybe a
Prelude.Nothing,
      $sel:roomArn:ResolveRoomResponse' :: Maybe Text
roomArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:roomName:ResolveRoomResponse' :: Maybe Text
roomName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ResolveRoomResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Response to get the room profile request. Required.
resolveRoomResponse_roomSkillParameters :: Lens.Lens' ResolveRoomResponse (Prelude.Maybe [RoomSkillParameter])
resolveRoomResponse_roomSkillParameters :: (Maybe [RoomSkillParameter] -> f (Maybe [RoomSkillParameter]))
-> ResolveRoomResponse -> f ResolveRoomResponse
resolveRoomResponse_roomSkillParameters = (ResolveRoomResponse -> Maybe [RoomSkillParameter])
-> (ResolveRoomResponse
    -> Maybe [RoomSkillParameter] -> ResolveRoomResponse)
-> Lens
     ResolveRoomResponse
     ResolveRoomResponse
     (Maybe [RoomSkillParameter])
     (Maybe [RoomSkillParameter])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoomResponse' {Maybe [RoomSkillParameter]
roomSkillParameters :: Maybe [RoomSkillParameter]
$sel:roomSkillParameters:ResolveRoomResponse' :: ResolveRoomResponse -> Maybe [RoomSkillParameter]
roomSkillParameters} -> Maybe [RoomSkillParameter]
roomSkillParameters) (\s :: ResolveRoomResponse
s@ResolveRoomResponse' {} Maybe [RoomSkillParameter]
a -> ResolveRoomResponse
s {$sel:roomSkillParameters:ResolveRoomResponse' :: Maybe [RoomSkillParameter]
roomSkillParameters = Maybe [RoomSkillParameter]
a} :: ResolveRoomResponse) ((Maybe [RoomSkillParameter] -> f (Maybe [RoomSkillParameter]))
 -> ResolveRoomResponse -> f ResolveRoomResponse)
-> ((Maybe [RoomSkillParameter] -> f (Maybe [RoomSkillParameter]))
    -> Maybe [RoomSkillParameter] -> f (Maybe [RoomSkillParameter]))
-> (Maybe [RoomSkillParameter] -> f (Maybe [RoomSkillParameter]))
-> ResolveRoomResponse
-> f ResolveRoomResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [RoomSkillParameter]
  [RoomSkillParameter]
  [RoomSkillParameter]
  [RoomSkillParameter]
-> Iso
     (Maybe [RoomSkillParameter])
     (Maybe [RoomSkillParameter])
     (Maybe [RoomSkillParameter])
     (Maybe [RoomSkillParameter])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [RoomSkillParameter]
  [RoomSkillParameter]
  [RoomSkillParameter]
  [RoomSkillParameter]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ARN of the room from which the skill request was invoked.
resolveRoomResponse_roomArn :: Lens.Lens' ResolveRoomResponse (Prelude.Maybe Prelude.Text)
resolveRoomResponse_roomArn :: (Maybe Text -> f (Maybe Text))
-> ResolveRoomResponse -> f ResolveRoomResponse
resolveRoomResponse_roomArn = (ResolveRoomResponse -> Maybe Text)
-> (ResolveRoomResponse -> Maybe Text -> ResolveRoomResponse)
-> Lens
     ResolveRoomResponse ResolveRoomResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoomResponse' {Maybe Text
roomArn :: Maybe Text
$sel:roomArn:ResolveRoomResponse' :: ResolveRoomResponse -> Maybe Text
roomArn} -> Maybe Text
roomArn) (\s :: ResolveRoomResponse
s@ResolveRoomResponse' {} Maybe Text
a -> ResolveRoomResponse
s {$sel:roomArn:ResolveRoomResponse' :: Maybe Text
roomArn = Maybe Text
a} :: ResolveRoomResponse)

-- | The name of the room from which the skill request was invoked.
resolveRoomResponse_roomName :: Lens.Lens' ResolveRoomResponse (Prelude.Maybe Prelude.Text)
resolveRoomResponse_roomName :: (Maybe Text -> f (Maybe Text))
-> ResolveRoomResponse -> f ResolveRoomResponse
resolveRoomResponse_roomName = (ResolveRoomResponse -> Maybe Text)
-> (ResolveRoomResponse -> Maybe Text -> ResolveRoomResponse)
-> Lens
     ResolveRoomResponse ResolveRoomResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoomResponse' {Maybe Text
roomName :: Maybe Text
$sel:roomName:ResolveRoomResponse' :: ResolveRoomResponse -> Maybe Text
roomName} -> Maybe Text
roomName) (\s :: ResolveRoomResponse
s@ResolveRoomResponse' {} Maybe Text
a -> ResolveRoomResponse
s {$sel:roomName:ResolveRoomResponse' :: Maybe Text
roomName = Maybe Text
a} :: ResolveRoomResponse)

-- | The response's http status code.
resolveRoomResponse_httpStatus :: Lens.Lens' ResolveRoomResponse Prelude.Int
resolveRoomResponse_httpStatus :: (Int -> f Int) -> ResolveRoomResponse -> f ResolveRoomResponse
resolveRoomResponse_httpStatus = (ResolveRoomResponse -> Int)
-> (ResolveRoomResponse -> Int -> ResolveRoomResponse)
-> Lens ResolveRoomResponse ResolveRoomResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResolveRoomResponse' {Int
httpStatus :: Int
$sel:httpStatus:ResolveRoomResponse' :: ResolveRoomResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ResolveRoomResponse
s@ResolveRoomResponse' {} Int
a -> ResolveRoomResponse
s {$sel:httpStatus:ResolveRoomResponse' :: Int
httpStatus = Int
a} :: ResolveRoomResponse)

instance Prelude.NFData ResolveRoomResponse