{-# 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.OpsWorks.RegisterInstance
(
RegisterInstance (..),
newRegisterInstance,
registerInstance_privateIp,
registerInstance_hostname,
registerInstance_instanceIdentity,
registerInstance_publicIp,
registerInstance_rsaPublicKeyFingerprint,
registerInstance_rsaPublicKey,
registerInstance_stackId,
RegisterInstanceResponse (..),
newRegisterInstanceResponse,
registerInstanceResponse_instanceId,
registerInstanceResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.OpsWorks.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data RegisterInstance = RegisterInstance'
{
RegisterInstance -> Maybe Text
privateIp :: Prelude.Maybe Prelude.Text,
RegisterInstance -> Maybe Text
hostname :: Prelude.Maybe Prelude.Text,
RegisterInstance -> Maybe InstanceIdentity
instanceIdentity :: Prelude.Maybe InstanceIdentity,
RegisterInstance -> Maybe Text
publicIp :: Prelude.Maybe Prelude.Text,
RegisterInstance -> Maybe Text
rsaPublicKeyFingerprint :: Prelude.Maybe Prelude.Text,
RegisterInstance -> Maybe Text
rsaPublicKey :: Prelude.Maybe Prelude.Text,
RegisterInstance -> Text
stackId :: Prelude.Text
}
deriving (RegisterInstance -> RegisterInstance -> Bool
(RegisterInstance -> RegisterInstance -> Bool)
-> (RegisterInstance -> RegisterInstance -> Bool)
-> Eq RegisterInstance
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: RegisterInstance -> RegisterInstance -> Bool
$c/= :: RegisterInstance -> RegisterInstance -> Bool
== :: RegisterInstance -> RegisterInstance -> Bool
$c== :: RegisterInstance -> RegisterInstance -> Bool
Prelude.Eq, ReadPrec [RegisterInstance]
ReadPrec RegisterInstance
Int -> ReadS RegisterInstance
ReadS [RegisterInstance]
(Int -> ReadS RegisterInstance)
-> ReadS [RegisterInstance]
-> ReadPrec RegisterInstance
-> ReadPrec [RegisterInstance]
-> Read RegisterInstance
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [RegisterInstance]
$creadListPrec :: ReadPrec [RegisterInstance]
readPrec :: ReadPrec RegisterInstance
$creadPrec :: ReadPrec RegisterInstance
readList :: ReadS [RegisterInstance]
$creadList :: ReadS [RegisterInstance]
readsPrec :: Int -> ReadS RegisterInstance
$creadsPrec :: Int -> ReadS RegisterInstance
Prelude.Read, Int -> RegisterInstance -> ShowS
[RegisterInstance] -> ShowS
RegisterInstance -> String
(Int -> RegisterInstance -> ShowS)
-> (RegisterInstance -> String)
-> ([RegisterInstance] -> ShowS)
-> Show RegisterInstance
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [RegisterInstance] -> ShowS
$cshowList :: [RegisterInstance] -> ShowS
show :: RegisterInstance -> String
$cshow :: RegisterInstance -> String
showsPrec :: Int -> RegisterInstance -> ShowS
$cshowsPrec :: Int -> RegisterInstance -> ShowS
Prelude.Show, (forall x. RegisterInstance -> Rep RegisterInstance x)
-> (forall x. Rep RegisterInstance x -> RegisterInstance)
-> Generic RegisterInstance
forall x. Rep RegisterInstance x -> RegisterInstance
forall x. RegisterInstance -> Rep RegisterInstance x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep RegisterInstance x -> RegisterInstance
$cfrom :: forall x. RegisterInstance -> Rep RegisterInstance x
Prelude.Generic)
newRegisterInstance ::
Prelude.Text ->
RegisterInstance
newRegisterInstance :: Text -> RegisterInstance
newRegisterInstance Text
pStackId_ =
RegisterInstance' :: Maybe Text
-> Maybe Text
-> Maybe InstanceIdentity
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> RegisterInstance
RegisterInstance'
{ $sel:privateIp:RegisterInstance' :: Maybe Text
privateIp = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:hostname:RegisterInstance' :: Maybe Text
hostname = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:instanceIdentity:RegisterInstance' :: Maybe InstanceIdentity
instanceIdentity = Maybe InstanceIdentity
forall a. Maybe a
Prelude.Nothing,
$sel:publicIp:RegisterInstance' :: Maybe Text
publicIp = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:rsaPublicKeyFingerprint:RegisterInstance' :: Maybe Text
rsaPublicKeyFingerprint = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:rsaPublicKey:RegisterInstance' :: Maybe Text
rsaPublicKey = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:stackId:RegisterInstance' :: Text
stackId = Text
pStackId_
}
registerInstance_privateIp :: Lens.Lens' RegisterInstance (Prelude.Maybe Prelude.Text)
registerInstance_privateIp :: (Maybe Text -> f (Maybe Text))
-> RegisterInstance -> f RegisterInstance
registerInstance_privateIp = (RegisterInstance -> Maybe Text)
-> (RegisterInstance -> Maybe Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe Text
privateIp :: Maybe Text
$sel:privateIp:RegisterInstance' :: RegisterInstance -> Maybe Text
privateIp} -> Maybe Text
privateIp) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe Text
a -> RegisterInstance
s {$sel:privateIp:RegisterInstance' :: Maybe Text
privateIp = Maybe Text
a} :: RegisterInstance)
registerInstance_hostname :: Lens.Lens' RegisterInstance (Prelude.Maybe Prelude.Text)
registerInstance_hostname :: (Maybe Text -> f (Maybe Text))
-> RegisterInstance -> f RegisterInstance
registerInstance_hostname = (RegisterInstance -> Maybe Text)
-> (RegisterInstance -> Maybe Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe Text
hostname :: Maybe Text
$sel:hostname:RegisterInstance' :: RegisterInstance -> Maybe Text
hostname} -> Maybe Text
hostname) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe Text
a -> RegisterInstance
s {$sel:hostname:RegisterInstance' :: Maybe Text
hostname = Maybe Text
a} :: RegisterInstance)
registerInstance_instanceIdentity :: Lens.Lens' RegisterInstance (Prelude.Maybe InstanceIdentity)
registerInstance_instanceIdentity :: (Maybe InstanceIdentity -> f (Maybe InstanceIdentity))
-> RegisterInstance -> f RegisterInstance
registerInstance_instanceIdentity = (RegisterInstance -> Maybe InstanceIdentity)
-> (RegisterInstance -> Maybe InstanceIdentity -> RegisterInstance)
-> Lens
RegisterInstance
RegisterInstance
(Maybe InstanceIdentity)
(Maybe InstanceIdentity)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe InstanceIdentity
instanceIdentity :: Maybe InstanceIdentity
$sel:instanceIdentity:RegisterInstance' :: RegisterInstance -> Maybe InstanceIdentity
instanceIdentity} -> Maybe InstanceIdentity
instanceIdentity) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe InstanceIdentity
a -> RegisterInstance
s {$sel:instanceIdentity:RegisterInstance' :: Maybe InstanceIdentity
instanceIdentity = Maybe InstanceIdentity
a} :: RegisterInstance)
registerInstance_publicIp :: Lens.Lens' RegisterInstance (Prelude.Maybe Prelude.Text)
registerInstance_publicIp :: (Maybe Text -> f (Maybe Text))
-> RegisterInstance -> f RegisterInstance
registerInstance_publicIp = (RegisterInstance -> Maybe Text)
-> (RegisterInstance -> Maybe Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe Text
publicIp :: Maybe Text
$sel:publicIp:RegisterInstance' :: RegisterInstance -> Maybe Text
publicIp} -> Maybe Text
publicIp) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe Text
a -> RegisterInstance
s {$sel:publicIp:RegisterInstance' :: Maybe Text
publicIp = Maybe Text
a} :: RegisterInstance)
registerInstance_rsaPublicKeyFingerprint :: Lens.Lens' RegisterInstance (Prelude.Maybe Prelude.Text)
registerInstance_rsaPublicKeyFingerprint :: (Maybe Text -> f (Maybe Text))
-> RegisterInstance -> f RegisterInstance
registerInstance_rsaPublicKeyFingerprint = (RegisterInstance -> Maybe Text)
-> (RegisterInstance -> Maybe Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe Text
rsaPublicKeyFingerprint :: Maybe Text
$sel:rsaPublicKeyFingerprint:RegisterInstance' :: RegisterInstance -> Maybe Text
rsaPublicKeyFingerprint} -> Maybe Text
rsaPublicKeyFingerprint) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe Text
a -> RegisterInstance
s {$sel:rsaPublicKeyFingerprint:RegisterInstance' :: Maybe Text
rsaPublicKeyFingerprint = Maybe Text
a} :: RegisterInstance)
registerInstance_rsaPublicKey :: Lens.Lens' RegisterInstance (Prelude.Maybe Prelude.Text)
registerInstance_rsaPublicKey :: (Maybe Text -> f (Maybe Text))
-> RegisterInstance -> f RegisterInstance
registerInstance_rsaPublicKey = (RegisterInstance -> Maybe Text)
-> (RegisterInstance -> Maybe Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Maybe Text
rsaPublicKey :: Maybe Text
$sel:rsaPublicKey:RegisterInstance' :: RegisterInstance -> Maybe Text
rsaPublicKey} -> Maybe Text
rsaPublicKey) (\s :: RegisterInstance
s@RegisterInstance' {} Maybe Text
a -> RegisterInstance
s {$sel:rsaPublicKey:RegisterInstance' :: Maybe Text
rsaPublicKey = Maybe Text
a} :: RegisterInstance)
registerInstance_stackId :: Lens.Lens' RegisterInstance Prelude.Text
registerInstance_stackId :: (Text -> f Text) -> RegisterInstance -> f RegisterInstance
registerInstance_stackId = (RegisterInstance -> Text)
-> (RegisterInstance -> Text -> RegisterInstance)
-> Lens RegisterInstance RegisterInstance Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstance' {Text
stackId :: Text
$sel:stackId:RegisterInstance' :: RegisterInstance -> Text
stackId} -> Text
stackId) (\s :: RegisterInstance
s@RegisterInstance' {} Text
a -> RegisterInstance
s {$sel:stackId:RegisterInstance' :: Text
stackId = Text
a} :: RegisterInstance)
instance Core.AWSRequest RegisterInstance where
type
AWSResponse RegisterInstance =
RegisterInstanceResponse
request :: RegisterInstance -> Request RegisterInstance
request = Service -> RegisterInstance -> Request RegisterInstance
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy RegisterInstance
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse RegisterInstance)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse RegisterInstance))
-> Logger
-> Service
-> Proxy RegisterInstance
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse RegisterInstance)))
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 Text -> Int -> RegisterInstanceResponse
RegisterInstanceResponse'
(Maybe Text -> Int -> RegisterInstanceResponse)
-> Either String (Maybe Text)
-> Either String (Int -> RegisterInstanceResponse)
forall (f :: * -> *) a b. Functor 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
"InstanceId")
Either String (Int -> RegisterInstanceResponse)
-> Either String Int -> Either String RegisterInstanceResponse
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 RegisterInstance
instance Prelude.NFData RegisterInstance
instance Core.ToHeaders RegisterInstance where
toHeaders :: RegisterInstance -> ResponseHeaders
toHeaders =
ResponseHeaders -> RegisterInstance -> 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
"OpsWorks_20130218.RegisterInstance" ::
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 RegisterInstance where
toJSON :: RegisterInstance -> Value
toJSON RegisterInstance' {Maybe Text
Maybe InstanceIdentity
Text
stackId :: Text
rsaPublicKey :: Maybe Text
rsaPublicKeyFingerprint :: Maybe Text
publicIp :: Maybe Text
instanceIdentity :: Maybe InstanceIdentity
hostname :: Maybe Text
privateIp :: Maybe Text
$sel:stackId:RegisterInstance' :: RegisterInstance -> Text
$sel:rsaPublicKey:RegisterInstance' :: RegisterInstance -> Maybe Text
$sel:rsaPublicKeyFingerprint:RegisterInstance' :: RegisterInstance -> Maybe Text
$sel:publicIp:RegisterInstance' :: RegisterInstance -> Maybe Text
$sel:instanceIdentity:RegisterInstance' :: RegisterInstance -> Maybe InstanceIdentity
$sel:hostname:RegisterInstance' :: RegisterInstance -> Maybe Text
$sel:privateIp:RegisterInstance' :: RegisterInstance -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"PrivateIp" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
privateIp,
(Text
"Hostname" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
hostname,
(Text
"InstanceIdentity" Text -> InstanceIdentity -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(InstanceIdentity -> Pair) -> Maybe InstanceIdentity -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe InstanceIdentity
instanceIdentity,
(Text
"PublicIp" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
publicIp,
(Text
"RsaPublicKeyFingerprint" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
rsaPublicKeyFingerprint,
(Text
"RsaPublicKey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
rsaPublicKey,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"StackId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
stackId)
]
)
instance Core.ToPath RegisterInstance where
toPath :: RegisterInstance -> ByteString
toPath = ByteString -> RegisterInstance -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery RegisterInstance where
toQuery :: RegisterInstance -> QueryString
toQuery = QueryString -> RegisterInstance -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data RegisterInstanceResponse = RegisterInstanceResponse'
{
RegisterInstanceResponse -> Maybe Text
instanceId :: Prelude.Maybe Prelude.Text,
RegisterInstanceResponse -> Int
httpStatus :: Prelude.Int
}
deriving (RegisterInstanceResponse -> RegisterInstanceResponse -> Bool
(RegisterInstanceResponse -> RegisterInstanceResponse -> Bool)
-> (RegisterInstanceResponse -> RegisterInstanceResponse -> Bool)
-> Eq RegisterInstanceResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: RegisterInstanceResponse -> RegisterInstanceResponse -> Bool
$c/= :: RegisterInstanceResponse -> RegisterInstanceResponse -> Bool
== :: RegisterInstanceResponse -> RegisterInstanceResponse -> Bool
$c== :: RegisterInstanceResponse -> RegisterInstanceResponse -> Bool
Prelude.Eq, ReadPrec [RegisterInstanceResponse]
ReadPrec RegisterInstanceResponse
Int -> ReadS RegisterInstanceResponse
ReadS [RegisterInstanceResponse]
(Int -> ReadS RegisterInstanceResponse)
-> ReadS [RegisterInstanceResponse]
-> ReadPrec RegisterInstanceResponse
-> ReadPrec [RegisterInstanceResponse]
-> Read RegisterInstanceResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [RegisterInstanceResponse]
$creadListPrec :: ReadPrec [RegisterInstanceResponse]
readPrec :: ReadPrec RegisterInstanceResponse
$creadPrec :: ReadPrec RegisterInstanceResponse
readList :: ReadS [RegisterInstanceResponse]
$creadList :: ReadS [RegisterInstanceResponse]
readsPrec :: Int -> ReadS RegisterInstanceResponse
$creadsPrec :: Int -> ReadS RegisterInstanceResponse
Prelude.Read, Int -> RegisterInstanceResponse -> ShowS
[RegisterInstanceResponse] -> ShowS
RegisterInstanceResponse -> String
(Int -> RegisterInstanceResponse -> ShowS)
-> (RegisterInstanceResponse -> String)
-> ([RegisterInstanceResponse] -> ShowS)
-> Show RegisterInstanceResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [RegisterInstanceResponse] -> ShowS
$cshowList :: [RegisterInstanceResponse] -> ShowS
show :: RegisterInstanceResponse -> String
$cshow :: RegisterInstanceResponse -> String
showsPrec :: Int -> RegisterInstanceResponse -> ShowS
$cshowsPrec :: Int -> RegisterInstanceResponse -> ShowS
Prelude.Show, (forall x.
RegisterInstanceResponse -> Rep RegisterInstanceResponse x)
-> (forall x.
Rep RegisterInstanceResponse x -> RegisterInstanceResponse)
-> Generic RegisterInstanceResponse
forall x.
Rep RegisterInstanceResponse x -> RegisterInstanceResponse
forall x.
RegisterInstanceResponse -> Rep RegisterInstanceResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep RegisterInstanceResponse x -> RegisterInstanceResponse
$cfrom :: forall x.
RegisterInstanceResponse -> Rep RegisterInstanceResponse x
Prelude.Generic)
newRegisterInstanceResponse ::
Prelude.Int ->
RegisterInstanceResponse
newRegisterInstanceResponse :: Int -> RegisterInstanceResponse
newRegisterInstanceResponse Int
pHttpStatus_ =
RegisterInstanceResponse' :: Maybe Text -> Int -> RegisterInstanceResponse
RegisterInstanceResponse'
{ $sel:instanceId:RegisterInstanceResponse' :: Maybe Text
instanceId =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:RegisterInstanceResponse' :: Int
httpStatus = Int
pHttpStatus_
}
registerInstanceResponse_instanceId :: Lens.Lens' RegisterInstanceResponse (Prelude.Maybe Prelude.Text)
registerInstanceResponse_instanceId :: (Maybe Text -> f (Maybe Text))
-> RegisterInstanceResponse -> f RegisterInstanceResponse
registerInstanceResponse_instanceId = (RegisterInstanceResponse -> Maybe Text)
-> (RegisterInstanceResponse
-> Maybe Text -> RegisterInstanceResponse)
-> Lens
RegisterInstanceResponse
RegisterInstanceResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstanceResponse' {Maybe Text
instanceId :: Maybe Text
$sel:instanceId:RegisterInstanceResponse' :: RegisterInstanceResponse -> Maybe Text
instanceId} -> Maybe Text
instanceId) (\s :: RegisterInstanceResponse
s@RegisterInstanceResponse' {} Maybe Text
a -> RegisterInstanceResponse
s {$sel:instanceId:RegisterInstanceResponse' :: Maybe Text
instanceId = Maybe Text
a} :: RegisterInstanceResponse)
registerInstanceResponse_httpStatus :: Lens.Lens' RegisterInstanceResponse Prelude.Int
registerInstanceResponse_httpStatus :: (Int -> f Int)
-> RegisterInstanceResponse -> f RegisterInstanceResponse
registerInstanceResponse_httpStatus = (RegisterInstanceResponse -> Int)
-> (RegisterInstanceResponse -> Int -> RegisterInstanceResponse)
-> Lens RegisterInstanceResponse RegisterInstanceResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegisterInstanceResponse' {Int
httpStatus :: Int
$sel:httpStatus:RegisterInstanceResponse' :: RegisterInstanceResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: RegisterInstanceResponse
s@RegisterInstanceResponse' {} Int
a -> RegisterInstanceResponse
s {$sel:httpStatus:RegisterInstanceResponse' :: Int
httpStatus = Int
a} :: RegisterInstanceResponse)
instance Prelude.NFData RegisterInstanceResponse