{-# 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.SSOOIDC.StartDeviceAuthorization
(
StartDeviceAuthorization (..),
newStartDeviceAuthorization,
startDeviceAuthorization_clientId,
startDeviceAuthorization_clientSecret,
startDeviceAuthorization_startUrl,
StartDeviceAuthorizationResponse (..),
newStartDeviceAuthorizationResponse,
startDeviceAuthorizationResponse_deviceCode,
startDeviceAuthorizationResponse_expiresIn,
startDeviceAuthorizationResponse_interval,
startDeviceAuthorizationResponse_userCode,
startDeviceAuthorizationResponse_verificationUri,
startDeviceAuthorizationResponse_verificationUriComplete,
startDeviceAuthorizationResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.SSOOIDC.Types
data StartDeviceAuthorization = StartDeviceAuthorization'
{
StartDeviceAuthorization -> Text
clientId :: Prelude.Text,
StartDeviceAuthorization -> Text
clientSecret :: Prelude.Text,
StartDeviceAuthorization -> Text
startUrl :: Prelude.Text
}
deriving (StartDeviceAuthorization -> StartDeviceAuthorization -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StartDeviceAuthorization -> StartDeviceAuthorization -> Bool
$c/= :: StartDeviceAuthorization -> StartDeviceAuthorization -> Bool
== :: StartDeviceAuthorization -> StartDeviceAuthorization -> Bool
$c== :: StartDeviceAuthorization -> StartDeviceAuthorization -> Bool
Prelude.Eq, ReadPrec [StartDeviceAuthorization]
ReadPrec StartDeviceAuthorization
Int -> ReadS StartDeviceAuthorization
ReadS [StartDeviceAuthorization]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StartDeviceAuthorization]
$creadListPrec :: ReadPrec [StartDeviceAuthorization]
readPrec :: ReadPrec StartDeviceAuthorization
$creadPrec :: ReadPrec StartDeviceAuthorization
readList :: ReadS [StartDeviceAuthorization]
$creadList :: ReadS [StartDeviceAuthorization]
readsPrec :: Int -> ReadS StartDeviceAuthorization
$creadsPrec :: Int -> ReadS StartDeviceAuthorization
Prelude.Read, Int -> StartDeviceAuthorization -> ShowS
[StartDeviceAuthorization] -> ShowS
StartDeviceAuthorization -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StartDeviceAuthorization] -> ShowS
$cshowList :: [StartDeviceAuthorization] -> ShowS
show :: StartDeviceAuthorization -> String
$cshow :: StartDeviceAuthorization -> String
showsPrec :: Int -> StartDeviceAuthorization -> ShowS
$cshowsPrec :: Int -> StartDeviceAuthorization -> ShowS
Prelude.Show, forall x.
Rep StartDeviceAuthorization x -> StartDeviceAuthorization
forall x.
StartDeviceAuthorization -> Rep StartDeviceAuthorization x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StartDeviceAuthorization x -> StartDeviceAuthorization
$cfrom :: forall x.
StartDeviceAuthorization -> Rep StartDeviceAuthorization x
Prelude.Generic)
newStartDeviceAuthorization ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
StartDeviceAuthorization
newStartDeviceAuthorization :: Text -> Text -> Text -> StartDeviceAuthorization
newStartDeviceAuthorization
Text
pClientId_
Text
pClientSecret_
Text
pStartUrl_ =
StartDeviceAuthorization'
{ $sel:clientId:StartDeviceAuthorization' :: Text
clientId = Text
pClientId_,
$sel:clientSecret:StartDeviceAuthorization' :: Text
clientSecret = Text
pClientSecret_,
$sel:startUrl:StartDeviceAuthorization' :: Text
startUrl = Text
pStartUrl_
}
startDeviceAuthorization_clientId :: Lens.Lens' StartDeviceAuthorization Prelude.Text
startDeviceAuthorization_clientId :: Lens' StartDeviceAuthorization Text
startDeviceAuthorization_clientId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorization' {Text
clientId :: Text
$sel:clientId:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
clientId} -> Text
clientId) (\s :: StartDeviceAuthorization
s@StartDeviceAuthorization' {} Text
a -> StartDeviceAuthorization
s {$sel:clientId:StartDeviceAuthorization' :: Text
clientId = Text
a} :: StartDeviceAuthorization)
startDeviceAuthorization_clientSecret :: Lens.Lens' StartDeviceAuthorization Prelude.Text
startDeviceAuthorization_clientSecret :: Lens' StartDeviceAuthorization Text
startDeviceAuthorization_clientSecret = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorization' {Text
clientSecret :: Text
$sel:clientSecret:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
clientSecret} -> Text
clientSecret) (\s :: StartDeviceAuthorization
s@StartDeviceAuthorization' {} Text
a -> StartDeviceAuthorization
s {$sel:clientSecret:StartDeviceAuthorization' :: Text
clientSecret = Text
a} :: StartDeviceAuthorization)
startDeviceAuthorization_startUrl :: Lens.Lens' StartDeviceAuthorization Prelude.Text
startDeviceAuthorization_startUrl :: Lens' StartDeviceAuthorization Text
startDeviceAuthorization_startUrl = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorization' {Text
startUrl :: Text
$sel:startUrl:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
startUrl} -> Text
startUrl) (\s :: StartDeviceAuthorization
s@StartDeviceAuthorization' {} Text
a -> StartDeviceAuthorization
s {$sel:startUrl:StartDeviceAuthorization' :: Text
startUrl = Text
a} :: StartDeviceAuthorization)
instance Core.AWSRequest StartDeviceAuthorization where
type
AWSResponse StartDeviceAuthorization =
StartDeviceAuthorizationResponse
request :: (Service -> Service)
-> StartDeviceAuthorization -> Request StartDeviceAuthorization
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy StartDeviceAuthorization
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse StartDeviceAuthorization)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> StartDeviceAuthorizationResponse
StartDeviceAuthorizationResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"deviceCode")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"expiresIn")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"interval")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"userCode")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"verificationUri")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"verificationUriComplete")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable StartDeviceAuthorization where
hashWithSalt :: Int -> StartDeviceAuthorization -> Int
hashWithSalt Int
_salt StartDeviceAuthorization' {Text
startUrl :: Text
clientSecret :: Text
clientId :: Text
$sel:startUrl:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientSecret:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientId:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
clientId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
clientSecret
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
startUrl
instance Prelude.NFData StartDeviceAuthorization where
rnf :: StartDeviceAuthorization -> ()
rnf StartDeviceAuthorization' {Text
startUrl :: Text
clientSecret :: Text
clientId :: Text
$sel:startUrl:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientSecret:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientId:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
clientId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
clientSecret
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
startUrl
instance Data.ToHeaders StartDeviceAuthorization where
toHeaders :: StartDeviceAuthorization -> ResponseHeaders
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON StartDeviceAuthorization where
toJSON :: StartDeviceAuthorization -> Value
toJSON StartDeviceAuthorization' {Text
startUrl :: Text
clientSecret :: Text
clientId :: Text
$sel:startUrl:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientSecret:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
$sel:clientId:StartDeviceAuthorization' :: StartDeviceAuthorization -> Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ forall a. a -> Maybe a
Prelude.Just (Key
"clientId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
clientId),
forall a. a -> Maybe a
Prelude.Just (Key
"clientSecret" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
clientSecret),
forall a. a -> Maybe a
Prelude.Just (Key
"startUrl" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
startUrl)
]
)
instance Data.ToPath StartDeviceAuthorization where
toPath :: StartDeviceAuthorization -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/device_authorization"
instance Data.ToQuery StartDeviceAuthorization where
toQuery :: StartDeviceAuthorization -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data StartDeviceAuthorizationResponse = StartDeviceAuthorizationResponse'
{
StartDeviceAuthorizationResponse -> Maybe Text
deviceCode :: Prelude.Maybe Prelude.Text,
StartDeviceAuthorizationResponse -> Maybe Int
expiresIn :: Prelude.Maybe Prelude.Int,
StartDeviceAuthorizationResponse -> Maybe Int
interval :: Prelude.Maybe Prelude.Int,
StartDeviceAuthorizationResponse -> Maybe Text
userCode :: Prelude.Maybe Prelude.Text,
StartDeviceAuthorizationResponse -> Maybe Text
verificationUri :: Prelude.Maybe Prelude.Text,
StartDeviceAuthorizationResponse -> Maybe Text
verificationUriComplete :: Prelude.Maybe Prelude.Text,
StartDeviceAuthorizationResponse -> Int
httpStatus :: Prelude.Int
}
deriving (StartDeviceAuthorizationResponse
-> StartDeviceAuthorizationResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: StartDeviceAuthorizationResponse
-> StartDeviceAuthorizationResponse -> Bool
$c/= :: StartDeviceAuthorizationResponse
-> StartDeviceAuthorizationResponse -> Bool
== :: StartDeviceAuthorizationResponse
-> StartDeviceAuthorizationResponse -> Bool
$c== :: StartDeviceAuthorizationResponse
-> StartDeviceAuthorizationResponse -> Bool
Prelude.Eq, ReadPrec [StartDeviceAuthorizationResponse]
ReadPrec StartDeviceAuthorizationResponse
Int -> ReadS StartDeviceAuthorizationResponse
ReadS [StartDeviceAuthorizationResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [StartDeviceAuthorizationResponse]
$creadListPrec :: ReadPrec [StartDeviceAuthorizationResponse]
readPrec :: ReadPrec StartDeviceAuthorizationResponse
$creadPrec :: ReadPrec StartDeviceAuthorizationResponse
readList :: ReadS [StartDeviceAuthorizationResponse]
$creadList :: ReadS [StartDeviceAuthorizationResponse]
readsPrec :: Int -> ReadS StartDeviceAuthorizationResponse
$creadsPrec :: Int -> ReadS StartDeviceAuthorizationResponse
Prelude.Read, Int -> StartDeviceAuthorizationResponse -> ShowS
[StartDeviceAuthorizationResponse] -> ShowS
StartDeviceAuthorizationResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [StartDeviceAuthorizationResponse] -> ShowS
$cshowList :: [StartDeviceAuthorizationResponse] -> ShowS
show :: StartDeviceAuthorizationResponse -> String
$cshow :: StartDeviceAuthorizationResponse -> String
showsPrec :: Int -> StartDeviceAuthorizationResponse -> ShowS
$cshowsPrec :: Int -> StartDeviceAuthorizationResponse -> ShowS
Prelude.Show, forall x.
Rep StartDeviceAuthorizationResponse x
-> StartDeviceAuthorizationResponse
forall x.
StartDeviceAuthorizationResponse
-> Rep StartDeviceAuthorizationResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep StartDeviceAuthorizationResponse x
-> StartDeviceAuthorizationResponse
$cfrom :: forall x.
StartDeviceAuthorizationResponse
-> Rep StartDeviceAuthorizationResponse x
Prelude.Generic)
newStartDeviceAuthorizationResponse ::
Prelude.Int ->
StartDeviceAuthorizationResponse
newStartDeviceAuthorizationResponse :: Int -> StartDeviceAuthorizationResponse
newStartDeviceAuthorizationResponse Int
pHttpStatus_ =
StartDeviceAuthorizationResponse'
{ $sel:deviceCode:StartDeviceAuthorizationResponse' :: Maybe Text
deviceCode =
forall a. Maybe a
Prelude.Nothing,
$sel:expiresIn:StartDeviceAuthorizationResponse' :: Maybe Int
expiresIn = forall a. Maybe a
Prelude.Nothing,
$sel:interval:StartDeviceAuthorizationResponse' :: Maybe Int
interval = forall a. Maybe a
Prelude.Nothing,
$sel:userCode:StartDeviceAuthorizationResponse' :: Maybe Text
userCode = forall a. Maybe a
Prelude.Nothing,
$sel:verificationUri:StartDeviceAuthorizationResponse' :: Maybe Text
verificationUri = forall a. Maybe a
Prelude.Nothing,
$sel:verificationUriComplete:StartDeviceAuthorizationResponse' :: Maybe Text
verificationUriComplete = forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:StartDeviceAuthorizationResponse' :: Int
httpStatus = Int
pHttpStatus_
}
startDeviceAuthorizationResponse_deviceCode :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Text)
startDeviceAuthorizationResponse_deviceCode :: Lens' StartDeviceAuthorizationResponse (Maybe Text)
startDeviceAuthorizationResponse_deviceCode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Text
deviceCode :: Maybe Text
$sel:deviceCode:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
deviceCode} -> Maybe Text
deviceCode) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Text
a -> StartDeviceAuthorizationResponse
s {$sel:deviceCode:StartDeviceAuthorizationResponse' :: Maybe Text
deviceCode = Maybe Text
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_expiresIn :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Int)
startDeviceAuthorizationResponse_expiresIn :: Lens' StartDeviceAuthorizationResponse (Maybe Int)
startDeviceAuthorizationResponse_expiresIn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Int
expiresIn :: Maybe Int
$sel:expiresIn:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Int
expiresIn} -> Maybe Int
expiresIn) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Int
a -> StartDeviceAuthorizationResponse
s {$sel:expiresIn:StartDeviceAuthorizationResponse' :: Maybe Int
expiresIn = Maybe Int
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_interval :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Int)
startDeviceAuthorizationResponse_interval :: Lens' StartDeviceAuthorizationResponse (Maybe Int)
startDeviceAuthorizationResponse_interval = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Int
interval :: Maybe Int
$sel:interval:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Int
interval} -> Maybe Int
interval) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Int
a -> StartDeviceAuthorizationResponse
s {$sel:interval:StartDeviceAuthorizationResponse' :: Maybe Int
interval = Maybe Int
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_userCode :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Text)
startDeviceAuthorizationResponse_userCode :: Lens' StartDeviceAuthorizationResponse (Maybe Text)
startDeviceAuthorizationResponse_userCode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Text
userCode :: Maybe Text
$sel:userCode:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
userCode} -> Maybe Text
userCode) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Text
a -> StartDeviceAuthorizationResponse
s {$sel:userCode:StartDeviceAuthorizationResponse' :: Maybe Text
userCode = Maybe Text
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_verificationUri :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Text)
startDeviceAuthorizationResponse_verificationUri :: Lens' StartDeviceAuthorizationResponse (Maybe Text)
startDeviceAuthorizationResponse_verificationUri = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Text
verificationUri :: Maybe Text
$sel:verificationUri:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
verificationUri} -> Maybe Text
verificationUri) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Text
a -> StartDeviceAuthorizationResponse
s {$sel:verificationUri:StartDeviceAuthorizationResponse' :: Maybe Text
verificationUri = Maybe Text
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_verificationUriComplete :: Lens.Lens' StartDeviceAuthorizationResponse (Prelude.Maybe Prelude.Text)
startDeviceAuthorizationResponse_verificationUriComplete :: Lens' StartDeviceAuthorizationResponse (Maybe Text)
startDeviceAuthorizationResponse_verificationUriComplete = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Maybe Text
verificationUriComplete :: Maybe Text
$sel:verificationUriComplete:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
verificationUriComplete} -> Maybe Text
verificationUriComplete) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Maybe Text
a -> StartDeviceAuthorizationResponse
s {$sel:verificationUriComplete:StartDeviceAuthorizationResponse' :: Maybe Text
verificationUriComplete = Maybe Text
a} :: StartDeviceAuthorizationResponse)
startDeviceAuthorizationResponse_httpStatus :: Lens.Lens' StartDeviceAuthorizationResponse Prelude.Int
startDeviceAuthorizationResponse_httpStatus :: Lens' StartDeviceAuthorizationResponse Int
startDeviceAuthorizationResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\StartDeviceAuthorizationResponse' {Int
httpStatus :: Int
$sel:httpStatus:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: StartDeviceAuthorizationResponse
s@StartDeviceAuthorizationResponse' {} Int
a -> StartDeviceAuthorizationResponse
s {$sel:httpStatus:StartDeviceAuthorizationResponse' :: Int
httpStatus = Int
a} :: StartDeviceAuthorizationResponse)
instance
Prelude.NFData
StartDeviceAuthorizationResponse
where
rnf :: StartDeviceAuthorizationResponse -> ()
rnf StartDeviceAuthorizationResponse' {Int
Maybe Int
Maybe Text
httpStatus :: Int
verificationUriComplete :: Maybe Text
verificationUri :: Maybe Text
userCode :: Maybe Text
interval :: Maybe Int
expiresIn :: Maybe Int
deviceCode :: Maybe Text
$sel:httpStatus:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Int
$sel:verificationUriComplete:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
$sel:verificationUri:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
$sel:userCode:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
$sel:interval:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Int
$sel:expiresIn:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Int
$sel:deviceCode:StartDeviceAuthorizationResponse' :: StartDeviceAuthorizationResponse -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
deviceCode
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
expiresIn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
interval
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
userCode
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
verificationUri
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
verificationUriComplete
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus