{-# 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 #-}
module Amazonka.LexRuntime.GetSession
(
GetSession (..),
newGetSession,
getSession_checkpointLabelFilter,
getSession_botName,
getSession_botAlias,
getSession_userId,
GetSessionResponse (..),
newGetSessionResponse,
getSessionResponse_activeContexts,
getSessionResponse_sessionId,
getSessionResponse_recentIntentSummaryView,
getSessionResponse_dialogAction,
getSessionResponse_sessionAttributes,
getSessionResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.LexRuntime.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data GetSession = GetSession'
{
GetSession -> Maybe Text
checkpointLabelFilter :: Prelude.Maybe Prelude.Text,
GetSession -> Text
botName :: Prelude.Text,
GetSession -> Text
botAlias :: Prelude.Text,
GetSession -> Text
userId :: Prelude.Text
}
deriving (GetSession -> GetSession -> Bool
(GetSession -> GetSession -> Bool)
-> (GetSession -> GetSession -> Bool) -> Eq GetSession
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetSession -> GetSession -> Bool
$c/= :: GetSession -> GetSession -> Bool
== :: GetSession -> GetSession -> Bool
$c== :: GetSession -> GetSession -> Bool
Prelude.Eq, ReadPrec [GetSession]
ReadPrec GetSession
Int -> ReadS GetSession
ReadS [GetSession]
(Int -> ReadS GetSession)
-> ReadS [GetSession]
-> ReadPrec GetSession
-> ReadPrec [GetSession]
-> Read GetSession
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetSession]
$creadListPrec :: ReadPrec [GetSession]
readPrec :: ReadPrec GetSession
$creadPrec :: ReadPrec GetSession
readList :: ReadS [GetSession]
$creadList :: ReadS [GetSession]
readsPrec :: Int -> ReadS GetSession
$creadsPrec :: Int -> ReadS GetSession
Prelude.Read, Int -> GetSession -> ShowS
[GetSession] -> ShowS
GetSession -> String
(Int -> GetSession -> ShowS)
-> (GetSession -> String)
-> ([GetSession] -> ShowS)
-> Show GetSession
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetSession] -> ShowS
$cshowList :: [GetSession] -> ShowS
show :: GetSession -> String
$cshow :: GetSession -> String
showsPrec :: Int -> GetSession -> ShowS
$cshowsPrec :: Int -> GetSession -> ShowS
Prelude.Show, (forall x. GetSession -> Rep GetSession x)
-> (forall x. Rep GetSession x -> GetSession) -> Generic GetSession
forall x. Rep GetSession x -> GetSession
forall x. GetSession -> Rep GetSession x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetSession x -> GetSession
$cfrom :: forall x. GetSession -> Rep GetSession x
Prelude.Generic)
newGetSession ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
GetSession
newGetSession :: Text -> Text -> Text -> GetSession
newGetSession Text
pBotName_ Text
pBotAlias_ Text
pUserId_ =
GetSession' :: Maybe Text -> Text -> Text -> Text -> GetSession
GetSession'
{ $sel:checkpointLabelFilter:GetSession' :: Maybe Text
checkpointLabelFilter =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:botName:GetSession' :: Text
botName = Text
pBotName_,
$sel:botAlias:GetSession' :: Text
botAlias = Text
pBotAlias_,
$sel:userId:GetSession' :: Text
userId = Text
pUserId_
}
getSession_checkpointLabelFilter :: Lens.Lens' GetSession (Prelude.Maybe Prelude.Text)
getSession_checkpointLabelFilter :: (Maybe Text -> f (Maybe Text)) -> GetSession -> f GetSession
getSession_checkpointLabelFilter = (GetSession -> Maybe Text)
-> (GetSession -> Maybe Text -> GetSession)
-> Lens GetSession GetSession (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSession' {Maybe Text
checkpointLabelFilter :: Maybe Text
$sel:checkpointLabelFilter:GetSession' :: GetSession -> Maybe Text
checkpointLabelFilter} -> Maybe Text
checkpointLabelFilter) (\s :: GetSession
s@GetSession' {} Maybe Text
a -> GetSession
s {$sel:checkpointLabelFilter:GetSession' :: Maybe Text
checkpointLabelFilter = Maybe Text
a} :: GetSession)
getSession_botName :: Lens.Lens' GetSession Prelude.Text
getSession_botName :: (Text -> f Text) -> GetSession -> f GetSession
getSession_botName = (GetSession -> Text)
-> (GetSession -> Text -> GetSession)
-> Lens GetSession GetSession Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSession' {Text
botName :: Text
$sel:botName:GetSession' :: GetSession -> Text
botName} -> Text
botName) (\s :: GetSession
s@GetSession' {} Text
a -> GetSession
s {$sel:botName:GetSession' :: Text
botName = Text
a} :: GetSession)
getSession_botAlias :: Lens.Lens' GetSession Prelude.Text
getSession_botAlias :: (Text -> f Text) -> GetSession -> f GetSession
getSession_botAlias = (GetSession -> Text)
-> (GetSession -> Text -> GetSession)
-> Lens GetSession GetSession Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSession' {Text
botAlias :: Text
$sel:botAlias:GetSession' :: GetSession -> Text
botAlias} -> Text
botAlias) (\s :: GetSession
s@GetSession' {} Text
a -> GetSession
s {$sel:botAlias:GetSession' :: Text
botAlias = Text
a} :: GetSession)
getSession_userId :: Lens.Lens' GetSession Prelude.Text
getSession_userId :: (Text -> f Text) -> GetSession -> f GetSession
getSession_userId = (GetSession -> Text)
-> (GetSession -> Text -> GetSession)
-> Lens GetSession GetSession Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSession' {Text
userId :: Text
$sel:userId:GetSession' :: GetSession -> Text
userId} -> Text
userId) (\s :: GetSession
s@GetSession' {} Text
a -> GetSession
s {$sel:userId:GetSession' :: Text
userId = Text
a} :: GetSession)
instance Core.AWSRequest GetSession where
type AWSResponse GetSession = GetSessionResponse
request :: GetSession -> Request GetSession
request = Service -> GetSession -> Request GetSession
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
response :: Logger
-> Service
-> Proxy GetSession
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetSession)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse GetSession))
-> Logger
-> Service
-> Proxy GetSession
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetSession)))
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 (Sensitive [ActiveContext])
-> Maybe Text
-> Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse
GetSessionResponse'
(Maybe (Sensitive [ActiveContext])
-> Maybe Text
-> Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
-> Either String (Maybe (Sensitive [ActiveContext]))
-> Either
String
(Maybe Text
-> Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object
-> Text
-> Either String (Maybe (Maybe (Sensitive [ActiveContext])))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"activeContexts" Either String (Maybe (Maybe (Sensitive [ActiveContext])))
-> Maybe (Sensitive [ActiveContext])
-> Either String (Maybe (Sensitive [ActiveContext]))
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe (Sensitive [ActiveContext])
forall a. Monoid a => a
Prelude.mempty)
Either
String
(Maybe Text
-> Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
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
"sessionId")
Either
String
(Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
-> Either String (Maybe [IntentSummary])
-> Either
String
(Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Either String (Maybe (Maybe [IntentSummary]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"recentIntentSummaryView"
Either String (Maybe (Maybe [IntentSummary]))
-> Maybe [IntentSummary] -> Either String (Maybe [IntentSummary])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [IntentSummary]
forall a. Monoid a => a
Prelude.mempty
)
Either
String
(Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse)
-> Either String (Maybe DialogAction)
-> Either
String
(Maybe (Sensitive (HashMap Text Text))
-> Int -> GetSessionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe DialogAction)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"dialogAction")
Either
String
(Maybe (Sensitive (HashMap Text Text))
-> Int -> GetSessionResponse)
-> Either String (Maybe (Sensitive (HashMap Text Text)))
-> Either String (Int -> GetSessionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Either String (Maybe (Maybe (Sensitive (HashMap Text Text))))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"sessionAttributes"
Either String (Maybe (Maybe (Sensitive (HashMap Text Text))))
-> Maybe (Sensitive (HashMap Text Text))
-> Either String (Maybe (Sensitive (HashMap Text Text)))
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe (Sensitive (HashMap Text Text))
forall a. Monoid a => a
Prelude.mempty
)
Either String (Int -> GetSessionResponse)
-> Either String Int -> Either String GetSessionResponse
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 GetSession
instance Prelude.NFData GetSession
instance Core.ToHeaders GetSession where
toHeaders :: GetSession -> ResponseHeaders
toHeaders =
ResponseHeaders -> GetSession -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ 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.ToPath GetSession where
toPath :: GetSession -> ByteString
toPath GetSession' {Maybe Text
Text
userId :: Text
botAlias :: Text
botName :: Text
checkpointLabelFilter :: Maybe Text
$sel:userId:GetSession' :: GetSession -> Text
$sel:botAlias:GetSession' :: GetSession -> Text
$sel:botName:GetSession' :: GetSession -> Text
$sel:checkpointLabelFilter:GetSession' :: GetSession -> Maybe Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/bot/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
botName,
ByteString
"/alias/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
botAlias,
ByteString
"/user/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
userId,
ByteString
"/session/"
]
instance Core.ToQuery GetSession where
toQuery :: GetSession -> QueryString
toQuery GetSession' {Maybe Text
Text
userId :: Text
botAlias :: Text
botName :: Text
checkpointLabelFilter :: Maybe Text
$sel:userId:GetSession' :: GetSession -> Text
$sel:botAlias:GetSession' :: GetSession -> Text
$sel:botName:GetSession' :: GetSession -> Text
$sel:checkpointLabelFilter:GetSession' :: GetSession -> Maybe Text
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"checkpointLabelFilter"
ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
checkpointLabelFilter
]
data GetSessionResponse = GetSessionResponse'
{
GetSessionResponse -> Maybe (Sensitive [ActiveContext])
activeContexts :: Prelude.Maybe (Core.Sensitive [ActiveContext]),
GetSessionResponse -> Maybe Text
sessionId :: Prelude.Maybe Prelude.Text,
GetSessionResponse -> Maybe [IntentSummary]
recentIntentSummaryView :: Prelude.Maybe [IntentSummary],
GetSessionResponse -> Maybe DialogAction
dialogAction :: Prelude.Maybe DialogAction,
GetSessionResponse -> Maybe (Sensitive (HashMap Text Text))
sessionAttributes :: Prelude.Maybe (Core.Sensitive (Prelude.HashMap Prelude.Text Prelude.Text)),
GetSessionResponse -> Int
httpStatus :: Prelude.Int
}
deriving (GetSessionResponse -> GetSessionResponse -> Bool
(GetSessionResponse -> GetSessionResponse -> Bool)
-> (GetSessionResponse -> GetSessionResponse -> Bool)
-> Eq GetSessionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetSessionResponse -> GetSessionResponse -> Bool
$c/= :: GetSessionResponse -> GetSessionResponse -> Bool
== :: GetSessionResponse -> GetSessionResponse -> Bool
$c== :: GetSessionResponse -> GetSessionResponse -> Bool
Prelude.Eq, Int -> GetSessionResponse -> ShowS
[GetSessionResponse] -> ShowS
GetSessionResponse -> String
(Int -> GetSessionResponse -> ShowS)
-> (GetSessionResponse -> String)
-> ([GetSessionResponse] -> ShowS)
-> Show GetSessionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetSessionResponse] -> ShowS
$cshowList :: [GetSessionResponse] -> ShowS
show :: GetSessionResponse -> String
$cshow :: GetSessionResponse -> String
showsPrec :: Int -> GetSessionResponse -> ShowS
$cshowsPrec :: Int -> GetSessionResponse -> ShowS
Prelude.Show, (forall x. GetSessionResponse -> Rep GetSessionResponse x)
-> (forall x. Rep GetSessionResponse x -> GetSessionResponse)
-> Generic GetSessionResponse
forall x. Rep GetSessionResponse x -> GetSessionResponse
forall x. GetSessionResponse -> Rep GetSessionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetSessionResponse x -> GetSessionResponse
$cfrom :: forall x. GetSessionResponse -> Rep GetSessionResponse x
Prelude.Generic)
newGetSessionResponse ::
Prelude.Int ->
GetSessionResponse
newGetSessionResponse :: Int -> GetSessionResponse
newGetSessionResponse Int
pHttpStatus_ =
GetSessionResponse' :: Maybe (Sensitive [ActiveContext])
-> Maybe Text
-> Maybe [IntentSummary]
-> Maybe DialogAction
-> Maybe (Sensitive (HashMap Text Text))
-> Int
-> GetSessionResponse
GetSessionResponse'
{ $sel:activeContexts:GetSessionResponse' :: Maybe (Sensitive [ActiveContext])
activeContexts =
Maybe (Sensitive [ActiveContext])
forall a. Maybe a
Prelude.Nothing,
$sel:sessionId:GetSessionResponse' :: Maybe Text
sessionId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:recentIntentSummaryView:GetSessionResponse' :: Maybe [IntentSummary]
recentIntentSummaryView = Maybe [IntentSummary]
forall a. Maybe a
Prelude.Nothing,
$sel:dialogAction:GetSessionResponse' :: Maybe DialogAction
dialogAction = Maybe DialogAction
forall a. Maybe a
Prelude.Nothing,
$sel:sessionAttributes:GetSessionResponse' :: Maybe (Sensitive (HashMap Text Text))
sessionAttributes = Maybe (Sensitive (HashMap Text Text))
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:GetSessionResponse' :: Int
httpStatus = Int
pHttpStatus_
}
getSessionResponse_activeContexts :: Lens.Lens' GetSessionResponse (Prelude.Maybe [ActiveContext])
getSessionResponse_activeContexts :: (Maybe [ActiveContext] -> f (Maybe [ActiveContext]))
-> GetSessionResponse -> f GetSessionResponse
getSessionResponse_activeContexts = (GetSessionResponse -> Maybe (Sensitive [ActiveContext]))
-> (GetSessionResponse
-> Maybe (Sensitive [ActiveContext]) -> GetSessionResponse)
-> Lens
GetSessionResponse
GetSessionResponse
(Maybe (Sensitive [ActiveContext]))
(Maybe (Sensitive [ActiveContext]))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Maybe (Sensitive [ActiveContext])
activeContexts :: Maybe (Sensitive [ActiveContext])
$sel:activeContexts:GetSessionResponse' :: GetSessionResponse -> Maybe (Sensitive [ActiveContext])
activeContexts} -> Maybe (Sensitive [ActiveContext])
activeContexts) (\s :: GetSessionResponse
s@GetSessionResponse' {} Maybe (Sensitive [ActiveContext])
a -> GetSessionResponse
s {$sel:activeContexts:GetSessionResponse' :: Maybe (Sensitive [ActiveContext])
activeContexts = Maybe (Sensitive [ActiveContext])
a} :: GetSessionResponse) ((Maybe (Sensitive [ActiveContext])
-> f (Maybe (Sensitive [ActiveContext])))
-> GetSessionResponse -> f GetSessionResponse)
-> ((Maybe [ActiveContext] -> f (Maybe [ActiveContext]))
-> Maybe (Sensitive [ActiveContext])
-> f (Maybe (Sensitive [ActiveContext])))
-> (Maybe [ActiveContext] -> f (Maybe [ActiveContext]))
-> GetSessionResponse
-> f GetSessionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(Sensitive [ActiveContext])
(Sensitive [ActiveContext])
[ActiveContext]
[ActiveContext]
-> Iso
(Maybe (Sensitive [ActiveContext]))
(Maybe (Sensitive [ActiveContext]))
(Maybe [ActiveContext])
(Maybe [ActiveContext])
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
(Sensitive [ActiveContext])
(Sensitive [ActiveContext])
[ActiveContext]
[ActiveContext]
forall a. Iso' (Sensitive a) a
Core._Sensitive AnIso
(Sensitive [ActiveContext])
(Sensitive [ActiveContext])
[ActiveContext]
[ActiveContext]
-> (Exchange
[ActiveContext]
[ActiveContext]
[ActiveContext]
(Identity [ActiveContext])
-> Exchange
[ActiveContext]
[ActiveContext]
[ActiveContext]
(Identity [ActiveContext]))
-> AnIso
(Sensitive [ActiveContext])
(Sensitive [ActiveContext])
[ActiveContext]
[ActiveContext]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Exchange
[ActiveContext]
[ActiveContext]
[ActiveContext]
(Identity [ActiveContext])
-> Exchange
[ActiveContext]
[ActiveContext]
[ActiveContext]
(Identity [ActiveContext])
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced)
getSessionResponse_sessionId :: Lens.Lens' GetSessionResponse (Prelude.Maybe Prelude.Text)
getSessionResponse_sessionId :: (Maybe Text -> f (Maybe Text))
-> GetSessionResponse -> f GetSessionResponse
getSessionResponse_sessionId = (GetSessionResponse -> Maybe Text)
-> (GetSessionResponse -> Maybe Text -> GetSessionResponse)
-> Lens
GetSessionResponse GetSessionResponse (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Maybe Text
sessionId :: Maybe Text
$sel:sessionId:GetSessionResponse' :: GetSessionResponse -> Maybe Text
sessionId} -> Maybe Text
sessionId) (\s :: GetSessionResponse
s@GetSessionResponse' {} Maybe Text
a -> GetSessionResponse
s {$sel:sessionId:GetSessionResponse' :: Maybe Text
sessionId = Maybe Text
a} :: GetSessionResponse)
getSessionResponse_recentIntentSummaryView :: Lens.Lens' GetSessionResponse (Prelude.Maybe [IntentSummary])
getSessionResponse_recentIntentSummaryView :: (Maybe [IntentSummary] -> f (Maybe [IntentSummary]))
-> GetSessionResponse -> f GetSessionResponse
getSessionResponse_recentIntentSummaryView = (GetSessionResponse -> Maybe [IntentSummary])
-> (GetSessionResponse
-> Maybe [IntentSummary] -> GetSessionResponse)
-> Lens
GetSessionResponse
GetSessionResponse
(Maybe [IntentSummary])
(Maybe [IntentSummary])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Maybe [IntentSummary]
recentIntentSummaryView :: Maybe [IntentSummary]
$sel:recentIntentSummaryView:GetSessionResponse' :: GetSessionResponse -> Maybe [IntentSummary]
recentIntentSummaryView} -> Maybe [IntentSummary]
recentIntentSummaryView) (\s :: GetSessionResponse
s@GetSessionResponse' {} Maybe [IntentSummary]
a -> GetSessionResponse
s {$sel:recentIntentSummaryView:GetSessionResponse' :: Maybe [IntentSummary]
recentIntentSummaryView = Maybe [IntentSummary]
a} :: GetSessionResponse) ((Maybe [IntentSummary] -> f (Maybe [IntentSummary]))
-> GetSessionResponse -> f GetSessionResponse)
-> ((Maybe [IntentSummary] -> f (Maybe [IntentSummary]))
-> Maybe [IntentSummary] -> f (Maybe [IntentSummary]))
-> (Maybe [IntentSummary] -> f (Maybe [IntentSummary]))
-> GetSessionResponse
-> f GetSessionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[IntentSummary] [IntentSummary] [IntentSummary] [IntentSummary]
-> Iso
(Maybe [IntentSummary])
(Maybe [IntentSummary])
(Maybe [IntentSummary])
(Maybe [IntentSummary])
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
[IntentSummary] [IntentSummary] [IntentSummary] [IntentSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
getSessionResponse_dialogAction :: Lens.Lens' GetSessionResponse (Prelude.Maybe DialogAction)
getSessionResponse_dialogAction :: (Maybe DialogAction -> f (Maybe DialogAction))
-> GetSessionResponse -> f GetSessionResponse
getSessionResponse_dialogAction = (GetSessionResponse -> Maybe DialogAction)
-> (GetSessionResponse -> Maybe DialogAction -> GetSessionResponse)
-> Lens
GetSessionResponse
GetSessionResponse
(Maybe DialogAction)
(Maybe DialogAction)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Maybe DialogAction
dialogAction :: Maybe DialogAction
$sel:dialogAction:GetSessionResponse' :: GetSessionResponse -> Maybe DialogAction
dialogAction} -> Maybe DialogAction
dialogAction) (\s :: GetSessionResponse
s@GetSessionResponse' {} Maybe DialogAction
a -> GetSessionResponse
s {$sel:dialogAction:GetSessionResponse' :: Maybe DialogAction
dialogAction = Maybe DialogAction
a} :: GetSessionResponse)
getSessionResponse_sessionAttributes :: Lens.Lens' GetSessionResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
getSessionResponse_sessionAttributes :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> GetSessionResponse -> f GetSessionResponse
getSessionResponse_sessionAttributes = (GetSessionResponse -> Maybe (Sensitive (HashMap Text Text)))
-> (GetSessionResponse
-> Maybe (Sensitive (HashMap Text Text)) -> GetSessionResponse)
-> Lens
GetSessionResponse
GetSessionResponse
(Maybe (Sensitive (HashMap Text Text)))
(Maybe (Sensitive (HashMap Text Text)))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Maybe (Sensitive (HashMap Text Text))
sessionAttributes :: Maybe (Sensitive (HashMap Text Text))
$sel:sessionAttributes:GetSessionResponse' :: GetSessionResponse -> Maybe (Sensitive (HashMap Text Text))
sessionAttributes} -> Maybe (Sensitive (HashMap Text Text))
sessionAttributes) (\s :: GetSessionResponse
s@GetSessionResponse' {} Maybe (Sensitive (HashMap Text Text))
a -> GetSessionResponse
s {$sel:sessionAttributes:GetSessionResponse' :: Maybe (Sensitive (HashMap Text Text))
sessionAttributes = Maybe (Sensitive (HashMap Text Text))
a} :: GetSessionResponse) ((Maybe (Sensitive (HashMap Text Text))
-> f (Maybe (Sensitive (HashMap Text Text))))
-> GetSessionResponse -> f GetSessionResponse)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (Sensitive (HashMap Text Text))
-> f (Maybe (Sensitive (HashMap Text Text))))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> GetSessionResponse
-> f GetSessionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(Sensitive (HashMap Text Text))
(Sensitive (HashMap Text Text))
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (Sensitive (HashMap Text Text)))
(Maybe (Sensitive (HashMap Text Text)))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
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
(Sensitive (HashMap Text Text))
(Sensitive (HashMap Text Text))
(HashMap Text Text)
(HashMap Text Text)
forall a. Iso' (Sensitive a) a
Core._Sensitive AnIso
(Sensitive (HashMap Text Text))
(Sensitive (HashMap Text Text))
(HashMap Text Text)
(HashMap Text Text)
-> (Exchange
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(Identity (HashMap Text Text))
-> Exchange
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(Identity (HashMap Text Text)))
-> AnIso
(Sensitive (HashMap Text Text))
(Sensitive (HashMap Text Text))
(HashMap Text Text)
(HashMap Text Text)
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Exchange
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(Identity (HashMap Text Text))
-> Exchange
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(Identity (HashMap Text Text))
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced)
getSessionResponse_httpStatus :: Lens.Lens' GetSessionResponse Prelude.Int
getSessionResponse_httpStatus :: (Int -> f Int) -> GetSessionResponse -> f GetSessionResponse
getSessionResponse_httpStatus = (GetSessionResponse -> Int)
-> (GetSessionResponse -> Int -> GetSessionResponse)
-> Lens GetSessionResponse GetSessionResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSessionResponse' {Int
httpStatus :: Int
$sel:httpStatus:GetSessionResponse' :: GetSessionResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: GetSessionResponse
s@GetSessionResponse' {} Int
a -> GetSessionResponse
s {$sel:httpStatus:GetSessionResponse' :: Int
httpStatus = Int
a} :: GetSessionResponse)
instance Prelude.NFData GetSessionResponse