{-# 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.WAFRegional.CreateByteMatchSet
-- 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 is __AWS WAF Classic__ documentation. For more information, see
-- <https://docs.aws.amazon.com/waf/latest/developerguide/classic-waf-chapter.html AWS WAF Classic>
-- in the developer guide.
--
-- __For the latest version of AWS WAF__, use the AWS WAFV2 API and see the
-- <https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html AWS WAF Developer Guide>.
-- With the latest version, AWS WAF has a single set of endpoints for
-- regional and global use.
--
-- Creates a @ByteMatchSet@. You then use UpdateByteMatchSet to identify
-- the part of a web request that you want AWS WAF to inspect, such as the
-- values of the @User-Agent@ header or the query string. For example, you
-- can create a @ByteMatchSet@ that matches any requests with @User-Agent@
-- headers that contain the string @BadBot@. You can then configure AWS WAF
-- to reject those requests.
--
-- To create and configure a @ByteMatchSet@, perform the following steps:
--
-- 1.  Use GetChangeToken to get the change token that you provide in the
--     @ChangeToken@ parameter of a @CreateByteMatchSet@ request.
--
-- 2.  Submit a @CreateByteMatchSet@ request.
--
-- 3.  Use @GetChangeToken@ to get the change token that you provide in the
--     @ChangeToken@ parameter of an @UpdateByteMatchSet@ request.
--
-- 4.  Submit an UpdateByteMatchSet request to specify the part of the
--     request that you want AWS WAF to inspect (for example, the header or
--     the URI) and the value that you want AWS WAF to watch for.
--
-- For more information about how to use the AWS WAF API to allow or block
-- HTTP requests, see the
-- <https://docs.aws.amazon.com/waf/latest/developerguide/ AWS WAF Developer Guide>.
module Amazonka.WAFRegional.CreateByteMatchSet
  ( -- * Creating a Request
    CreateByteMatchSet (..),
    newCreateByteMatchSet,

    -- * Request Lenses
    createByteMatchSet_name,
    createByteMatchSet_changeToken,

    -- * Destructuring the Response
    CreateByteMatchSetResponse (..),
    newCreateByteMatchSetResponse,

    -- * Response Lenses
    createByteMatchSetResponse_byteMatchSet,
    createByteMatchSetResponse_changeToken,
    createByteMatchSetResponse_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.WAFRegional.Types

-- | /See:/ 'newCreateByteMatchSet' smart constructor.
data CreateByteMatchSet = CreateByteMatchSet'
  { -- | A friendly name or description of the ByteMatchSet. You can\'t change
    -- @Name@ after you create a @ByteMatchSet@.
    CreateByteMatchSet -> Text
name :: Prelude.Text,
    -- | The value returned by the most recent call to GetChangeToken.
    CreateByteMatchSet -> Text
changeToken :: Prelude.Text
  }
  deriving (CreateByteMatchSet -> CreateByteMatchSet -> Bool
(CreateByteMatchSet -> CreateByteMatchSet -> Bool)
-> (CreateByteMatchSet -> CreateByteMatchSet -> Bool)
-> Eq CreateByteMatchSet
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateByteMatchSet -> CreateByteMatchSet -> Bool
$c/= :: CreateByteMatchSet -> CreateByteMatchSet -> Bool
== :: CreateByteMatchSet -> CreateByteMatchSet -> Bool
$c== :: CreateByteMatchSet -> CreateByteMatchSet -> Bool
Prelude.Eq, ReadPrec [CreateByteMatchSet]
ReadPrec CreateByteMatchSet
Int -> ReadS CreateByteMatchSet
ReadS [CreateByteMatchSet]
(Int -> ReadS CreateByteMatchSet)
-> ReadS [CreateByteMatchSet]
-> ReadPrec CreateByteMatchSet
-> ReadPrec [CreateByteMatchSet]
-> Read CreateByteMatchSet
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateByteMatchSet]
$creadListPrec :: ReadPrec [CreateByteMatchSet]
readPrec :: ReadPrec CreateByteMatchSet
$creadPrec :: ReadPrec CreateByteMatchSet
readList :: ReadS [CreateByteMatchSet]
$creadList :: ReadS [CreateByteMatchSet]
readsPrec :: Int -> ReadS CreateByteMatchSet
$creadsPrec :: Int -> ReadS CreateByteMatchSet
Prelude.Read, Int -> CreateByteMatchSet -> ShowS
[CreateByteMatchSet] -> ShowS
CreateByteMatchSet -> String
(Int -> CreateByteMatchSet -> ShowS)
-> (CreateByteMatchSet -> String)
-> ([CreateByteMatchSet] -> ShowS)
-> Show CreateByteMatchSet
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateByteMatchSet] -> ShowS
$cshowList :: [CreateByteMatchSet] -> ShowS
show :: CreateByteMatchSet -> String
$cshow :: CreateByteMatchSet -> String
showsPrec :: Int -> CreateByteMatchSet -> ShowS
$cshowsPrec :: Int -> CreateByteMatchSet -> ShowS
Prelude.Show, (forall x. CreateByteMatchSet -> Rep CreateByteMatchSet x)
-> (forall x. Rep CreateByteMatchSet x -> CreateByteMatchSet)
-> Generic CreateByteMatchSet
forall x. Rep CreateByteMatchSet x -> CreateByteMatchSet
forall x. CreateByteMatchSet -> Rep CreateByteMatchSet x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateByteMatchSet x -> CreateByteMatchSet
$cfrom :: forall x. CreateByteMatchSet -> Rep CreateByteMatchSet x
Prelude.Generic)

-- |
-- Create a value of 'CreateByteMatchSet' 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:
--
-- 'name', 'createByteMatchSet_name' - A friendly name or description of the ByteMatchSet. You can\'t change
-- @Name@ after you create a @ByteMatchSet@.
--
-- 'changeToken', 'createByteMatchSet_changeToken' - The value returned by the most recent call to GetChangeToken.
newCreateByteMatchSet ::
  -- | 'name'
  Prelude.Text ->
  -- | 'changeToken'
  Prelude.Text ->
  CreateByteMatchSet
newCreateByteMatchSet :: Text -> Text -> CreateByteMatchSet
newCreateByteMatchSet Text
pName_ Text
pChangeToken_ =
  CreateByteMatchSet' :: Text -> Text -> CreateByteMatchSet
CreateByteMatchSet'
    { $sel:name:CreateByteMatchSet' :: Text
name = Text
pName_,
      $sel:changeToken:CreateByteMatchSet' :: Text
changeToken = Text
pChangeToken_
    }

-- | A friendly name or description of the ByteMatchSet. You can\'t change
-- @Name@ after you create a @ByteMatchSet@.
createByteMatchSet_name :: Lens.Lens' CreateByteMatchSet Prelude.Text
createByteMatchSet_name :: (Text -> f Text) -> CreateByteMatchSet -> f CreateByteMatchSet
createByteMatchSet_name = (CreateByteMatchSet -> Text)
-> (CreateByteMatchSet -> Text -> CreateByteMatchSet)
-> Lens CreateByteMatchSet CreateByteMatchSet Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateByteMatchSet' {Text
name :: Text
$sel:name:CreateByteMatchSet' :: CreateByteMatchSet -> Text
name} -> Text
name) (\s :: CreateByteMatchSet
s@CreateByteMatchSet' {} Text
a -> CreateByteMatchSet
s {$sel:name:CreateByteMatchSet' :: Text
name = Text
a} :: CreateByteMatchSet)

-- | The value returned by the most recent call to GetChangeToken.
createByteMatchSet_changeToken :: Lens.Lens' CreateByteMatchSet Prelude.Text
createByteMatchSet_changeToken :: (Text -> f Text) -> CreateByteMatchSet -> f CreateByteMatchSet
createByteMatchSet_changeToken = (CreateByteMatchSet -> Text)
-> (CreateByteMatchSet -> Text -> CreateByteMatchSet)
-> Lens CreateByteMatchSet CreateByteMatchSet Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateByteMatchSet' {Text
changeToken :: Text
$sel:changeToken:CreateByteMatchSet' :: CreateByteMatchSet -> Text
changeToken} -> Text
changeToken) (\s :: CreateByteMatchSet
s@CreateByteMatchSet' {} Text
a -> CreateByteMatchSet
s {$sel:changeToken:CreateByteMatchSet' :: Text
changeToken = Text
a} :: CreateByteMatchSet)

instance Core.AWSRequest CreateByteMatchSet where
  type
    AWSResponse CreateByteMatchSet =
      CreateByteMatchSetResponse
  request :: CreateByteMatchSet -> Request CreateByteMatchSet
request = Service -> CreateByteMatchSet -> Request CreateByteMatchSet
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateByteMatchSet
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateByteMatchSet)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateByteMatchSet))
-> Logger
-> Service
-> Proxy CreateByteMatchSet
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateByteMatchSet)))
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 ByteMatchSet
-> Maybe Text -> Int -> CreateByteMatchSetResponse
CreateByteMatchSetResponse'
            (Maybe ByteMatchSet
 -> Maybe Text -> Int -> CreateByteMatchSetResponse)
-> Either String (Maybe ByteMatchSet)
-> Either String (Maybe Text -> Int -> CreateByteMatchSetResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe ByteMatchSet)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"ByteMatchSet")
            Either String (Maybe Text -> Int -> CreateByteMatchSetResponse)
-> Either String (Maybe Text)
-> Either String (Int -> CreateByteMatchSetResponse)
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
"ChangeToken")
            Either String (Int -> CreateByteMatchSetResponse)
-> Either String Int -> Either String CreateByteMatchSetResponse
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 CreateByteMatchSet

instance Prelude.NFData CreateByteMatchSet

instance Core.ToHeaders CreateByteMatchSet where
  toHeaders :: CreateByteMatchSet -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateByteMatchSet -> 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
"AWSWAF_Regional_20161128.CreateByteMatchSet" ::
                          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 CreateByteMatchSet where
  toJSON :: CreateByteMatchSet -> Value
toJSON CreateByteMatchSet' {Text
changeToken :: Text
name :: Text
$sel:changeToken:CreateByteMatchSet' :: CreateByteMatchSet -> Text
$sel:name:CreateByteMatchSet' :: CreateByteMatchSet -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"ChangeToken" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
changeToken)
          ]
      )

instance Core.ToPath CreateByteMatchSet where
  toPath :: CreateByteMatchSet -> ByteString
toPath = ByteString -> CreateByteMatchSet -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Core.ToQuery CreateByteMatchSet where
  toQuery :: CreateByteMatchSet -> QueryString
toQuery = QueryString -> CreateByteMatchSet -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newCreateByteMatchSetResponse' smart constructor.
data CreateByteMatchSetResponse = CreateByteMatchSetResponse'
  { -- | A ByteMatchSet that contains no @ByteMatchTuple@ objects.
    CreateByteMatchSetResponse -> Maybe ByteMatchSet
byteMatchSet :: Prelude.Maybe ByteMatchSet,
    -- | The @ChangeToken@ that you used to submit the @CreateByteMatchSet@
    -- request. You can also use this value to query the status of the request.
    -- For more information, see GetChangeTokenStatus.
    CreateByteMatchSetResponse -> Maybe Text
changeToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    CreateByteMatchSetResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool
(CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool)
-> (CreateByteMatchSetResponse
    -> CreateByteMatchSetResponse -> Bool)
-> Eq CreateByteMatchSetResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool
$c/= :: CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool
== :: CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool
$c== :: CreateByteMatchSetResponse -> CreateByteMatchSetResponse -> Bool
Prelude.Eq, ReadPrec [CreateByteMatchSetResponse]
ReadPrec CreateByteMatchSetResponse
Int -> ReadS CreateByteMatchSetResponse
ReadS [CreateByteMatchSetResponse]
(Int -> ReadS CreateByteMatchSetResponse)
-> ReadS [CreateByteMatchSetResponse]
-> ReadPrec CreateByteMatchSetResponse
-> ReadPrec [CreateByteMatchSetResponse]
-> Read CreateByteMatchSetResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateByteMatchSetResponse]
$creadListPrec :: ReadPrec [CreateByteMatchSetResponse]
readPrec :: ReadPrec CreateByteMatchSetResponse
$creadPrec :: ReadPrec CreateByteMatchSetResponse
readList :: ReadS [CreateByteMatchSetResponse]
$creadList :: ReadS [CreateByteMatchSetResponse]
readsPrec :: Int -> ReadS CreateByteMatchSetResponse
$creadsPrec :: Int -> ReadS CreateByteMatchSetResponse
Prelude.Read, Int -> CreateByteMatchSetResponse -> ShowS
[CreateByteMatchSetResponse] -> ShowS
CreateByteMatchSetResponse -> String
(Int -> CreateByteMatchSetResponse -> ShowS)
-> (CreateByteMatchSetResponse -> String)
-> ([CreateByteMatchSetResponse] -> ShowS)
-> Show CreateByteMatchSetResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateByteMatchSetResponse] -> ShowS
$cshowList :: [CreateByteMatchSetResponse] -> ShowS
show :: CreateByteMatchSetResponse -> String
$cshow :: CreateByteMatchSetResponse -> String
showsPrec :: Int -> CreateByteMatchSetResponse -> ShowS
$cshowsPrec :: Int -> CreateByteMatchSetResponse -> ShowS
Prelude.Show, (forall x.
 CreateByteMatchSetResponse -> Rep CreateByteMatchSetResponse x)
-> (forall x.
    Rep CreateByteMatchSetResponse x -> CreateByteMatchSetResponse)
-> Generic CreateByteMatchSetResponse
forall x.
Rep CreateByteMatchSetResponse x -> CreateByteMatchSetResponse
forall x.
CreateByteMatchSetResponse -> Rep CreateByteMatchSetResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateByteMatchSetResponse x -> CreateByteMatchSetResponse
$cfrom :: forall x.
CreateByteMatchSetResponse -> Rep CreateByteMatchSetResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateByteMatchSetResponse' 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:
--
-- 'byteMatchSet', 'createByteMatchSetResponse_byteMatchSet' - A ByteMatchSet that contains no @ByteMatchTuple@ objects.
--
-- 'changeToken', 'createByteMatchSetResponse_changeToken' - The @ChangeToken@ that you used to submit the @CreateByteMatchSet@
-- request. You can also use this value to query the status of the request.
-- For more information, see GetChangeTokenStatus.
--
-- 'httpStatus', 'createByteMatchSetResponse_httpStatus' - The response's http status code.
newCreateByteMatchSetResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateByteMatchSetResponse
newCreateByteMatchSetResponse :: Int -> CreateByteMatchSetResponse
newCreateByteMatchSetResponse Int
pHttpStatus_ =
  CreateByteMatchSetResponse' :: Maybe ByteMatchSet
-> Maybe Text -> Int -> CreateByteMatchSetResponse
CreateByteMatchSetResponse'
    { $sel:byteMatchSet:CreateByteMatchSetResponse' :: Maybe ByteMatchSet
byteMatchSet =
        Maybe ByteMatchSet
forall a. Maybe a
Prelude.Nothing,
      $sel:changeToken:CreateByteMatchSetResponse' :: Maybe Text
changeToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateByteMatchSetResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A ByteMatchSet that contains no @ByteMatchTuple@ objects.
createByteMatchSetResponse_byteMatchSet :: Lens.Lens' CreateByteMatchSetResponse (Prelude.Maybe ByteMatchSet)
createByteMatchSetResponse_byteMatchSet :: (Maybe ByteMatchSet -> f (Maybe ByteMatchSet))
-> CreateByteMatchSetResponse -> f CreateByteMatchSetResponse
createByteMatchSetResponse_byteMatchSet = (CreateByteMatchSetResponse -> Maybe ByteMatchSet)
-> (CreateByteMatchSetResponse
    -> Maybe ByteMatchSet -> CreateByteMatchSetResponse)
-> Lens
     CreateByteMatchSetResponse
     CreateByteMatchSetResponse
     (Maybe ByteMatchSet)
     (Maybe ByteMatchSet)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateByteMatchSetResponse' {Maybe ByteMatchSet
byteMatchSet :: Maybe ByteMatchSet
$sel:byteMatchSet:CreateByteMatchSetResponse' :: CreateByteMatchSetResponse -> Maybe ByteMatchSet
byteMatchSet} -> Maybe ByteMatchSet
byteMatchSet) (\s :: CreateByteMatchSetResponse
s@CreateByteMatchSetResponse' {} Maybe ByteMatchSet
a -> CreateByteMatchSetResponse
s {$sel:byteMatchSet:CreateByteMatchSetResponse' :: Maybe ByteMatchSet
byteMatchSet = Maybe ByteMatchSet
a} :: CreateByteMatchSetResponse)

-- | The @ChangeToken@ that you used to submit the @CreateByteMatchSet@
-- request. You can also use this value to query the status of the request.
-- For more information, see GetChangeTokenStatus.
createByteMatchSetResponse_changeToken :: Lens.Lens' CreateByteMatchSetResponse (Prelude.Maybe Prelude.Text)
createByteMatchSetResponse_changeToken :: (Maybe Text -> f (Maybe Text))
-> CreateByteMatchSetResponse -> f CreateByteMatchSetResponse
createByteMatchSetResponse_changeToken = (CreateByteMatchSetResponse -> Maybe Text)
-> (CreateByteMatchSetResponse
    -> Maybe Text -> CreateByteMatchSetResponse)
-> Lens
     CreateByteMatchSetResponse
     CreateByteMatchSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateByteMatchSetResponse' {Maybe Text
changeToken :: Maybe Text
$sel:changeToken:CreateByteMatchSetResponse' :: CreateByteMatchSetResponse -> Maybe Text
changeToken} -> Maybe Text
changeToken) (\s :: CreateByteMatchSetResponse
s@CreateByteMatchSetResponse' {} Maybe Text
a -> CreateByteMatchSetResponse
s {$sel:changeToken:CreateByteMatchSetResponse' :: Maybe Text
changeToken = Maybe Text
a} :: CreateByteMatchSetResponse)

-- | The response's http status code.
createByteMatchSetResponse_httpStatus :: Lens.Lens' CreateByteMatchSetResponse Prelude.Int
createByteMatchSetResponse_httpStatus :: (Int -> f Int)
-> CreateByteMatchSetResponse -> f CreateByteMatchSetResponse
createByteMatchSetResponse_httpStatus = (CreateByteMatchSetResponse -> Int)
-> (CreateByteMatchSetResponse
    -> Int -> CreateByteMatchSetResponse)
-> Lens
     CreateByteMatchSetResponse CreateByteMatchSetResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateByteMatchSetResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateByteMatchSetResponse' :: CreateByteMatchSetResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateByteMatchSetResponse
s@CreateByteMatchSetResponse' {} Int
a -> CreateByteMatchSetResponse
s {$sel:httpStatus:CreateByteMatchSetResponse' :: Int
httpStatus = Int
a} :: CreateByteMatchSetResponse)

instance Prelude.NFData CreateByteMatchSetResponse