{-# 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.Signer.PutSigningProfile
(
PutSigningProfile (..),
newPutSigningProfile,
putSigningProfile_overrides,
putSigningProfile_signingMaterial,
putSigningProfile_signatureValidityPeriod,
putSigningProfile_signingParameters,
putSigningProfile_tags,
putSigningProfile_profileName,
putSigningProfile_platformId,
PutSigningProfileResponse (..),
newPutSigningProfileResponse,
putSigningProfileResponse_arn,
putSigningProfileResponse_profileVersion,
putSigningProfileResponse_profileVersionArn,
putSigningProfileResponse_httpStatus,
)
where
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
import Amazonka.Signer.Types
data PutSigningProfile = PutSigningProfile'
{
PutSigningProfile -> Maybe SigningPlatformOverrides
overrides :: Prelude.Maybe SigningPlatformOverrides,
PutSigningProfile -> Maybe SigningMaterial
signingMaterial :: Prelude.Maybe SigningMaterial,
PutSigningProfile -> Maybe SignatureValidityPeriod
signatureValidityPeriod :: Prelude.Maybe SignatureValidityPeriod,
PutSigningProfile -> Maybe (HashMap Text Text)
signingParameters :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
PutSigningProfile -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
PutSigningProfile -> Text
profileName :: Prelude.Text,
PutSigningProfile -> Text
platformId :: Prelude.Text
}
deriving (PutSigningProfile -> PutSigningProfile -> Bool
(PutSigningProfile -> PutSigningProfile -> Bool)
-> (PutSigningProfile -> PutSigningProfile -> Bool)
-> Eq PutSigningProfile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutSigningProfile -> PutSigningProfile -> Bool
$c/= :: PutSigningProfile -> PutSigningProfile -> Bool
== :: PutSigningProfile -> PutSigningProfile -> Bool
$c== :: PutSigningProfile -> PutSigningProfile -> Bool
Prelude.Eq, ReadPrec [PutSigningProfile]
ReadPrec PutSigningProfile
Int -> ReadS PutSigningProfile
ReadS [PutSigningProfile]
(Int -> ReadS PutSigningProfile)
-> ReadS [PutSigningProfile]
-> ReadPrec PutSigningProfile
-> ReadPrec [PutSigningProfile]
-> Read PutSigningProfile
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PutSigningProfile]
$creadListPrec :: ReadPrec [PutSigningProfile]
readPrec :: ReadPrec PutSigningProfile
$creadPrec :: ReadPrec PutSigningProfile
readList :: ReadS [PutSigningProfile]
$creadList :: ReadS [PutSigningProfile]
readsPrec :: Int -> ReadS PutSigningProfile
$creadsPrec :: Int -> ReadS PutSigningProfile
Prelude.Read, Int -> PutSigningProfile -> ShowS
[PutSigningProfile] -> ShowS
PutSigningProfile -> String
(Int -> PutSigningProfile -> ShowS)
-> (PutSigningProfile -> String)
-> ([PutSigningProfile] -> ShowS)
-> Show PutSigningProfile
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutSigningProfile] -> ShowS
$cshowList :: [PutSigningProfile] -> ShowS
show :: PutSigningProfile -> String
$cshow :: PutSigningProfile -> String
showsPrec :: Int -> PutSigningProfile -> ShowS
$cshowsPrec :: Int -> PutSigningProfile -> ShowS
Prelude.Show, (forall x. PutSigningProfile -> Rep PutSigningProfile x)
-> (forall x. Rep PutSigningProfile x -> PutSigningProfile)
-> Generic PutSigningProfile
forall x. Rep PutSigningProfile x -> PutSigningProfile
forall x. PutSigningProfile -> Rep PutSigningProfile x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep PutSigningProfile x -> PutSigningProfile
$cfrom :: forall x. PutSigningProfile -> Rep PutSigningProfile x
Prelude.Generic)
newPutSigningProfile ::
Prelude.Text ->
Prelude.Text ->
PutSigningProfile
newPutSigningProfile :: Text -> Text -> PutSigningProfile
newPutSigningProfile Text
pProfileName_ Text
pPlatformId_ =
PutSigningProfile' :: Maybe SigningPlatformOverrides
-> Maybe SigningMaterial
-> Maybe SignatureValidityPeriod
-> Maybe (HashMap Text Text)
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> PutSigningProfile
PutSigningProfile'
{ $sel:overrides:PutSigningProfile' :: Maybe SigningPlatformOverrides
overrides = Maybe SigningPlatformOverrides
forall a. Maybe a
Prelude.Nothing,
$sel:signingMaterial:PutSigningProfile' :: Maybe SigningMaterial
signingMaterial = Maybe SigningMaterial
forall a. Maybe a
Prelude.Nothing,
$sel:signatureValidityPeriod:PutSigningProfile' :: Maybe SignatureValidityPeriod
signatureValidityPeriod = Maybe SignatureValidityPeriod
forall a. Maybe a
Prelude.Nothing,
$sel:signingParameters:PutSigningProfile' :: Maybe (HashMap Text Text)
signingParameters = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:tags:PutSigningProfile' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:profileName:PutSigningProfile' :: Text
profileName = Text
pProfileName_,
$sel:platformId:PutSigningProfile' :: Text
platformId = Text
pPlatformId_
}
putSigningProfile_overrides :: Lens.Lens' PutSigningProfile (Prelude.Maybe SigningPlatformOverrides)
putSigningProfile_overrides :: (Maybe SigningPlatformOverrides
-> f (Maybe SigningPlatformOverrides))
-> PutSigningProfile -> f PutSigningProfile
putSigningProfile_overrides = (PutSigningProfile -> Maybe SigningPlatformOverrides)
-> (PutSigningProfile
-> Maybe SigningPlatformOverrides -> PutSigningProfile)
-> Lens
PutSigningProfile
PutSigningProfile
(Maybe SigningPlatformOverrides)
(Maybe SigningPlatformOverrides)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Maybe SigningPlatformOverrides
overrides :: Maybe SigningPlatformOverrides
$sel:overrides:PutSigningProfile' :: PutSigningProfile -> Maybe SigningPlatformOverrides
overrides} -> Maybe SigningPlatformOverrides
overrides) (\s :: PutSigningProfile
s@PutSigningProfile' {} Maybe SigningPlatformOverrides
a -> PutSigningProfile
s {$sel:overrides:PutSigningProfile' :: Maybe SigningPlatformOverrides
overrides = Maybe SigningPlatformOverrides
a} :: PutSigningProfile)
putSigningProfile_signingMaterial :: Lens.Lens' PutSigningProfile (Prelude.Maybe SigningMaterial)
putSigningProfile_signingMaterial :: (Maybe SigningMaterial -> f (Maybe SigningMaterial))
-> PutSigningProfile -> f PutSigningProfile
putSigningProfile_signingMaterial = (PutSigningProfile -> Maybe SigningMaterial)
-> (PutSigningProfile
-> Maybe SigningMaterial -> PutSigningProfile)
-> Lens
PutSigningProfile
PutSigningProfile
(Maybe SigningMaterial)
(Maybe SigningMaterial)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Maybe SigningMaterial
signingMaterial :: Maybe SigningMaterial
$sel:signingMaterial:PutSigningProfile' :: PutSigningProfile -> Maybe SigningMaterial
signingMaterial} -> Maybe SigningMaterial
signingMaterial) (\s :: PutSigningProfile
s@PutSigningProfile' {} Maybe SigningMaterial
a -> PutSigningProfile
s {$sel:signingMaterial:PutSigningProfile' :: Maybe SigningMaterial
signingMaterial = Maybe SigningMaterial
a} :: PutSigningProfile)
putSigningProfile_signatureValidityPeriod :: Lens.Lens' PutSigningProfile (Prelude.Maybe SignatureValidityPeriod)
putSigningProfile_signatureValidityPeriod :: (Maybe SignatureValidityPeriod
-> f (Maybe SignatureValidityPeriod))
-> PutSigningProfile -> f PutSigningProfile
putSigningProfile_signatureValidityPeriod = (PutSigningProfile -> Maybe SignatureValidityPeriod)
-> (PutSigningProfile
-> Maybe SignatureValidityPeriod -> PutSigningProfile)
-> Lens
PutSigningProfile
PutSigningProfile
(Maybe SignatureValidityPeriod)
(Maybe SignatureValidityPeriod)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Maybe SignatureValidityPeriod
signatureValidityPeriod :: Maybe SignatureValidityPeriod
$sel:signatureValidityPeriod:PutSigningProfile' :: PutSigningProfile -> Maybe SignatureValidityPeriod
signatureValidityPeriod} -> Maybe SignatureValidityPeriod
signatureValidityPeriod) (\s :: PutSigningProfile
s@PutSigningProfile' {} Maybe SignatureValidityPeriod
a -> PutSigningProfile
s {$sel:signatureValidityPeriod:PutSigningProfile' :: Maybe SignatureValidityPeriod
signatureValidityPeriod = Maybe SignatureValidityPeriod
a} :: PutSigningProfile)
putSigningProfile_signingParameters :: Lens.Lens' PutSigningProfile (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
putSigningProfile_signingParameters :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile -> f PutSigningProfile
putSigningProfile_signingParameters = (PutSigningProfile -> Maybe (HashMap Text Text))
-> (PutSigningProfile
-> Maybe (HashMap Text Text) -> PutSigningProfile)
-> Lens
PutSigningProfile
PutSigningProfile
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Maybe (HashMap Text Text)
signingParameters :: Maybe (HashMap Text Text)
$sel:signingParameters:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
signingParameters} -> Maybe (HashMap Text Text)
signingParameters) (\s :: PutSigningProfile
s@PutSigningProfile' {} Maybe (HashMap Text Text)
a -> PutSigningProfile
s {$sel:signingParameters:PutSigningProfile' :: Maybe (HashMap Text Text)
signingParameters = Maybe (HashMap Text Text)
a} :: PutSigningProfile) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile -> f PutSigningProfile)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile
-> f PutSigningProfile
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (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
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
putSigningProfile_tags :: Lens.Lens' PutSigningProfile (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
putSigningProfile_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile -> f PutSigningProfile
putSigningProfile_tags = (PutSigningProfile -> Maybe (HashMap Text Text))
-> (PutSigningProfile
-> Maybe (HashMap Text Text) -> PutSigningProfile)
-> Lens
PutSigningProfile
PutSigningProfile
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: PutSigningProfile
s@PutSigningProfile' {} Maybe (HashMap Text Text)
a -> PutSigningProfile
s {$sel:tags:PutSigningProfile' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: PutSigningProfile) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile -> f PutSigningProfile)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> PutSigningProfile
-> f PutSigningProfile
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (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
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
putSigningProfile_profileName :: Lens.Lens' PutSigningProfile Prelude.Text
putSigningProfile_profileName :: (Text -> f Text) -> PutSigningProfile -> f PutSigningProfile
putSigningProfile_profileName = (PutSigningProfile -> Text)
-> (PutSigningProfile -> Text -> PutSigningProfile)
-> Lens PutSigningProfile PutSigningProfile Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Text
profileName :: Text
$sel:profileName:PutSigningProfile' :: PutSigningProfile -> Text
profileName} -> Text
profileName) (\s :: PutSigningProfile
s@PutSigningProfile' {} Text
a -> PutSigningProfile
s {$sel:profileName:PutSigningProfile' :: Text
profileName = Text
a} :: PutSigningProfile)
putSigningProfile_platformId :: Lens.Lens' PutSigningProfile Prelude.Text
putSigningProfile_platformId :: (Text -> f Text) -> PutSigningProfile -> f PutSigningProfile
putSigningProfile_platformId = (PutSigningProfile -> Text)
-> (PutSigningProfile -> Text -> PutSigningProfile)
-> Lens PutSigningProfile PutSigningProfile Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfile' {Text
platformId :: Text
$sel:platformId:PutSigningProfile' :: PutSigningProfile -> Text
platformId} -> Text
platformId) (\s :: PutSigningProfile
s@PutSigningProfile' {} Text
a -> PutSigningProfile
s {$sel:platformId:PutSigningProfile' :: Text
platformId = Text
a} :: PutSigningProfile)
instance Core.AWSRequest PutSigningProfile where
type
AWSResponse PutSigningProfile =
PutSigningProfileResponse
request :: PutSigningProfile -> Request PutSigningProfile
request = Service -> PutSigningProfile -> Request PutSigningProfile
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.putJSON Service
defaultService
response :: Logger
-> Service
-> Proxy PutSigningProfile
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse PutSigningProfile)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse PutSigningProfile))
-> Logger
-> Service
-> Proxy PutSigningProfile
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse PutSigningProfile)))
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
-> Maybe Text -> Maybe Text -> Int -> PutSigningProfileResponse
PutSigningProfileResponse'
(Maybe Text
-> Maybe Text -> Maybe Text -> Int -> PutSigningProfileResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text -> Maybe Text -> Int -> PutSigningProfileResponse)
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
"arn")
Either
String
(Maybe Text -> Maybe Text -> Int -> PutSigningProfileResponse)
-> Either String (Maybe Text)
-> Either String (Maybe Text -> Int -> PutSigningProfileResponse)
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
"profileVersion")
Either String (Maybe Text -> Int -> PutSigningProfileResponse)
-> Either String (Maybe Text)
-> Either String (Int -> PutSigningProfileResponse)
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
"profileVersionArn")
Either String (Int -> PutSigningProfileResponse)
-> Either String Int -> Either String PutSigningProfileResponse
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 PutSigningProfile
instance Prelude.NFData PutSigningProfile
instance Core.ToHeaders PutSigningProfile where
toHeaders :: PutSigningProfile -> ResponseHeaders
toHeaders =
ResponseHeaders -> PutSigningProfile -> 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.ToJSON PutSigningProfile where
toJSON :: PutSigningProfile -> Value
toJSON PutSigningProfile' {Maybe (HashMap Text Text)
Maybe SigningMaterial
Maybe SigningPlatformOverrides
Maybe SignatureValidityPeriod
Text
platformId :: Text
profileName :: Text
tags :: Maybe (HashMap Text Text)
signingParameters :: Maybe (HashMap Text Text)
signatureValidityPeriod :: Maybe SignatureValidityPeriod
signingMaterial :: Maybe SigningMaterial
overrides :: Maybe SigningPlatformOverrides
$sel:platformId:PutSigningProfile' :: PutSigningProfile -> Text
$sel:profileName:PutSigningProfile' :: PutSigningProfile -> Text
$sel:tags:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
$sel:signingParameters:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
$sel:signatureValidityPeriod:PutSigningProfile' :: PutSigningProfile -> Maybe SignatureValidityPeriod
$sel:signingMaterial:PutSigningProfile' :: PutSigningProfile -> Maybe SigningMaterial
$sel:overrides:PutSigningProfile' :: PutSigningProfile -> Maybe SigningPlatformOverrides
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"overrides" Text -> SigningPlatformOverrides -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (SigningPlatformOverrides -> Pair)
-> Maybe SigningPlatformOverrides -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SigningPlatformOverrides
overrides,
(Text
"signingMaterial" Text -> SigningMaterial -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(SigningMaterial -> Pair) -> Maybe SigningMaterial -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SigningMaterial
signingMaterial,
(Text
"signatureValidityPeriod" Text -> SignatureValidityPeriod -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(SignatureValidityPeriod -> Pair)
-> Maybe SignatureValidityPeriod -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SignatureValidityPeriod
signatureValidityPeriod,
(Text
"signingParameters" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
signingParameters,
(Text
"tags" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
tags,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"platformId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
platformId)
]
)
instance Core.ToPath PutSigningProfile where
toPath :: PutSigningProfile -> ByteString
toPath PutSigningProfile' {Maybe (HashMap Text Text)
Maybe SigningMaterial
Maybe SigningPlatformOverrides
Maybe SignatureValidityPeriod
Text
platformId :: Text
profileName :: Text
tags :: Maybe (HashMap Text Text)
signingParameters :: Maybe (HashMap Text Text)
signatureValidityPeriod :: Maybe SignatureValidityPeriod
signingMaterial :: Maybe SigningMaterial
overrides :: Maybe SigningPlatformOverrides
$sel:platformId:PutSigningProfile' :: PutSigningProfile -> Text
$sel:profileName:PutSigningProfile' :: PutSigningProfile -> Text
$sel:tags:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
$sel:signingParameters:PutSigningProfile' :: PutSigningProfile -> Maybe (HashMap Text Text)
$sel:signatureValidityPeriod:PutSigningProfile' :: PutSigningProfile -> Maybe SignatureValidityPeriod
$sel:signingMaterial:PutSigningProfile' :: PutSigningProfile -> Maybe SigningMaterial
$sel:overrides:PutSigningProfile' :: PutSigningProfile -> Maybe SigningPlatformOverrides
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ByteString
"/signing-profiles/", Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
profileName]
instance Core.ToQuery PutSigningProfile where
toQuery :: PutSigningProfile -> QueryString
toQuery = QueryString -> PutSigningProfile -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data PutSigningProfileResponse = PutSigningProfileResponse'
{
PutSigningProfileResponse -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
PutSigningProfileResponse -> Maybe Text
profileVersion :: Prelude.Maybe Prelude.Text,
PutSigningProfileResponse -> Maybe Text
profileVersionArn :: Prelude.Maybe Prelude.Text,
PutSigningProfileResponse -> Int
httpStatus :: Prelude.Int
}
deriving (PutSigningProfileResponse -> PutSigningProfileResponse -> Bool
(PutSigningProfileResponse -> PutSigningProfileResponse -> Bool)
-> (PutSigningProfileResponse -> PutSigningProfileResponse -> Bool)
-> Eq PutSigningProfileResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutSigningProfileResponse -> PutSigningProfileResponse -> Bool
$c/= :: PutSigningProfileResponse -> PutSigningProfileResponse -> Bool
== :: PutSigningProfileResponse -> PutSigningProfileResponse -> Bool
$c== :: PutSigningProfileResponse -> PutSigningProfileResponse -> Bool
Prelude.Eq, ReadPrec [PutSigningProfileResponse]
ReadPrec PutSigningProfileResponse
Int -> ReadS PutSigningProfileResponse
ReadS [PutSigningProfileResponse]
(Int -> ReadS PutSigningProfileResponse)
-> ReadS [PutSigningProfileResponse]
-> ReadPrec PutSigningProfileResponse
-> ReadPrec [PutSigningProfileResponse]
-> Read PutSigningProfileResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PutSigningProfileResponse]
$creadListPrec :: ReadPrec [PutSigningProfileResponse]
readPrec :: ReadPrec PutSigningProfileResponse
$creadPrec :: ReadPrec PutSigningProfileResponse
readList :: ReadS [PutSigningProfileResponse]
$creadList :: ReadS [PutSigningProfileResponse]
readsPrec :: Int -> ReadS PutSigningProfileResponse
$creadsPrec :: Int -> ReadS PutSigningProfileResponse
Prelude.Read, Int -> PutSigningProfileResponse -> ShowS
[PutSigningProfileResponse] -> ShowS
PutSigningProfileResponse -> String
(Int -> PutSigningProfileResponse -> ShowS)
-> (PutSigningProfileResponse -> String)
-> ([PutSigningProfileResponse] -> ShowS)
-> Show PutSigningProfileResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutSigningProfileResponse] -> ShowS
$cshowList :: [PutSigningProfileResponse] -> ShowS
show :: PutSigningProfileResponse -> String
$cshow :: PutSigningProfileResponse -> String
showsPrec :: Int -> PutSigningProfileResponse -> ShowS
$cshowsPrec :: Int -> PutSigningProfileResponse -> ShowS
Prelude.Show, (forall x.
PutSigningProfileResponse -> Rep PutSigningProfileResponse x)
-> (forall x.
Rep PutSigningProfileResponse x -> PutSigningProfileResponse)
-> Generic PutSigningProfileResponse
forall x.
Rep PutSigningProfileResponse x -> PutSigningProfileResponse
forall x.
PutSigningProfileResponse -> Rep PutSigningProfileResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PutSigningProfileResponse x -> PutSigningProfileResponse
$cfrom :: forall x.
PutSigningProfileResponse -> Rep PutSigningProfileResponse x
Prelude.Generic)
newPutSigningProfileResponse ::
Prelude.Int ->
PutSigningProfileResponse
newPutSigningProfileResponse :: Int -> PutSigningProfileResponse
newPutSigningProfileResponse Int
pHttpStatus_ =
PutSigningProfileResponse' :: Maybe Text
-> Maybe Text -> Maybe Text -> Int -> PutSigningProfileResponse
PutSigningProfileResponse'
{ $sel:arn:PutSigningProfileResponse' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:profileVersion:PutSigningProfileResponse' :: Maybe Text
profileVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:profileVersionArn:PutSigningProfileResponse' :: Maybe Text
profileVersionArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:PutSigningProfileResponse' :: Int
httpStatus = Int
pHttpStatus_
}
putSigningProfileResponse_arn :: Lens.Lens' PutSigningProfileResponse (Prelude.Maybe Prelude.Text)
putSigningProfileResponse_arn :: (Maybe Text -> f (Maybe Text))
-> PutSigningProfileResponse -> f PutSigningProfileResponse
putSigningProfileResponse_arn = (PutSigningProfileResponse -> Maybe Text)
-> (PutSigningProfileResponse
-> Maybe Text -> PutSigningProfileResponse)
-> Lens
PutSigningProfileResponse
PutSigningProfileResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfileResponse' {Maybe Text
arn :: Maybe Text
$sel:arn:PutSigningProfileResponse' :: PutSigningProfileResponse -> Maybe Text
arn} -> Maybe Text
arn) (\s :: PutSigningProfileResponse
s@PutSigningProfileResponse' {} Maybe Text
a -> PutSigningProfileResponse
s {$sel:arn:PutSigningProfileResponse' :: Maybe Text
arn = Maybe Text
a} :: PutSigningProfileResponse)
putSigningProfileResponse_profileVersion :: Lens.Lens' PutSigningProfileResponse (Prelude.Maybe Prelude.Text)
putSigningProfileResponse_profileVersion :: (Maybe Text -> f (Maybe Text))
-> PutSigningProfileResponse -> f PutSigningProfileResponse
putSigningProfileResponse_profileVersion = (PutSigningProfileResponse -> Maybe Text)
-> (PutSigningProfileResponse
-> Maybe Text -> PutSigningProfileResponse)
-> Lens
PutSigningProfileResponse
PutSigningProfileResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfileResponse' {Maybe Text
profileVersion :: Maybe Text
$sel:profileVersion:PutSigningProfileResponse' :: PutSigningProfileResponse -> Maybe Text
profileVersion} -> Maybe Text
profileVersion) (\s :: PutSigningProfileResponse
s@PutSigningProfileResponse' {} Maybe Text
a -> PutSigningProfileResponse
s {$sel:profileVersion:PutSigningProfileResponse' :: Maybe Text
profileVersion = Maybe Text
a} :: PutSigningProfileResponse)
putSigningProfileResponse_profileVersionArn :: Lens.Lens' PutSigningProfileResponse (Prelude.Maybe Prelude.Text)
putSigningProfileResponse_profileVersionArn :: (Maybe Text -> f (Maybe Text))
-> PutSigningProfileResponse -> f PutSigningProfileResponse
putSigningProfileResponse_profileVersionArn = (PutSigningProfileResponse -> Maybe Text)
-> (PutSigningProfileResponse
-> Maybe Text -> PutSigningProfileResponse)
-> Lens
PutSigningProfileResponse
PutSigningProfileResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfileResponse' {Maybe Text
profileVersionArn :: Maybe Text
$sel:profileVersionArn:PutSigningProfileResponse' :: PutSigningProfileResponse -> Maybe Text
profileVersionArn} -> Maybe Text
profileVersionArn) (\s :: PutSigningProfileResponse
s@PutSigningProfileResponse' {} Maybe Text
a -> PutSigningProfileResponse
s {$sel:profileVersionArn:PutSigningProfileResponse' :: Maybe Text
profileVersionArn = Maybe Text
a} :: PutSigningProfileResponse)
putSigningProfileResponse_httpStatus :: Lens.Lens' PutSigningProfileResponse Prelude.Int
putSigningProfileResponse_httpStatus :: (Int -> f Int)
-> PutSigningProfileResponse -> f PutSigningProfileResponse
putSigningProfileResponse_httpStatus = (PutSigningProfileResponse -> Int)
-> (PutSigningProfileResponse -> Int -> PutSigningProfileResponse)
-> Lens PutSigningProfileResponse PutSigningProfileResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutSigningProfileResponse' {Int
httpStatus :: Int
$sel:httpStatus:PutSigningProfileResponse' :: PutSigningProfileResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: PutSigningProfileResponse
s@PutSigningProfileResponse' {} Int
a -> PutSigningProfileResponse
s {$sel:httpStatus:PutSigningProfileResponse' :: Int
httpStatus = Int
a} :: PutSigningProfileResponse)
instance Prelude.NFData PutSigningProfileResponse