{-# 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.Config.PutOrganizationConformancePack
(
PutOrganizationConformancePack (..),
newPutOrganizationConformancePack,
putOrganizationConformancePack_deliveryS3Bucket,
putOrganizationConformancePack_deliveryS3KeyPrefix,
putOrganizationConformancePack_templateS3Uri,
putOrganizationConformancePack_conformancePackInputParameters,
putOrganizationConformancePack_excludedAccounts,
putOrganizationConformancePack_templateBody,
putOrganizationConformancePack_organizationConformancePackName,
PutOrganizationConformancePackResponse (..),
newPutOrganizationConformancePackResponse,
putOrganizationConformancePackResponse_organizationConformancePackArn,
putOrganizationConformancePackResponse_httpStatus,
)
where
import Amazonka.Config.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 PutOrganizationConformancePack = PutOrganizationConformancePack'
{
PutOrganizationConformancePack -> Maybe Text
deliveryS3Bucket :: Prelude.Maybe Prelude.Text,
PutOrganizationConformancePack -> Maybe Text
deliveryS3KeyPrefix :: Prelude.Maybe Prelude.Text,
PutOrganizationConformancePack -> Maybe Text
templateS3Uri :: Prelude.Maybe Prelude.Text,
PutOrganizationConformancePack
-> Maybe [ConformancePackInputParameter]
conformancePackInputParameters :: Prelude.Maybe [ConformancePackInputParameter],
PutOrganizationConformancePack -> Maybe [Text]
excludedAccounts :: Prelude.Maybe [Prelude.Text],
PutOrganizationConformancePack -> Maybe Text
templateBody :: Prelude.Maybe Prelude.Text,
PutOrganizationConformancePack -> Text
organizationConformancePackName :: Prelude.Text
}
deriving (PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool
(PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool)
-> (PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool)
-> Eq PutOrganizationConformancePack
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool
$c/= :: PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool
== :: PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool
$c== :: PutOrganizationConformancePack
-> PutOrganizationConformancePack -> Bool
Prelude.Eq, ReadPrec [PutOrganizationConformancePack]
ReadPrec PutOrganizationConformancePack
Int -> ReadS PutOrganizationConformancePack
ReadS [PutOrganizationConformancePack]
(Int -> ReadS PutOrganizationConformancePack)
-> ReadS [PutOrganizationConformancePack]
-> ReadPrec PutOrganizationConformancePack
-> ReadPrec [PutOrganizationConformancePack]
-> Read PutOrganizationConformancePack
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PutOrganizationConformancePack]
$creadListPrec :: ReadPrec [PutOrganizationConformancePack]
readPrec :: ReadPrec PutOrganizationConformancePack
$creadPrec :: ReadPrec PutOrganizationConformancePack
readList :: ReadS [PutOrganizationConformancePack]
$creadList :: ReadS [PutOrganizationConformancePack]
readsPrec :: Int -> ReadS PutOrganizationConformancePack
$creadsPrec :: Int -> ReadS PutOrganizationConformancePack
Prelude.Read, Int -> PutOrganizationConformancePack -> ShowS
[PutOrganizationConformancePack] -> ShowS
PutOrganizationConformancePack -> String
(Int -> PutOrganizationConformancePack -> ShowS)
-> (PutOrganizationConformancePack -> String)
-> ([PutOrganizationConformancePack] -> ShowS)
-> Show PutOrganizationConformancePack
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutOrganizationConformancePack] -> ShowS
$cshowList :: [PutOrganizationConformancePack] -> ShowS
show :: PutOrganizationConformancePack -> String
$cshow :: PutOrganizationConformancePack -> String
showsPrec :: Int -> PutOrganizationConformancePack -> ShowS
$cshowsPrec :: Int -> PutOrganizationConformancePack -> ShowS
Prelude.Show, (forall x.
PutOrganizationConformancePack
-> Rep PutOrganizationConformancePack x)
-> (forall x.
Rep PutOrganizationConformancePack x
-> PutOrganizationConformancePack)
-> Generic PutOrganizationConformancePack
forall x.
Rep PutOrganizationConformancePack x
-> PutOrganizationConformancePack
forall x.
PutOrganizationConformancePack
-> Rep PutOrganizationConformancePack x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PutOrganizationConformancePack x
-> PutOrganizationConformancePack
$cfrom :: forall x.
PutOrganizationConformancePack
-> Rep PutOrganizationConformancePack x
Prelude.Generic)
newPutOrganizationConformancePack ::
Prelude.Text ->
PutOrganizationConformancePack
newPutOrganizationConformancePack :: Text -> PutOrganizationConformancePack
newPutOrganizationConformancePack
Text
pOrganizationConformancePackName_ =
PutOrganizationConformancePack' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [ConformancePackInputParameter]
-> Maybe [Text]
-> Maybe Text
-> Text
-> PutOrganizationConformancePack
PutOrganizationConformancePack'
{ $sel:deliveryS3Bucket:PutOrganizationConformancePack' :: Maybe Text
deliveryS3Bucket =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:deliveryS3KeyPrefix:PutOrganizationConformancePack' :: Maybe Text
deliveryS3KeyPrefix = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:templateS3Uri:PutOrganizationConformancePack' :: Maybe Text
templateS3Uri = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:conformancePackInputParameters:PutOrganizationConformancePack' :: Maybe [ConformancePackInputParameter]
conformancePackInputParameters =
Maybe [ConformancePackInputParameter]
forall a. Maybe a
Prelude.Nothing,
$sel:excludedAccounts:PutOrganizationConformancePack' :: Maybe [Text]
excludedAccounts = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:templateBody:PutOrganizationConformancePack' :: Maybe Text
templateBody = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:organizationConformancePackName:PutOrganizationConformancePack' :: Text
organizationConformancePackName =
Text
pOrganizationConformancePackName_
}
putOrganizationConformancePack_deliveryS3Bucket :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe Prelude.Text)
putOrganizationConformancePack_deliveryS3Bucket :: (Maybe Text -> f (Maybe Text))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_deliveryS3Bucket = (PutOrganizationConformancePack -> Maybe Text)
-> (PutOrganizationConformancePack
-> Maybe Text -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe Text
deliveryS3Bucket :: Maybe Text
$sel:deliveryS3Bucket:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
deliveryS3Bucket} -> Maybe Text
deliveryS3Bucket) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe Text
a -> PutOrganizationConformancePack
s {$sel:deliveryS3Bucket:PutOrganizationConformancePack' :: Maybe Text
deliveryS3Bucket = Maybe Text
a} :: PutOrganizationConformancePack)
putOrganizationConformancePack_deliveryS3KeyPrefix :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe Prelude.Text)
putOrganizationConformancePack_deliveryS3KeyPrefix :: (Maybe Text -> f (Maybe Text))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_deliveryS3KeyPrefix = (PutOrganizationConformancePack -> Maybe Text)
-> (PutOrganizationConformancePack
-> Maybe Text -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe Text
deliveryS3KeyPrefix :: Maybe Text
$sel:deliveryS3KeyPrefix:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
deliveryS3KeyPrefix} -> Maybe Text
deliveryS3KeyPrefix) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe Text
a -> PutOrganizationConformancePack
s {$sel:deliveryS3KeyPrefix:PutOrganizationConformancePack' :: Maybe Text
deliveryS3KeyPrefix = Maybe Text
a} :: PutOrganizationConformancePack)
putOrganizationConformancePack_templateS3Uri :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe Prelude.Text)
putOrganizationConformancePack_templateS3Uri :: (Maybe Text -> f (Maybe Text))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_templateS3Uri = (PutOrganizationConformancePack -> Maybe Text)
-> (PutOrganizationConformancePack
-> Maybe Text -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe Text
templateS3Uri :: Maybe Text
$sel:templateS3Uri:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
templateS3Uri} -> Maybe Text
templateS3Uri) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe Text
a -> PutOrganizationConformancePack
s {$sel:templateS3Uri:PutOrganizationConformancePack' :: Maybe Text
templateS3Uri = Maybe Text
a} :: PutOrganizationConformancePack)
putOrganizationConformancePack_conformancePackInputParameters :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe [ConformancePackInputParameter])
putOrganizationConformancePack_conformancePackInputParameters :: (Maybe [ConformancePackInputParameter]
-> f (Maybe [ConformancePackInputParameter]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_conformancePackInputParameters = (PutOrganizationConformancePack
-> Maybe [ConformancePackInputParameter])
-> (PutOrganizationConformancePack
-> Maybe [ConformancePackInputParameter]
-> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe [ConformancePackInputParameter])
(Maybe [ConformancePackInputParameter])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe [ConformancePackInputParameter]
conformancePackInputParameters :: Maybe [ConformancePackInputParameter]
$sel:conformancePackInputParameters:PutOrganizationConformancePack' :: PutOrganizationConformancePack
-> Maybe [ConformancePackInputParameter]
conformancePackInputParameters} -> Maybe [ConformancePackInputParameter]
conformancePackInputParameters) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe [ConformancePackInputParameter]
a -> PutOrganizationConformancePack
s {$sel:conformancePackInputParameters:PutOrganizationConformancePack' :: Maybe [ConformancePackInputParameter]
conformancePackInputParameters = Maybe [ConformancePackInputParameter]
a} :: PutOrganizationConformancePack) ((Maybe [ConformancePackInputParameter]
-> f (Maybe [ConformancePackInputParameter]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack)
-> ((Maybe [ConformancePackInputParameter]
-> f (Maybe [ConformancePackInputParameter]))
-> Maybe [ConformancePackInputParameter]
-> f (Maybe [ConformancePackInputParameter]))
-> (Maybe [ConformancePackInputParameter]
-> f (Maybe [ConformancePackInputParameter]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[ConformancePackInputParameter]
[ConformancePackInputParameter]
[ConformancePackInputParameter]
[ConformancePackInputParameter]
-> Iso
(Maybe [ConformancePackInputParameter])
(Maybe [ConformancePackInputParameter])
(Maybe [ConformancePackInputParameter])
(Maybe [ConformancePackInputParameter])
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
[ConformancePackInputParameter]
[ConformancePackInputParameter]
[ConformancePackInputParameter]
[ConformancePackInputParameter]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
putOrganizationConformancePack_excludedAccounts :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe [Prelude.Text])
putOrganizationConformancePack_excludedAccounts :: (Maybe [Text] -> f (Maybe [Text]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_excludedAccounts = (PutOrganizationConformancePack -> Maybe [Text])
-> (PutOrganizationConformancePack
-> Maybe [Text] -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe [Text])
(Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe [Text]
excludedAccounts :: Maybe [Text]
$sel:excludedAccounts:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe [Text]
excludedAccounts} -> Maybe [Text]
excludedAccounts) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe [Text]
a -> PutOrganizationConformancePack
s {$sel:excludedAccounts:PutOrganizationConformancePack' :: Maybe [Text]
excludedAccounts = Maybe [Text]
a} :: PutOrganizationConformancePack) ((Maybe [Text] -> f (Maybe [Text]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
putOrganizationConformancePack_templateBody :: Lens.Lens' PutOrganizationConformancePack (Prelude.Maybe Prelude.Text)
putOrganizationConformancePack_templateBody :: (Maybe Text -> f (Maybe Text))
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_templateBody = (PutOrganizationConformancePack -> Maybe Text)
-> (PutOrganizationConformancePack
-> Maybe Text -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Maybe Text
templateBody :: Maybe Text
$sel:templateBody:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
templateBody} -> Maybe Text
templateBody) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Maybe Text
a -> PutOrganizationConformancePack
s {$sel:templateBody:PutOrganizationConformancePack' :: Maybe Text
templateBody = Maybe Text
a} :: PutOrganizationConformancePack)
putOrganizationConformancePack_organizationConformancePackName :: Lens.Lens' PutOrganizationConformancePack Prelude.Text
putOrganizationConformancePack_organizationConformancePackName :: (Text -> f Text)
-> PutOrganizationConformancePack
-> f PutOrganizationConformancePack
putOrganizationConformancePack_organizationConformancePackName = (PutOrganizationConformancePack -> Text)
-> (PutOrganizationConformancePack
-> Text -> PutOrganizationConformancePack)
-> Lens
PutOrganizationConformancePack
PutOrganizationConformancePack
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePack' {Text
organizationConformancePackName :: Text
$sel:organizationConformancePackName:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Text
organizationConformancePackName} -> Text
organizationConformancePackName) (\s :: PutOrganizationConformancePack
s@PutOrganizationConformancePack' {} Text
a -> PutOrganizationConformancePack
s {$sel:organizationConformancePackName:PutOrganizationConformancePack' :: Text
organizationConformancePackName = Text
a} :: PutOrganizationConformancePack)
instance
Core.AWSRequest
PutOrganizationConformancePack
where
type
AWSResponse PutOrganizationConformancePack =
PutOrganizationConformancePackResponse
request :: PutOrganizationConformancePack
-> Request PutOrganizationConformancePack
request = Service
-> PutOrganizationConformancePack
-> Request PutOrganizationConformancePack
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy PutOrganizationConformancePack
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse PutOrganizationConformancePack)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse PutOrganizationConformancePack))
-> Logger
-> Service
-> Proxy PutOrganizationConformancePack
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse PutOrganizationConformancePack)))
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 -> PutOrganizationConformancePackResponse
PutOrganizationConformancePackResponse'
(Maybe Text -> Int -> PutOrganizationConformancePackResponse)
-> Either String (Maybe Text)
-> Either String (Int -> PutOrganizationConformancePackResponse)
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
"OrganizationConformancePackArn")
Either String (Int -> PutOrganizationConformancePackResponse)
-> Either String Int
-> Either String PutOrganizationConformancePackResponse
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
PutOrganizationConformancePack
instance
Prelude.NFData
PutOrganizationConformancePack
instance
Core.ToHeaders
PutOrganizationConformancePack
where
toHeaders :: PutOrganizationConformancePack -> ResponseHeaders
toHeaders =
ResponseHeaders
-> PutOrganizationConformancePack -> 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
"StarlingDoveService.PutOrganizationConformancePack" ::
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 PutOrganizationConformancePack where
toJSON :: PutOrganizationConformancePack -> Value
toJSON PutOrganizationConformancePack' {Maybe [Text]
Maybe [ConformancePackInputParameter]
Maybe Text
Text
organizationConformancePackName :: Text
templateBody :: Maybe Text
excludedAccounts :: Maybe [Text]
conformancePackInputParameters :: Maybe [ConformancePackInputParameter]
templateS3Uri :: Maybe Text
deliveryS3KeyPrefix :: Maybe Text
deliveryS3Bucket :: Maybe Text
$sel:organizationConformancePackName:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Text
$sel:templateBody:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
$sel:excludedAccounts:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe [Text]
$sel:conformancePackInputParameters:PutOrganizationConformancePack' :: PutOrganizationConformancePack
-> Maybe [ConformancePackInputParameter]
$sel:templateS3Uri:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
$sel:deliveryS3KeyPrefix:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
$sel:deliveryS3Bucket:PutOrganizationConformancePack' :: PutOrganizationConformancePack -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"DeliveryS3Bucket" 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
deliveryS3Bucket,
(Text
"DeliveryS3KeyPrefix" 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
deliveryS3KeyPrefix,
(Text
"TemplateS3Uri" 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
templateS3Uri,
(Text
"ConformancePackInputParameters" Text -> [ConformancePackInputParameter] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
([ConformancePackInputParameter] -> Pair)
-> Maybe [ConformancePackInputParameter] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ConformancePackInputParameter]
conformancePackInputParameters,
(Text
"ExcludedAccounts" 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]
excludedAccounts,
(Text
"TemplateBody" 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
templateBody,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
( Text
"OrganizationConformancePackName"
Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
organizationConformancePackName
)
]
)
instance Core.ToPath PutOrganizationConformancePack where
toPath :: PutOrganizationConformancePack -> ByteString
toPath = ByteString -> PutOrganizationConformancePack -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery PutOrganizationConformancePack where
toQuery :: PutOrganizationConformancePack -> QueryString
toQuery = QueryString -> PutOrganizationConformancePack -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data PutOrganizationConformancePackResponse = PutOrganizationConformancePackResponse'
{
PutOrganizationConformancePackResponse -> Maybe Text
organizationConformancePackArn :: Prelude.Maybe Prelude.Text,
PutOrganizationConformancePackResponse -> Int
httpStatus :: Prelude.Int
}
deriving (PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool
(PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool)
-> (PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool)
-> Eq PutOrganizationConformancePackResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool
$c/= :: PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool
== :: PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool
$c== :: PutOrganizationConformancePackResponse
-> PutOrganizationConformancePackResponse -> Bool
Prelude.Eq, ReadPrec [PutOrganizationConformancePackResponse]
ReadPrec PutOrganizationConformancePackResponse
Int -> ReadS PutOrganizationConformancePackResponse
ReadS [PutOrganizationConformancePackResponse]
(Int -> ReadS PutOrganizationConformancePackResponse)
-> ReadS [PutOrganizationConformancePackResponse]
-> ReadPrec PutOrganizationConformancePackResponse
-> ReadPrec [PutOrganizationConformancePackResponse]
-> Read PutOrganizationConformancePackResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PutOrganizationConformancePackResponse]
$creadListPrec :: ReadPrec [PutOrganizationConformancePackResponse]
readPrec :: ReadPrec PutOrganizationConformancePackResponse
$creadPrec :: ReadPrec PutOrganizationConformancePackResponse
readList :: ReadS [PutOrganizationConformancePackResponse]
$creadList :: ReadS [PutOrganizationConformancePackResponse]
readsPrec :: Int -> ReadS PutOrganizationConformancePackResponse
$creadsPrec :: Int -> ReadS PutOrganizationConformancePackResponse
Prelude.Read, Int -> PutOrganizationConformancePackResponse -> ShowS
[PutOrganizationConformancePackResponse] -> ShowS
PutOrganizationConformancePackResponse -> String
(Int -> PutOrganizationConformancePackResponse -> ShowS)
-> (PutOrganizationConformancePackResponse -> String)
-> ([PutOrganizationConformancePackResponse] -> ShowS)
-> Show PutOrganizationConformancePackResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutOrganizationConformancePackResponse] -> ShowS
$cshowList :: [PutOrganizationConformancePackResponse] -> ShowS
show :: PutOrganizationConformancePackResponse -> String
$cshow :: PutOrganizationConformancePackResponse -> String
showsPrec :: Int -> PutOrganizationConformancePackResponse -> ShowS
$cshowsPrec :: Int -> PutOrganizationConformancePackResponse -> ShowS
Prelude.Show, (forall x.
PutOrganizationConformancePackResponse
-> Rep PutOrganizationConformancePackResponse x)
-> (forall x.
Rep PutOrganizationConformancePackResponse x
-> PutOrganizationConformancePackResponse)
-> Generic PutOrganizationConformancePackResponse
forall x.
Rep PutOrganizationConformancePackResponse x
-> PutOrganizationConformancePackResponse
forall x.
PutOrganizationConformancePackResponse
-> Rep PutOrganizationConformancePackResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PutOrganizationConformancePackResponse x
-> PutOrganizationConformancePackResponse
$cfrom :: forall x.
PutOrganizationConformancePackResponse
-> Rep PutOrganizationConformancePackResponse x
Prelude.Generic)
newPutOrganizationConformancePackResponse ::
Prelude.Int ->
PutOrganizationConformancePackResponse
newPutOrganizationConformancePackResponse :: Int -> PutOrganizationConformancePackResponse
newPutOrganizationConformancePackResponse
Int
pHttpStatus_ =
PutOrganizationConformancePackResponse' :: Maybe Text -> Int -> PutOrganizationConformancePackResponse
PutOrganizationConformancePackResponse'
{ $sel:organizationConformancePackArn:PutOrganizationConformancePackResponse' :: Maybe Text
organizationConformancePackArn =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:PutOrganizationConformancePackResponse' :: Int
httpStatus = Int
pHttpStatus_
}
putOrganizationConformancePackResponse_organizationConformancePackArn :: Lens.Lens' PutOrganizationConformancePackResponse (Prelude.Maybe Prelude.Text)
putOrganizationConformancePackResponse_organizationConformancePackArn :: (Maybe Text -> f (Maybe Text))
-> PutOrganizationConformancePackResponse
-> f PutOrganizationConformancePackResponse
putOrganizationConformancePackResponse_organizationConformancePackArn = (PutOrganizationConformancePackResponse -> Maybe Text)
-> (PutOrganizationConformancePackResponse
-> Maybe Text -> PutOrganizationConformancePackResponse)
-> Lens
PutOrganizationConformancePackResponse
PutOrganizationConformancePackResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePackResponse' {Maybe Text
organizationConformancePackArn :: Maybe Text
$sel:organizationConformancePackArn:PutOrganizationConformancePackResponse' :: PutOrganizationConformancePackResponse -> Maybe Text
organizationConformancePackArn} -> Maybe Text
organizationConformancePackArn) (\s :: PutOrganizationConformancePackResponse
s@PutOrganizationConformancePackResponse' {} Maybe Text
a -> PutOrganizationConformancePackResponse
s {$sel:organizationConformancePackArn:PutOrganizationConformancePackResponse' :: Maybe Text
organizationConformancePackArn = Maybe Text
a} :: PutOrganizationConformancePackResponse)
putOrganizationConformancePackResponse_httpStatus :: Lens.Lens' PutOrganizationConformancePackResponse Prelude.Int
putOrganizationConformancePackResponse_httpStatus :: (Int -> f Int)
-> PutOrganizationConformancePackResponse
-> f PutOrganizationConformancePackResponse
putOrganizationConformancePackResponse_httpStatus = (PutOrganizationConformancePackResponse -> Int)
-> (PutOrganizationConformancePackResponse
-> Int -> PutOrganizationConformancePackResponse)
-> Lens
PutOrganizationConformancePackResponse
PutOrganizationConformancePackResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutOrganizationConformancePackResponse' {Int
httpStatus :: Int
$sel:httpStatus:PutOrganizationConformancePackResponse' :: PutOrganizationConformancePackResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: PutOrganizationConformancePackResponse
s@PutOrganizationConformancePackResponse' {} Int
a -> PutOrganizationConformancePackResponse
s {$sel:httpStatus:PutOrganizationConformancePackResponse' :: Int
httpStatus = Int
a} :: PutOrganizationConformancePackResponse)
instance
Prelude.NFData
PutOrganizationConformancePackResponse