{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.S3.PutBucketEncryption
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- This action uses the @encryption@ subresource to configure default
-- encryption and Amazon S3 Bucket Key for an existing bucket.
--
-- Default encryption for a bucket can use server-side encryption with
-- Amazon S3-managed keys (SSE-S3) or customer managed keys (SSE-KMS). If
-- you specify default encryption using SSE-KMS, you can also configure
-- Amazon S3 Bucket Key. For information about default encryption, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html Amazon S3 default bucket encryption>
-- in the /Amazon S3 User Guide/. For more information about S3 Bucket
-- Keys, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-key.html Amazon S3 Bucket Keys>
-- in the /Amazon S3 User Guide/.
--
-- This action requires Amazon Web Services Signature Version 4. For more
-- information, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html Authenticating Requests (Amazon Web Services Signature Version 4)>.
--
-- To use this operation, you must have permissions to perform the
-- @s3:PutEncryptionConfiguration@ action. The bucket owner has this
-- permission by default. The bucket owner can grant this permission to
-- others. For more information about permissions, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources Permissions Related to Bucket Subresource Operations>
-- and
-- <https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html Managing Access Permissions to Your Amazon S3 Resources>
-- in the Amazon S3 User Guide.
--
-- __Related Resources__
--
-- -   <https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketEncryption.html GetBucketEncryption>
--
-- -   <https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketEncryption.html DeleteBucketEncryption>
module Amazonka.S3.PutBucketEncryption
  ( -- * Creating a Request
    PutBucketEncryption (..),
    newPutBucketEncryption,

    -- * Request Lenses
    putBucketEncryption_contentMD5,
    putBucketEncryption_expectedBucketOwner,
    putBucketEncryption_bucket,
    putBucketEncryption_serverSideEncryptionConfiguration,

    -- * Destructuring the Response
    PutBucketEncryptionResponse (..),
    newPutBucketEncryptionResponse,
  )
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.S3.Types

-- | /See:/ 'newPutBucketEncryption' smart constructor.
data PutBucketEncryption = PutBucketEncryption'
  { -- | The base64-encoded 128-bit MD5 digest of the server-side encryption
    -- configuration.
    --
    -- For requests made using the Amazon Web Services Command Line Interface
    -- (CLI) or Amazon Web Services SDKs, this field is calculated
    -- automatically.
    PutBucketEncryption -> Maybe Text
contentMD5 :: Prelude.Maybe Prelude.Text,
    -- | The account ID of the expected bucket owner. If the bucket is owned by a
    -- different account, the request will fail with an HTTP
    -- @403 (Access Denied)@ error.
    PutBucketEncryption -> Maybe Text
expectedBucketOwner :: Prelude.Maybe Prelude.Text,
    -- | Specifies default encryption for a bucket using server-side encryption
    -- with Amazon S3-managed keys (SSE-S3) or customer managed keys (SSE-KMS).
    -- For information about the Amazon S3 default encryption feature, see
    -- <https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html Amazon S3 Default Bucket Encryption>
    -- in the /Amazon S3 User Guide/.
    PutBucketEncryption -> BucketName
bucket :: BucketName,
    PutBucketEncryption -> ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration :: ServerSideEncryptionConfiguration
  }
  deriving (PutBucketEncryption -> PutBucketEncryption -> Bool
(PutBucketEncryption -> PutBucketEncryption -> Bool)
-> (PutBucketEncryption -> PutBucketEncryption -> Bool)
-> Eq PutBucketEncryption
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutBucketEncryption -> PutBucketEncryption -> Bool
$c/= :: PutBucketEncryption -> PutBucketEncryption -> Bool
== :: PutBucketEncryption -> PutBucketEncryption -> Bool
$c== :: PutBucketEncryption -> PutBucketEncryption -> Bool
Prelude.Eq, Int -> PutBucketEncryption -> ShowS
[PutBucketEncryption] -> ShowS
PutBucketEncryption -> String
(Int -> PutBucketEncryption -> ShowS)
-> (PutBucketEncryption -> String)
-> ([PutBucketEncryption] -> ShowS)
-> Show PutBucketEncryption
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutBucketEncryption] -> ShowS
$cshowList :: [PutBucketEncryption] -> ShowS
show :: PutBucketEncryption -> String
$cshow :: PutBucketEncryption -> String
showsPrec :: Int -> PutBucketEncryption -> ShowS
$cshowsPrec :: Int -> PutBucketEncryption -> ShowS
Prelude.Show, (forall x. PutBucketEncryption -> Rep PutBucketEncryption x)
-> (forall x. Rep PutBucketEncryption x -> PutBucketEncryption)
-> Generic PutBucketEncryption
forall x. Rep PutBucketEncryption x -> PutBucketEncryption
forall x. PutBucketEncryption -> Rep PutBucketEncryption x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep PutBucketEncryption x -> PutBucketEncryption
$cfrom :: forall x. PutBucketEncryption -> Rep PutBucketEncryption x
Prelude.Generic)

-- |
-- Create a value of 'PutBucketEncryption' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'contentMD5', 'putBucketEncryption_contentMD5' - The base64-encoded 128-bit MD5 digest of the server-side encryption
-- configuration.
--
-- For requests made using the Amazon Web Services Command Line Interface
-- (CLI) or Amazon Web Services SDKs, this field is calculated
-- automatically.
--
-- 'expectedBucketOwner', 'putBucketEncryption_expectedBucketOwner' - The account ID of the expected bucket owner. If the bucket is owned by a
-- different account, the request will fail with an HTTP
-- @403 (Access Denied)@ error.
--
-- 'bucket', 'putBucketEncryption_bucket' - Specifies default encryption for a bucket using server-side encryption
-- with Amazon S3-managed keys (SSE-S3) or customer managed keys (SSE-KMS).
-- For information about the Amazon S3 default encryption feature, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html Amazon S3 Default Bucket Encryption>
-- in the /Amazon S3 User Guide/.
--
-- 'serverSideEncryptionConfiguration', 'putBucketEncryption_serverSideEncryptionConfiguration' - Undocumented member.
newPutBucketEncryption ::
  -- | 'bucket'
  BucketName ->
  -- | 'serverSideEncryptionConfiguration'
  ServerSideEncryptionConfiguration ->
  PutBucketEncryption
newPutBucketEncryption :: BucketName
-> ServerSideEncryptionConfiguration -> PutBucketEncryption
newPutBucketEncryption
  BucketName
pBucket_
  ServerSideEncryptionConfiguration
pServerSideEncryptionConfiguration_ =
    PutBucketEncryption' :: Maybe Text
-> Maybe Text
-> BucketName
-> ServerSideEncryptionConfiguration
-> PutBucketEncryption
PutBucketEncryption'
      { $sel:contentMD5:PutBucketEncryption' :: Maybe Text
contentMD5 = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:expectedBucketOwner:PutBucketEncryption' :: Maybe Text
expectedBucketOwner = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:bucket:PutBucketEncryption' :: BucketName
bucket = BucketName
pBucket_,
        $sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration =
          ServerSideEncryptionConfiguration
pServerSideEncryptionConfiguration_
      }

-- | The base64-encoded 128-bit MD5 digest of the server-side encryption
-- configuration.
--
-- For requests made using the Amazon Web Services Command Line Interface
-- (CLI) or Amazon Web Services SDKs, this field is calculated
-- automatically.
putBucketEncryption_contentMD5 :: Lens.Lens' PutBucketEncryption (Prelude.Maybe Prelude.Text)
putBucketEncryption_contentMD5 :: (Maybe Text -> f (Maybe Text))
-> PutBucketEncryption -> f PutBucketEncryption
putBucketEncryption_contentMD5 = (PutBucketEncryption -> Maybe Text)
-> (PutBucketEncryption -> Maybe Text -> PutBucketEncryption)
-> Lens
     PutBucketEncryption PutBucketEncryption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutBucketEncryption' {Maybe Text
contentMD5 :: Maybe Text
$sel:contentMD5:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
contentMD5} -> Maybe Text
contentMD5) (\s :: PutBucketEncryption
s@PutBucketEncryption' {} Maybe Text
a -> PutBucketEncryption
s {$sel:contentMD5:PutBucketEncryption' :: Maybe Text
contentMD5 = Maybe Text
a} :: PutBucketEncryption)

-- | The account ID of the expected bucket owner. If the bucket is owned by a
-- different account, the request will fail with an HTTP
-- @403 (Access Denied)@ error.
putBucketEncryption_expectedBucketOwner :: Lens.Lens' PutBucketEncryption (Prelude.Maybe Prelude.Text)
putBucketEncryption_expectedBucketOwner :: (Maybe Text -> f (Maybe Text))
-> PutBucketEncryption -> f PutBucketEncryption
putBucketEncryption_expectedBucketOwner = (PutBucketEncryption -> Maybe Text)
-> (PutBucketEncryption -> Maybe Text -> PutBucketEncryption)
-> Lens
     PutBucketEncryption PutBucketEncryption (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutBucketEncryption' {Maybe Text
expectedBucketOwner :: Maybe Text
$sel:expectedBucketOwner:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
expectedBucketOwner} -> Maybe Text
expectedBucketOwner) (\s :: PutBucketEncryption
s@PutBucketEncryption' {} Maybe Text
a -> PutBucketEncryption
s {$sel:expectedBucketOwner:PutBucketEncryption' :: Maybe Text
expectedBucketOwner = Maybe Text
a} :: PutBucketEncryption)

-- | Specifies default encryption for a bucket using server-side encryption
-- with Amazon S3-managed keys (SSE-S3) or customer managed keys (SSE-KMS).
-- For information about the Amazon S3 default encryption feature, see
-- <https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html Amazon S3 Default Bucket Encryption>
-- in the /Amazon S3 User Guide/.
putBucketEncryption_bucket :: Lens.Lens' PutBucketEncryption BucketName
putBucketEncryption_bucket :: (BucketName -> f BucketName)
-> PutBucketEncryption -> f PutBucketEncryption
putBucketEncryption_bucket = (PutBucketEncryption -> BucketName)
-> (PutBucketEncryption -> BucketName -> PutBucketEncryption)
-> Lens
     PutBucketEncryption PutBucketEncryption BucketName BucketName
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutBucketEncryption' {BucketName
bucket :: BucketName
$sel:bucket:PutBucketEncryption' :: PutBucketEncryption -> BucketName
bucket} -> BucketName
bucket) (\s :: PutBucketEncryption
s@PutBucketEncryption' {} BucketName
a -> PutBucketEncryption
s {$sel:bucket:PutBucketEncryption' :: BucketName
bucket = BucketName
a} :: PutBucketEncryption)

-- | Undocumented member.
putBucketEncryption_serverSideEncryptionConfiguration :: Lens.Lens' PutBucketEncryption ServerSideEncryptionConfiguration
putBucketEncryption_serverSideEncryptionConfiguration :: (ServerSideEncryptionConfiguration
 -> f ServerSideEncryptionConfiguration)
-> PutBucketEncryption -> f PutBucketEncryption
putBucketEncryption_serverSideEncryptionConfiguration = (PutBucketEncryption -> ServerSideEncryptionConfiguration)
-> (PutBucketEncryption
    -> ServerSideEncryptionConfiguration -> PutBucketEncryption)
-> Lens
     PutBucketEncryption
     PutBucketEncryption
     ServerSideEncryptionConfiguration
     ServerSideEncryptionConfiguration
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PutBucketEncryption' {ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration :: ServerSideEncryptionConfiguration
$sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: PutBucketEncryption -> ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration} -> ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration) (\s :: PutBucketEncryption
s@PutBucketEncryption' {} ServerSideEncryptionConfiguration
a -> PutBucketEncryption
s {$sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration = ServerSideEncryptionConfiguration
a} :: PutBucketEncryption)

instance Core.AWSRequest PutBucketEncryption where
  type
    AWSResponse PutBucketEncryption =
      PutBucketEncryptionResponse
  request :: PutBucketEncryption -> Request PutBucketEncryption
request =
    Request PutBucketEncryption -> Request PutBucketEncryption
forall a. Request a -> Request a
Request.s3vhost
      (Request PutBucketEncryption -> Request PutBucketEncryption)
-> (PutBucketEncryption -> Request PutBucketEncryption)
-> PutBucketEncryption
-> Request PutBucketEncryption
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Service -> PutBucketEncryption -> Request PutBucketEncryption
forall a. (ToRequest a, ToElement a) => Service -> a -> Request a
Request.putXML Service
defaultService
  response :: Logger
-> Service
-> Proxy PutBucketEncryption
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse PutBucketEncryption)))
response =
    AWSResponse PutBucketEncryption
-> Logger
-> Service
-> Proxy PutBucketEncryption
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse PutBucketEncryption)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull AWSResponse PutBucketEncryption
PutBucketEncryptionResponse
PutBucketEncryptionResponse'

instance Prelude.Hashable PutBucketEncryption

instance Prelude.NFData PutBucketEncryption

instance Core.ToElement PutBucketEncryption where
  toElement :: PutBucketEncryption -> Element
toElement PutBucketEncryption' {Maybe Text
BucketName
ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration :: ServerSideEncryptionConfiguration
bucket :: BucketName
expectedBucketOwner :: Maybe Text
contentMD5 :: Maybe Text
$sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: PutBucketEncryption -> ServerSideEncryptionConfiguration
$sel:bucket:PutBucketEncryption' :: PutBucketEncryption -> BucketName
$sel:expectedBucketOwner:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
$sel:contentMD5:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
..} =
    Name -> ServerSideEncryptionConfiguration -> Element
forall a. ToXML a => Name -> a -> Element
Core.mkElement
      Name
"{http://s3.amazonaws.com/doc/2006-03-01/}ServerSideEncryptionConfiguration"
      ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration

instance Core.ToHeaders PutBucketEncryption where
  toHeaders :: PutBucketEncryption -> [Header]
toHeaders PutBucketEncryption' {Maybe Text
BucketName
ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration :: ServerSideEncryptionConfiguration
bucket :: BucketName
expectedBucketOwner :: Maybe Text
contentMD5 :: Maybe Text
$sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: PutBucketEncryption -> ServerSideEncryptionConfiguration
$sel:bucket:PutBucketEncryption' :: PutBucketEncryption -> BucketName
$sel:expectedBucketOwner:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
$sel:contentMD5:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
..} =
    [[Header]] -> [Header]
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ HeaderName
"Content-MD5" HeaderName -> Maybe Text -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# Maybe Text
contentMD5,
        HeaderName
"x-amz-expected-bucket-owner"
          HeaderName -> Maybe Text -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# Maybe Text
expectedBucketOwner
      ]

instance Core.ToPath PutBucketEncryption where
  toPath :: PutBucketEncryption -> ByteString
toPath PutBucketEncryption' {Maybe Text
BucketName
ServerSideEncryptionConfiguration
serverSideEncryptionConfiguration :: ServerSideEncryptionConfiguration
bucket :: BucketName
expectedBucketOwner :: Maybe Text
contentMD5 :: Maybe Text
$sel:serverSideEncryptionConfiguration:PutBucketEncryption' :: PutBucketEncryption -> ServerSideEncryptionConfiguration
$sel:bucket:PutBucketEncryption' :: PutBucketEncryption -> BucketName
$sel:expectedBucketOwner:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
$sel:contentMD5:PutBucketEncryption' :: PutBucketEncryption -> Maybe Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"/", BucketName -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS BucketName
bucket]

instance Core.ToQuery PutBucketEncryption where
  toQuery :: PutBucketEncryption -> QueryString
toQuery =
    QueryString -> PutBucketEncryption -> QueryString
forall a b. a -> b -> a
Prelude.const ([QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat [QueryString
"encryption"])

-- | /See:/ 'newPutBucketEncryptionResponse' smart constructor.
data PutBucketEncryptionResponse = PutBucketEncryptionResponse'
  {
  }
  deriving (PutBucketEncryptionResponse -> PutBucketEncryptionResponse -> Bool
(PutBucketEncryptionResponse
 -> PutBucketEncryptionResponse -> Bool)
-> (PutBucketEncryptionResponse
    -> PutBucketEncryptionResponse -> Bool)
-> Eq PutBucketEncryptionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PutBucketEncryptionResponse -> PutBucketEncryptionResponse -> Bool
$c/= :: PutBucketEncryptionResponse -> PutBucketEncryptionResponse -> Bool
== :: PutBucketEncryptionResponse -> PutBucketEncryptionResponse -> Bool
$c== :: PutBucketEncryptionResponse -> PutBucketEncryptionResponse -> Bool
Prelude.Eq, ReadPrec [PutBucketEncryptionResponse]
ReadPrec PutBucketEncryptionResponse
Int -> ReadS PutBucketEncryptionResponse
ReadS [PutBucketEncryptionResponse]
(Int -> ReadS PutBucketEncryptionResponse)
-> ReadS [PutBucketEncryptionResponse]
-> ReadPrec PutBucketEncryptionResponse
-> ReadPrec [PutBucketEncryptionResponse]
-> Read PutBucketEncryptionResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PutBucketEncryptionResponse]
$creadListPrec :: ReadPrec [PutBucketEncryptionResponse]
readPrec :: ReadPrec PutBucketEncryptionResponse
$creadPrec :: ReadPrec PutBucketEncryptionResponse
readList :: ReadS [PutBucketEncryptionResponse]
$creadList :: ReadS [PutBucketEncryptionResponse]
readsPrec :: Int -> ReadS PutBucketEncryptionResponse
$creadsPrec :: Int -> ReadS PutBucketEncryptionResponse
Prelude.Read, Int -> PutBucketEncryptionResponse -> ShowS
[PutBucketEncryptionResponse] -> ShowS
PutBucketEncryptionResponse -> String
(Int -> PutBucketEncryptionResponse -> ShowS)
-> (PutBucketEncryptionResponse -> String)
-> ([PutBucketEncryptionResponse] -> ShowS)
-> Show PutBucketEncryptionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PutBucketEncryptionResponse] -> ShowS
$cshowList :: [PutBucketEncryptionResponse] -> ShowS
show :: PutBucketEncryptionResponse -> String
$cshow :: PutBucketEncryptionResponse -> String
showsPrec :: Int -> PutBucketEncryptionResponse -> ShowS
$cshowsPrec :: Int -> PutBucketEncryptionResponse -> ShowS
Prelude.Show, (forall x.
 PutBucketEncryptionResponse -> Rep PutBucketEncryptionResponse x)
-> (forall x.
    Rep PutBucketEncryptionResponse x -> PutBucketEncryptionResponse)
-> Generic PutBucketEncryptionResponse
forall x.
Rep PutBucketEncryptionResponse x -> PutBucketEncryptionResponse
forall x.
PutBucketEncryptionResponse -> Rep PutBucketEncryptionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PutBucketEncryptionResponse x -> PutBucketEncryptionResponse
$cfrom :: forall x.
PutBucketEncryptionResponse -> Rep PutBucketEncryptionResponse x
Prelude.Generic)

-- |
-- Create a value of 'PutBucketEncryptionResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
newPutBucketEncryptionResponse ::
  PutBucketEncryptionResponse
newPutBucketEncryptionResponse :: PutBucketEncryptionResponse
newPutBucketEncryptionResponse =
  PutBucketEncryptionResponse
PutBucketEncryptionResponse'

instance Prelude.NFData PutBucketEncryptionResponse