{-# 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.CertificateManager.ImportCertificate
(
ImportCertificate (..),
newImportCertificate,
importCertificate_certificateArn,
importCertificate_certificateChain,
importCertificate_tags,
importCertificate_certificate,
importCertificate_privateKey,
ImportCertificateResponse (..),
newImportCertificateResponse,
importCertificateResponse_certificateArn,
importCertificateResponse_httpStatus,
)
where
import Amazonka.CertificateManager.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
data ImportCertificate = ImportCertificate'
{
ImportCertificate -> Maybe Text
certificateArn :: Prelude.Maybe Prelude.Text,
ImportCertificate -> Maybe Base64
certificateChain :: Prelude.Maybe Core.Base64,
ImportCertificate -> Maybe (NonEmpty Tag)
tags :: Prelude.Maybe (Prelude.NonEmpty Tag),
ImportCertificate -> Base64
certificate :: Core.Base64,
ImportCertificate -> Sensitive Base64
privateKey :: Core.Sensitive Core.Base64
}
deriving (ImportCertificate -> ImportCertificate -> Bool
(ImportCertificate -> ImportCertificate -> Bool)
-> (ImportCertificate -> ImportCertificate -> Bool)
-> Eq ImportCertificate
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ImportCertificate -> ImportCertificate -> Bool
$c/= :: ImportCertificate -> ImportCertificate -> Bool
== :: ImportCertificate -> ImportCertificate -> Bool
$c== :: ImportCertificate -> ImportCertificate -> Bool
Prelude.Eq, Int -> ImportCertificate -> ShowS
[ImportCertificate] -> ShowS
ImportCertificate -> String
(Int -> ImportCertificate -> ShowS)
-> (ImportCertificate -> String)
-> ([ImportCertificate] -> ShowS)
-> Show ImportCertificate
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ImportCertificate] -> ShowS
$cshowList :: [ImportCertificate] -> ShowS
show :: ImportCertificate -> String
$cshow :: ImportCertificate -> String
showsPrec :: Int -> ImportCertificate -> ShowS
$cshowsPrec :: Int -> ImportCertificate -> ShowS
Prelude.Show, (forall x. ImportCertificate -> Rep ImportCertificate x)
-> (forall x. Rep ImportCertificate x -> ImportCertificate)
-> Generic ImportCertificate
forall x. Rep ImportCertificate x -> ImportCertificate
forall x. ImportCertificate -> Rep ImportCertificate x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ImportCertificate x -> ImportCertificate
$cfrom :: forall x. ImportCertificate -> Rep ImportCertificate x
Prelude.Generic)
newImportCertificate ::
Prelude.ByteString ->
Prelude.ByteString ->
ImportCertificate
newImportCertificate :: ByteString -> ByteString -> ImportCertificate
newImportCertificate ByteString
pCertificate_ ByteString
pPrivateKey_ =
ImportCertificate' :: Maybe Text
-> Maybe Base64
-> Maybe (NonEmpty Tag)
-> Base64
-> Sensitive Base64
-> ImportCertificate
ImportCertificate'
{ $sel:certificateArn:ImportCertificate' :: Maybe Text
certificateArn =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:certificateChain:ImportCertificate' :: Maybe Base64
certificateChain = Maybe Base64
forall a. Maybe a
Prelude.Nothing,
$sel:tags:ImportCertificate' :: Maybe (NonEmpty Tag)
tags = Maybe (NonEmpty Tag)
forall a. Maybe a
Prelude.Nothing,
$sel:certificate:ImportCertificate' :: Base64
certificate = Tagged ByteString (Identity ByteString)
-> Tagged Base64 (Identity Base64)
Iso' Base64 ByteString
Core._Base64 (Tagged ByteString (Identity ByteString)
-> Tagged Base64 (Identity Base64))
-> ByteString -> Base64
forall t b. AReview t b -> b -> t
Lens.# ByteString
pCertificate_,
$sel:privateKey:ImportCertificate' :: Sensitive Base64
privateKey =
Tagged Base64 (Identity Base64)
-> Tagged (Sensitive Base64) (Identity (Sensitive Base64))
forall a. Iso' (Sensitive a) a
Core._Sensitive (Tagged Base64 (Identity Base64)
-> Tagged (Sensitive Base64) (Identity (Sensitive Base64)))
-> (Tagged ByteString (Identity ByteString)
-> Tagged Base64 (Identity Base64))
-> Tagged ByteString (Identity ByteString)
-> Tagged (Sensitive Base64) (Identity (Sensitive Base64))
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Tagged ByteString (Identity ByteString)
-> Tagged Base64 (Identity Base64)
Iso' Base64 ByteString
Core._Base64
(Tagged ByteString (Identity ByteString)
-> Tagged (Sensitive Base64) (Identity (Sensitive Base64)))
-> ByteString -> Sensitive Base64
forall t b. AReview t b -> b -> t
Lens.# ByteString
pPrivateKey_
}
importCertificate_certificateArn :: Lens.Lens' ImportCertificate (Prelude.Maybe Prelude.Text)
importCertificate_certificateArn :: (Maybe Text -> f (Maybe Text))
-> ImportCertificate -> f ImportCertificate
importCertificate_certificateArn = (ImportCertificate -> Maybe Text)
-> (ImportCertificate -> Maybe Text -> ImportCertificate)
-> Lens
ImportCertificate ImportCertificate (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificate' {Maybe Text
certificateArn :: Maybe Text
$sel:certificateArn:ImportCertificate' :: ImportCertificate -> Maybe Text
certificateArn} -> Maybe Text
certificateArn) (\s :: ImportCertificate
s@ImportCertificate' {} Maybe Text
a -> ImportCertificate
s {$sel:certificateArn:ImportCertificate' :: Maybe Text
certificateArn = Maybe Text
a} :: ImportCertificate)
importCertificate_certificateChain :: Lens.Lens' ImportCertificate (Prelude.Maybe Prelude.ByteString)
importCertificate_certificateChain :: (Maybe ByteString -> f (Maybe ByteString))
-> ImportCertificate -> f ImportCertificate
importCertificate_certificateChain = (ImportCertificate -> Maybe Base64)
-> (ImportCertificate -> Maybe Base64 -> ImportCertificate)
-> Lens
ImportCertificate ImportCertificate (Maybe Base64) (Maybe Base64)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificate' {Maybe Base64
certificateChain :: Maybe Base64
$sel:certificateChain:ImportCertificate' :: ImportCertificate -> Maybe Base64
certificateChain} -> Maybe Base64
certificateChain) (\s :: ImportCertificate
s@ImportCertificate' {} Maybe Base64
a -> ImportCertificate
s {$sel:certificateChain:ImportCertificate' :: Maybe Base64
certificateChain = Maybe Base64
a} :: ImportCertificate) ((Maybe Base64 -> f (Maybe Base64))
-> ImportCertificate -> f ImportCertificate)
-> ((Maybe ByteString -> f (Maybe ByteString))
-> Maybe Base64 -> f (Maybe Base64))
-> (Maybe ByteString -> f (Maybe ByteString))
-> ImportCertificate
-> f ImportCertificate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso Base64 Base64 ByteString ByteString
-> Iso
(Maybe Base64) (Maybe Base64) (Maybe ByteString) (Maybe ByteString)
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 Base64 Base64 ByteString ByteString
Iso' Base64 ByteString
Core._Base64
importCertificate_tags :: Lens.Lens' ImportCertificate (Prelude.Maybe (Prelude.NonEmpty Tag))
importCertificate_tags :: (Maybe (NonEmpty Tag) -> f (Maybe (NonEmpty Tag)))
-> ImportCertificate -> f ImportCertificate
importCertificate_tags = (ImportCertificate -> Maybe (NonEmpty Tag))
-> (ImportCertificate -> Maybe (NonEmpty Tag) -> ImportCertificate)
-> Lens
ImportCertificate
ImportCertificate
(Maybe (NonEmpty Tag))
(Maybe (NonEmpty Tag))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificate' {Maybe (NonEmpty Tag)
tags :: Maybe (NonEmpty Tag)
$sel:tags:ImportCertificate' :: ImportCertificate -> Maybe (NonEmpty Tag)
tags} -> Maybe (NonEmpty Tag)
tags) (\s :: ImportCertificate
s@ImportCertificate' {} Maybe (NonEmpty Tag)
a -> ImportCertificate
s {$sel:tags:ImportCertificate' :: Maybe (NonEmpty Tag)
tags = Maybe (NonEmpty Tag)
a} :: ImportCertificate) ((Maybe (NonEmpty Tag) -> f (Maybe (NonEmpty Tag)))
-> ImportCertificate -> f ImportCertificate)
-> ((Maybe (NonEmpty Tag) -> f (Maybe (NonEmpty Tag)))
-> Maybe (NonEmpty Tag) -> f (Maybe (NonEmpty Tag)))
-> (Maybe (NonEmpty Tag) -> f (Maybe (NonEmpty Tag)))
-> ImportCertificate
-> f ImportCertificate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso (NonEmpty Tag) (NonEmpty Tag) (NonEmpty Tag) (NonEmpty Tag)
-> Iso
(Maybe (NonEmpty Tag))
(Maybe (NonEmpty Tag))
(Maybe (NonEmpty Tag))
(Maybe (NonEmpty Tag))
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 (NonEmpty Tag) (NonEmpty Tag) (NonEmpty Tag) (NonEmpty Tag)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
importCertificate_certificate :: Lens.Lens' ImportCertificate Prelude.ByteString
importCertificate_certificate :: (ByteString -> f ByteString)
-> ImportCertificate -> f ImportCertificate
importCertificate_certificate = (ImportCertificate -> Base64)
-> (ImportCertificate -> Base64 -> ImportCertificate)
-> Lens ImportCertificate ImportCertificate Base64 Base64
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificate' {Base64
certificate :: Base64
$sel:certificate:ImportCertificate' :: ImportCertificate -> Base64
certificate} -> Base64
certificate) (\s :: ImportCertificate
s@ImportCertificate' {} Base64
a -> ImportCertificate
s {$sel:certificate:ImportCertificate' :: Base64
certificate = Base64
a} :: ImportCertificate) ((Base64 -> f Base64) -> ImportCertificate -> f ImportCertificate)
-> ((ByteString -> f ByteString) -> Base64 -> f Base64)
-> (ByteString -> f ByteString)
-> ImportCertificate
-> f ImportCertificate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (ByteString -> f ByteString) -> Base64 -> f Base64
Iso' Base64 ByteString
Core._Base64
importCertificate_privateKey :: Lens.Lens' ImportCertificate Prelude.ByteString
importCertificate_privateKey :: (ByteString -> f ByteString)
-> ImportCertificate -> f ImportCertificate
importCertificate_privateKey = (ImportCertificate -> Sensitive Base64)
-> (ImportCertificate -> Sensitive Base64 -> ImportCertificate)
-> Lens
ImportCertificate
ImportCertificate
(Sensitive Base64)
(Sensitive Base64)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificate' {Sensitive Base64
privateKey :: Sensitive Base64
$sel:privateKey:ImportCertificate' :: ImportCertificate -> Sensitive Base64
privateKey} -> Sensitive Base64
privateKey) (\s :: ImportCertificate
s@ImportCertificate' {} Sensitive Base64
a -> ImportCertificate
s {$sel:privateKey:ImportCertificate' :: Sensitive Base64
privateKey = Sensitive Base64
a} :: ImportCertificate) ((Sensitive Base64 -> f (Sensitive Base64))
-> ImportCertificate -> f ImportCertificate)
-> ((ByteString -> f ByteString)
-> Sensitive Base64 -> f (Sensitive Base64))
-> (ByteString -> f ByteString)
-> ImportCertificate
-> f ImportCertificate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Base64 -> f Base64) -> Sensitive Base64 -> f (Sensitive Base64)
forall a. Iso' (Sensitive a) a
Core._Sensitive ((Base64 -> f Base64) -> Sensitive Base64 -> f (Sensitive Base64))
-> ((ByteString -> f ByteString) -> Base64 -> f Base64)
-> (ByteString -> f ByteString)
-> Sensitive Base64
-> f (Sensitive Base64)
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (ByteString -> f ByteString) -> Base64 -> f Base64
Iso' Base64 ByteString
Core._Base64
instance Core.AWSRequest ImportCertificate where
type
AWSResponse ImportCertificate =
ImportCertificateResponse
request :: ImportCertificate -> Request ImportCertificate
request = Service -> ImportCertificate -> Request ImportCertificate
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ImportCertificate
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ImportCertificate)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ImportCertificate))
-> Logger
-> Service
-> Proxy ImportCertificate
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ImportCertificate)))
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 -> ImportCertificateResponse
ImportCertificateResponse'
(Maybe Text -> Int -> ImportCertificateResponse)
-> Either String (Maybe Text)
-> Either String (Int -> ImportCertificateResponse)
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
"CertificateArn")
Either String (Int -> ImportCertificateResponse)
-> Either String Int -> Either String ImportCertificateResponse
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 ImportCertificate
instance Prelude.NFData ImportCertificate
instance Core.ToHeaders ImportCertificate where
toHeaders :: ImportCertificate -> ResponseHeaders
toHeaders =
ResponseHeaders -> ImportCertificate -> 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
"CertificateManager.ImportCertificate" ::
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 ImportCertificate where
toJSON :: ImportCertificate -> Value
toJSON ImportCertificate' {Maybe (NonEmpty Tag)
Maybe Text
Maybe Base64
Base64
Sensitive Base64
privateKey :: Sensitive Base64
certificate :: Base64
tags :: Maybe (NonEmpty Tag)
certificateChain :: Maybe Base64
certificateArn :: Maybe Text
$sel:privateKey:ImportCertificate' :: ImportCertificate -> Sensitive Base64
$sel:certificate:ImportCertificate' :: ImportCertificate -> Base64
$sel:tags:ImportCertificate' :: ImportCertificate -> Maybe (NonEmpty Tag)
$sel:certificateChain:ImportCertificate' :: ImportCertificate -> Maybe Base64
$sel:certificateArn:ImportCertificate' :: ImportCertificate -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"CertificateArn" 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
certificateArn,
(Text
"CertificateChain" Text -> Base64 -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Base64 -> Pair) -> Maybe Base64 -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Base64
certificateChain,
(Text
"Tags" Text -> NonEmpty Tag -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (NonEmpty Tag -> Pair) -> Maybe (NonEmpty Tag) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty Tag)
tags,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Certificate" Text -> Base64 -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Base64
certificate),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"PrivateKey" Text -> Sensitive Base64 -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Sensitive Base64
privateKey)
]
)
instance Core.ToPath ImportCertificate where
toPath :: ImportCertificate -> ByteString
toPath = ByteString -> ImportCertificate -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ImportCertificate where
toQuery :: ImportCertificate -> QueryString
toQuery = QueryString -> ImportCertificate -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ImportCertificateResponse = ImportCertificateResponse'
{
ImportCertificateResponse -> Maybe Text
certificateArn :: Prelude.Maybe Prelude.Text,
ImportCertificateResponse -> Int
httpStatus :: Prelude.Int
}
deriving (ImportCertificateResponse -> ImportCertificateResponse -> Bool
(ImportCertificateResponse -> ImportCertificateResponse -> Bool)
-> (ImportCertificateResponse -> ImportCertificateResponse -> Bool)
-> Eq ImportCertificateResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ImportCertificateResponse -> ImportCertificateResponse -> Bool
$c/= :: ImportCertificateResponse -> ImportCertificateResponse -> Bool
== :: ImportCertificateResponse -> ImportCertificateResponse -> Bool
$c== :: ImportCertificateResponse -> ImportCertificateResponse -> Bool
Prelude.Eq, ReadPrec [ImportCertificateResponse]
ReadPrec ImportCertificateResponse
Int -> ReadS ImportCertificateResponse
ReadS [ImportCertificateResponse]
(Int -> ReadS ImportCertificateResponse)
-> ReadS [ImportCertificateResponse]
-> ReadPrec ImportCertificateResponse
-> ReadPrec [ImportCertificateResponse]
-> Read ImportCertificateResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ImportCertificateResponse]
$creadListPrec :: ReadPrec [ImportCertificateResponse]
readPrec :: ReadPrec ImportCertificateResponse
$creadPrec :: ReadPrec ImportCertificateResponse
readList :: ReadS [ImportCertificateResponse]
$creadList :: ReadS [ImportCertificateResponse]
readsPrec :: Int -> ReadS ImportCertificateResponse
$creadsPrec :: Int -> ReadS ImportCertificateResponse
Prelude.Read, Int -> ImportCertificateResponse -> ShowS
[ImportCertificateResponse] -> ShowS
ImportCertificateResponse -> String
(Int -> ImportCertificateResponse -> ShowS)
-> (ImportCertificateResponse -> String)
-> ([ImportCertificateResponse] -> ShowS)
-> Show ImportCertificateResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ImportCertificateResponse] -> ShowS
$cshowList :: [ImportCertificateResponse] -> ShowS
show :: ImportCertificateResponse -> String
$cshow :: ImportCertificateResponse -> String
showsPrec :: Int -> ImportCertificateResponse -> ShowS
$cshowsPrec :: Int -> ImportCertificateResponse -> ShowS
Prelude.Show, (forall x.
ImportCertificateResponse -> Rep ImportCertificateResponse x)
-> (forall x.
Rep ImportCertificateResponse x -> ImportCertificateResponse)
-> Generic ImportCertificateResponse
forall x.
Rep ImportCertificateResponse x -> ImportCertificateResponse
forall x.
ImportCertificateResponse -> Rep ImportCertificateResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ImportCertificateResponse x -> ImportCertificateResponse
$cfrom :: forall x.
ImportCertificateResponse -> Rep ImportCertificateResponse x
Prelude.Generic)
newImportCertificateResponse ::
Prelude.Int ->
ImportCertificateResponse
newImportCertificateResponse :: Int -> ImportCertificateResponse
newImportCertificateResponse Int
pHttpStatus_ =
ImportCertificateResponse' :: Maybe Text -> Int -> ImportCertificateResponse
ImportCertificateResponse'
{ $sel:certificateArn:ImportCertificateResponse' :: Maybe Text
certificateArn =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ImportCertificateResponse' :: Int
httpStatus = Int
pHttpStatus_
}
importCertificateResponse_certificateArn :: Lens.Lens' ImportCertificateResponse (Prelude.Maybe Prelude.Text)
importCertificateResponse_certificateArn :: (Maybe Text -> f (Maybe Text))
-> ImportCertificateResponse -> f ImportCertificateResponse
importCertificateResponse_certificateArn = (ImportCertificateResponse -> Maybe Text)
-> (ImportCertificateResponse
-> Maybe Text -> ImportCertificateResponse)
-> Lens
ImportCertificateResponse
ImportCertificateResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificateResponse' {Maybe Text
certificateArn :: Maybe Text
$sel:certificateArn:ImportCertificateResponse' :: ImportCertificateResponse -> Maybe Text
certificateArn} -> Maybe Text
certificateArn) (\s :: ImportCertificateResponse
s@ImportCertificateResponse' {} Maybe Text
a -> ImportCertificateResponse
s {$sel:certificateArn:ImportCertificateResponse' :: Maybe Text
certificateArn = Maybe Text
a} :: ImportCertificateResponse)
importCertificateResponse_httpStatus :: Lens.Lens' ImportCertificateResponse Prelude.Int
importCertificateResponse_httpStatus :: (Int -> f Int)
-> ImportCertificateResponse -> f ImportCertificateResponse
importCertificateResponse_httpStatus = (ImportCertificateResponse -> Int)
-> (ImportCertificateResponse -> Int -> ImportCertificateResponse)
-> Lens ImportCertificateResponse ImportCertificateResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportCertificateResponse' {Int
httpStatus :: Int
$sel:httpStatus:ImportCertificateResponse' :: ImportCertificateResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ImportCertificateResponse
s@ImportCertificateResponse' {} Int
a -> ImportCertificateResponse
s {$sel:httpStatus:ImportCertificateResponse' :: Int
httpStatus = Int
a} :: ImportCertificateResponse)
instance Prelude.NFData ImportCertificateResponse