{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

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

-- |
-- Module      : Amazonka.SecurityHub.Types.AwsApiGatewayMethodSettings
-- 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)
module Amazonka.SecurityHub.Types.AwsApiGatewayMethodSettings where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Defines settings for a method for the stage.
--
-- /See:/ 'newAwsApiGatewayMethodSettings' smart constructor.
data AwsApiGatewayMethodSettings = AwsApiGatewayMethodSettings'
  { -- | Indicates whether data trace logging is enabled for the method. Data
    -- trace logging affects the log entries that are pushed to CloudWatch
    -- Logs.
    AwsApiGatewayMethodSettings -> Maybe Bool
dataTraceEnabled :: Prelude.Maybe Prelude.Bool,
    -- | Specifies the time to live (TTL), in seconds, for cached responses. The
    -- higher the TTL, the longer the response is cached.
    AwsApiGatewayMethodSettings -> Maybe Int
cacheTtlInSeconds :: Prelude.Maybe Prelude.Int,
    -- | The HTTP method. You can use an asterisk (*) as a wildcard to apply
    -- method settings to multiple methods.
    AwsApiGatewayMethodSettings -> Maybe Text
httpMethod :: Prelude.Maybe Prelude.Text,
    -- | The throttling burst limit for the method.
    AwsApiGatewayMethodSettings -> Maybe Int
throttlingBurstLimit :: Prelude.Maybe Prelude.Int,
    -- | Indicates whether the cached responses are encrypted.
    AwsApiGatewayMethodSettings -> Maybe Bool
cacheDataEncrypted :: Prelude.Maybe Prelude.Bool,
    -- | The logging level for this method. The logging level affects the log
    -- entries that are pushed to CloudWatch Logs.
    --
    -- If the logging level is @ERROR@, then the logs only include error-level
    -- entries.
    --
    -- If the logging level is @INFO@, then the logs include both @ERROR@
    -- events and extra informational events.
    --
    -- Valid values: @OFF@ | @ERROR@ | @INFO@
    AwsApiGatewayMethodSettings -> Maybe Text
loggingLevel :: Prelude.Maybe Prelude.Text,
    -- | Indicates whether authorization is required for a cache invalidation
    -- request.
    AwsApiGatewayMethodSettings -> Maybe Bool
requireAuthorizationForCacheControl :: Prelude.Maybe Prelude.Bool,
    -- | Indicates whether responses are cached and returned for requests. For
    -- responses to be cached, a cache cluster must be enabled on the stage.
    AwsApiGatewayMethodSettings -> Maybe Bool
cachingEnabled :: Prelude.Maybe Prelude.Bool,
    -- | The resource path for this method. Forward slashes (\/) are encoded as
    -- ~1 . The initial slash must include a forward slash.
    --
    -- For example, the path value @\/resource\/subresource@ must be encoded as
    -- @\/~1resource~1subresource@.
    --
    -- To specify the root path, use only a slash (\/). You can use an asterisk
    -- (*) as a wildcard to apply method settings to multiple methods.
    AwsApiGatewayMethodSettings -> Maybe Text
resourcePath :: Prelude.Maybe Prelude.Text,
    -- | The throttling rate limit for the method.
    AwsApiGatewayMethodSettings -> Maybe Double
throttlingRateLimit :: Prelude.Maybe Prelude.Double,
    -- | Indicates whether CloudWatch metrics are enabled for the method.
    AwsApiGatewayMethodSettings -> Maybe Bool
metricsEnabled :: Prelude.Maybe Prelude.Bool,
    -- | Indicates how to handle unauthorized requests for cache invalidation.
    --
    -- Valid values: @FAIL_WITH_403@ | @SUCCEED_WITH_RESPONSE_HEADER@ |
    -- @SUCCEED_WITHOUT_RESPONSE_HEADER@
    AwsApiGatewayMethodSettings -> Maybe Text
unauthorizedCacheControlHeaderStrategy :: Prelude.Maybe Prelude.Text
  }
  deriving (AwsApiGatewayMethodSettings -> AwsApiGatewayMethodSettings -> Bool
(AwsApiGatewayMethodSettings
 -> AwsApiGatewayMethodSettings -> Bool)
-> (AwsApiGatewayMethodSettings
    -> AwsApiGatewayMethodSettings -> Bool)
-> Eq AwsApiGatewayMethodSettings
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsApiGatewayMethodSettings -> AwsApiGatewayMethodSettings -> Bool
$c/= :: AwsApiGatewayMethodSettings -> AwsApiGatewayMethodSettings -> Bool
== :: AwsApiGatewayMethodSettings -> AwsApiGatewayMethodSettings -> Bool
$c== :: AwsApiGatewayMethodSettings -> AwsApiGatewayMethodSettings -> Bool
Prelude.Eq, ReadPrec [AwsApiGatewayMethodSettings]
ReadPrec AwsApiGatewayMethodSettings
Int -> ReadS AwsApiGatewayMethodSettings
ReadS [AwsApiGatewayMethodSettings]
(Int -> ReadS AwsApiGatewayMethodSettings)
-> ReadS [AwsApiGatewayMethodSettings]
-> ReadPrec AwsApiGatewayMethodSettings
-> ReadPrec [AwsApiGatewayMethodSettings]
-> Read AwsApiGatewayMethodSettings
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AwsApiGatewayMethodSettings]
$creadListPrec :: ReadPrec [AwsApiGatewayMethodSettings]
readPrec :: ReadPrec AwsApiGatewayMethodSettings
$creadPrec :: ReadPrec AwsApiGatewayMethodSettings
readList :: ReadS [AwsApiGatewayMethodSettings]
$creadList :: ReadS [AwsApiGatewayMethodSettings]
readsPrec :: Int -> ReadS AwsApiGatewayMethodSettings
$creadsPrec :: Int -> ReadS AwsApiGatewayMethodSettings
Prelude.Read, Int -> AwsApiGatewayMethodSettings -> ShowS
[AwsApiGatewayMethodSettings] -> ShowS
AwsApiGatewayMethodSettings -> String
(Int -> AwsApiGatewayMethodSettings -> ShowS)
-> (AwsApiGatewayMethodSettings -> String)
-> ([AwsApiGatewayMethodSettings] -> ShowS)
-> Show AwsApiGatewayMethodSettings
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsApiGatewayMethodSettings] -> ShowS
$cshowList :: [AwsApiGatewayMethodSettings] -> ShowS
show :: AwsApiGatewayMethodSettings -> String
$cshow :: AwsApiGatewayMethodSettings -> String
showsPrec :: Int -> AwsApiGatewayMethodSettings -> ShowS
$cshowsPrec :: Int -> AwsApiGatewayMethodSettings -> ShowS
Prelude.Show, (forall x.
 AwsApiGatewayMethodSettings -> Rep AwsApiGatewayMethodSettings x)
-> (forall x.
    Rep AwsApiGatewayMethodSettings x -> AwsApiGatewayMethodSettings)
-> Generic AwsApiGatewayMethodSettings
forall x.
Rep AwsApiGatewayMethodSettings x -> AwsApiGatewayMethodSettings
forall x.
AwsApiGatewayMethodSettings -> Rep AwsApiGatewayMethodSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep AwsApiGatewayMethodSettings x -> AwsApiGatewayMethodSettings
$cfrom :: forall x.
AwsApiGatewayMethodSettings -> Rep AwsApiGatewayMethodSettings x
Prelude.Generic)

-- |
-- Create a value of 'AwsApiGatewayMethodSettings' 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:
--
-- 'dataTraceEnabled', 'awsApiGatewayMethodSettings_dataTraceEnabled' - Indicates whether data trace logging is enabled for the method. Data
-- trace logging affects the log entries that are pushed to CloudWatch
-- Logs.
--
-- 'cacheTtlInSeconds', 'awsApiGatewayMethodSettings_cacheTtlInSeconds' - Specifies the time to live (TTL), in seconds, for cached responses. The
-- higher the TTL, the longer the response is cached.
--
-- 'httpMethod', 'awsApiGatewayMethodSettings_httpMethod' - The HTTP method. You can use an asterisk (*) as a wildcard to apply
-- method settings to multiple methods.
--
-- 'throttlingBurstLimit', 'awsApiGatewayMethodSettings_throttlingBurstLimit' - The throttling burst limit for the method.
--
-- 'cacheDataEncrypted', 'awsApiGatewayMethodSettings_cacheDataEncrypted' - Indicates whether the cached responses are encrypted.
--
-- 'loggingLevel', 'awsApiGatewayMethodSettings_loggingLevel' - The logging level for this method. The logging level affects the log
-- entries that are pushed to CloudWatch Logs.
--
-- If the logging level is @ERROR@, then the logs only include error-level
-- entries.
--
-- If the logging level is @INFO@, then the logs include both @ERROR@
-- events and extra informational events.
--
-- Valid values: @OFF@ | @ERROR@ | @INFO@
--
-- 'requireAuthorizationForCacheControl', 'awsApiGatewayMethodSettings_requireAuthorizationForCacheControl' - Indicates whether authorization is required for a cache invalidation
-- request.
--
-- 'cachingEnabled', 'awsApiGatewayMethodSettings_cachingEnabled' - Indicates whether responses are cached and returned for requests. For
-- responses to be cached, a cache cluster must be enabled on the stage.
--
-- 'resourcePath', 'awsApiGatewayMethodSettings_resourcePath' - The resource path for this method. Forward slashes (\/) are encoded as
-- ~1 . The initial slash must include a forward slash.
--
-- For example, the path value @\/resource\/subresource@ must be encoded as
-- @\/~1resource~1subresource@.
--
-- To specify the root path, use only a slash (\/). You can use an asterisk
-- (*) as a wildcard to apply method settings to multiple methods.
--
-- 'throttlingRateLimit', 'awsApiGatewayMethodSettings_throttlingRateLimit' - The throttling rate limit for the method.
--
-- 'metricsEnabled', 'awsApiGatewayMethodSettings_metricsEnabled' - Indicates whether CloudWatch metrics are enabled for the method.
--
-- 'unauthorizedCacheControlHeaderStrategy', 'awsApiGatewayMethodSettings_unauthorizedCacheControlHeaderStrategy' - Indicates how to handle unauthorized requests for cache invalidation.
--
-- Valid values: @FAIL_WITH_403@ | @SUCCEED_WITH_RESPONSE_HEADER@ |
-- @SUCCEED_WITHOUT_RESPONSE_HEADER@
newAwsApiGatewayMethodSettings ::
  AwsApiGatewayMethodSettings
newAwsApiGatewayMethodSettings :: AwsApiGatewayMethodSettings
newAwsApiGatewayMethodSettings =
  AwsApiGatewayMethodSettings' :: Maybe Bool
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> Maybe Double
-> Maybe Bool
-> Maybe Text
-> AwsApiGatewayMethodSettings
AwsApiGatewayMethodSettings'
    { $sel:dataTraceEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
dataTraceEnabled =
        Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:cacheTtlInSeconds:AwsApiGatewayMethodSettings' :: Maybe Int
cacheTtlInSeconds = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:httpMethod:AwsApiGatewayMethodSettings' :: Maybe Text
httpMethod = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:throttlingBurstLimit:AwsApiGatewayMethodSettings' :: Maybe Int
throttlingBurstLimit = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:cacheDataEncrypted:AwsApiGatewayMethodSettings' :: Maybe Bool
cacheDataEncrypted = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:loggingLevel:AwsApiGatewayMethodSettings' :: Maybe Text
loggingLevel = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:requireAuthorizationForCacheControl:AwsApiGatewayMethodSettings' :: Maybe Bool
requireAuthorizationForCacheControl =
        Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:cachingEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
cachingEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:resourcePath:AwsApiGatewayMethodSettings' :: Maybe Text
resourcePath = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:throttlingRateLimit:AwsApiGatewayMethodSettings' :: Maybe Double
throttlingRateLimit = Maybe Double
forall a. Maybe a
Prelude.Nothing,
      $sel:metricsEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
metricsEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:unauthorizedCacheControlHeaderStrategy:AwsApiGatewayMethodSettings' :: Maybe Text
unauthorizedCacheControlHeaderStrategy =
        Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | Indicates whether data trace logging is enabled for the method. Data
-- trace logging affects the log entries that are pushed to CloudWatch
-- Logs.
awsApiGatewayMethodSettings_dataTraceEnabled :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Bool)
awsApiGatewayMethodSettings_dataTraceEnabled :: (Maybe Bool -> f (Maybe Bool))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_dataTraceEnabled = (AwsApiGatewayMethodSettings -> Maybe Bool)
-> (AwsApiGatewayMethodSettings
    -> Maybe Bool -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Bool
dataTraceEnabled :: Maybe Bool
$sel:dataTraceEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
dataTraceEnabled} -> Maybe Bool
dataTraceEnabled) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Bool
a -> AwsApiGatewayMethodSettings
s {$sel:dataTraceEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
dataTraceEnabled = Maybe Bool
a} :: AwsApiGatewayMethodSettings)

-- | Specifies the time to live (TTL), in seconds, for cached responses. The
-- higher the TTL, the longer the response is cached.
awsApiGatewayMethodSettings_cacheTtlInSeconds :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Int)
awsApiGatewayMethodSettings_cacheTtlInSeconds :: (Maybe Int -> f (Maybe Int))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_cacheTtlInSeconds = (AwsApiGatewayMethodSettings -> Maybe Int)
-> (AwsApiGatewayMethodSettings
    -> Maybe Int -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Int
cacheTtlInSeconds :: Maybe Int
$sel:cacheTtlInSeconds:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Int
cacheTtlInSeconds} -> Maybe Int
cacheTtlInSeconds) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Int
a -> AwsApiGatewayMethodSettings
s {$sel:cacheTtlInSeconds:AwsApiGatewayMethodSettings' :: Maybe Int
cacheTtlInSeconds = Maybe Int
a} :: AwsApiGatewayMethodSettings)

-- | The HTTP method. You can use an asterisk (*) as a wildcard to apply
-- method settings to multiple methods.
awsApiGatewayMethodSettings_httpMethod :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Text)
awsApiGatewayMethodSettings_httpMethod :: (Maybe Text -> f (Maybe Text))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_httpMethod = (AwsApiGatewayMethodSettings -> Maybe Text)
-> (AwsApiGatewayMethodSettings
    -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Text
httpMethod :: Maybe Text
$sel:httpMethod:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
httpMethod} -> Maybe Text
httpMethod) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Text
a -> AwsApiGatewayMethodSettings
s {$sel:httpMethod:AwsApiGatewayMethodSettings' :: Maybe Text
httpMethod = Maybe Text
a} :: AwsApiGatewayMethodSettings)

-- | The throttling burst limit for the method.
awsApiGatewayMethodSettings_throttlingBurstLimit :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Int)
awsApiGatewayMethodSettings_throttlingBurstLimit :: (Maybe Int -> f (Maybe Int))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_throttlingBurstLimit = (AwsApiGatewayMethodSettings -> Maybe Int)
-> (AwsApiGatewayMethodSettings
    -> Maybe Int -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Int
throttlingBurstLimit :: Maybe Int
$sel:throttlingBurstLimit:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Int
throttlingBurstLimit} -> Maybe Int
throttlingBurstLimit) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Int
a -> AwsApiGatewayMethodSettings
s {$sel:throttlingBurstLimit:AwsApiGatewayMethodSettings' :: Maybe Int
throttlingBurstLimit = Maybe Int
a} :: AwsApiGatewayMethodSettings)

-- | Indicates whether the cached responses are encrypted.
awsApiGatewayMethodSettings_cacheDataEncrypted :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Bool)
awsApiGatewayMethodSettings_cacheDataEncrypted :: (Maybe Bool -> f (Maybe Bool))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_cacheDataEncrypted = (AwsApiGatewayMethodSettings -> Maybe Bool)
-> (AwsApiGatewayMethodSettings
    -> Maybe Bool -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Bool
cacheDataEncrypted :: Maybe Bool
$sel:cacheDataEncrypted:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
cacheDataEncrypted} -> Maybe Bool
cacheDataEncrypted) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Bool
a -> AwsApiGatewayMethodSettings
s {$sel:cacheDataEncrypted:AwsApiGatewayMethodSettings' :: Maybe Bool
cacheDataEncrypted = Maybe Bool
a} :: AwsApiGatewayMethodSettings)

-- | The logging level for this method. The logging level affects the log
-- entries that are pushed to CloudWatch Logs.
--
-- If the logging level is @ERROR@, then the logs only include error-level
-- entries.
--
-- If the logging level is @INFO@, then the logs include both @ERROR@
-- events and extra informational events.
--
-- Valid values: @OFF@ | @ERROR@ | @INFO@
awsApiGatewayMethodSettings_loggingLevel :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Text)
awsApiGatewayMethodSettings_loggingLevel :: (Maybe Text -> f (Maybe Text))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_loggingLevel = (AwsApiGatewayMethodSettings -> Maybe Text)
-> (AwsApiGatewayMethodSettings
    -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Text
loggingLevel :: Maybe Text
$sel:loggingLevel:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
loggingLevel} -> Maybe Text
loggingLevel) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Text
a -> AwsApiGatewayMethodSettings
s {$sel:loggingLevel:AwsApiGatewayMethodSettings' :: Maybe Text
loggingLevel = Maybe Text
a} :: AwsApiGatewayMethodSettings)

-- | Indicates whether authorization is required for a cache invalidation
-- request.
awsApiGatewayMethodSettings_requireAuthorizationForCacheControl :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Bool)
awsApiGatewayMethodSettings_requireAuthorizationForCacheControl :: (Maybe Bool -> f (Maybe Bool))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_requireAuthorizationForCacheControl = (AwsApiGatewayMethodSettings -> Maybe Bool)
-> (AwsApiGatewayMethodSettings
    -> Maybe Bool -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Bool
requireAuthorizationForCacheControl :: Maybe Bool
$sel:requireAuthorizationForCacheControl:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
requireAuthorizationForCacheControl} -> Maybe Bool
requireAuthorizationForCacheControl) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Bool
a -> AwsApiGatewayMethodSettings
s {$sel:requireAuthorizationForCacheControl:AwsApiGatewayMethodSettings' :: Maybe Bool
requireAuthorizationForCacheControl = Maybe Bool
a} :: AwsApiGatewayMethodSettings)

-- | Indicates whether responses are cached and returned for requests. For
-- responses to be cached, a cache cluster must be enabled on the stage.
awsApiGatewayMethodSettings_cachingEnabled :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Bool)
awsApiGatewayMethodSettings_cachingEnabled :: (Maybe Bool -> f (Maybe Bool))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_cachingEnabled = (AwsApiGatewayMethodSettings -> Maybe Bool)
-> (AwsApiGatewayMethodSettings
    -> Maybe Bool -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Bool
cachingEnabled :: Maybe Bool
$sel:cachingEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
cachingEnabled} -> Maybe Bool
cachingEnabled) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Bool
a -> AwsApiGatewayMethodSettings
s {$sel:cachingEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
cachingEnabled = Maybe Bool
a} :: AwsApiGatewayMethodSettings)

-- | The resource path for this method. Forward slashes (\/) are encoded as
-- ~1 . The initial slash must include a forward slash.
--
-- For example, the path value @\/resource\/subresource@ must be encoded as
-- @\/~1resource~1subresource@.
--
-- To specify the root path, use only a slash (\/). You can use an asterisk
-- (*) as a wildcard to apply method settings to multiple methods.
awsApiGatewayMethodSettings_resourcePath :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Text)
awsApiGatewayMethodSettings_resourcePath :: (Maybe Text -> f (Maybe Text))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_resourcePath = (AwsApiGatewayMethodSettings -> Maybe Text)
-> (AwsApiGatewayMethodSettings
    -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Text
resourcePath :: Maybe Text
$sel:resourcePath:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
resourcePath} -> Maybe Text
resourcePath) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Text
a -> AwsApiGatewayMethodSettings
s {$sel:resourcePath:AwsApiGatewayMethodSettings' :: Maybe Text
resourcePath = Maybe Text
a} :: AwsApiGatewayMethodSettings)

-- | The throttling rate limit for the method.
awsApiGatewayMethodSettings_throttlingRateLimit :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Double)
awsApiGatewayMethodSettings_throttlingRateLimit :: (Maybe Double -> f (Maybe Double))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_throttlingRateLimit = (AwsApiGatewayMethodSettings -> Maybe Double)
-> (AwsApiGatewayMethodSettings
    -> Maybe Double -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Double)
     (Maybe Double)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Double
throttlingRateLimit :: Maybe Double
$sel:throttlingRateLimit:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Double
throttlingRateLimit} -> Maybe Double
throttlingRateLimit) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Double
a -> AwsApiGatewayMethodSettings
s {$sel:throttlingRateLimit:AwsApiGatewayMethodSettings' :: Maybe Double
throttlingRateLimit = Maybe Double
a} :: AwsApiGatewayMethodSettings)

-- | Indicates whether CloudWatch metrics are enabled for the method.
awsApiGatewayMethodSettings_metricsEnabled :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Bool)
awsApiGatewayMethodSettings_metricsEnabled :: (Maybe Bool -> f (Maybe Bool))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_metricsEnabled = (AwsApiGatewayMethodSettings -> Maybe Bool)
-> (AwsApiGatewayMethodSettings
    -> Maybe Bool -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Bool
metricsEnabled :: Maybe Bool
$sel:metricsEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
metricsEnabled} -> Maybe Bool
metricsEnabled) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Bool
a -> AwsApiGatewayMethodSettings
s {$sel:metricsEnabled:AwsApiGatewayMethodSettings' :: Maybe Bool
metricsEnabled = Maybe Bool
a} :: AwsApiGatewayMethodSettings)

-- | Indicates how to handle unauthorized requests for cache invalidation.
--
-- Valid values: @FAIL_WITH_403@ | @SUCCEED_WITH_RESPONSE_HEADER@ |
-- @SUCCEED_WITHOUT_RESPONSE_HEADER@
awsApiGatewayMethodSettings_unauthorizedCacheControlHeaderStrategy :: Lens.Lens' AwsApiGatewayMethodSettings (Prelude.Maybe Prelude.Text)
awsApiGatewayMethodSettings_unauthorizedCacheControlHeaderStrategy :: (Maybe Text -> f (Maybe Text))
-> AwsApiGatewayMethodSettings -> f AwsApiGatewayMethodSettings
awsApiGatewayMethodSettings_unauthorizedCacheControlHeaderStrategy = (AwsApiGatewayMethodSettings -> Maybe Text)
-> (AwsApiGatewayMethodSettings
    -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Lens
     AwsApiGatewayMethodSettings
     AwsApiGatewayMethodSettings
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsApiGatewayMethodSettings' {Maybe Text
unauthorizedCacheControlHeaderStrategy :: Maybe Text
$sel:unauthorizedCacheControlHeaderStrategy:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
unauthorizedCacheControlHeaderStrategy} -> Maybe Text
unauthorizedCacheControlHeaderStrategy) (\s :: AwsApiGatewayMethodSettings
s@AwsApiGatewayMethodSettings' {} Maybe Text
a -> AwsApiGatewayMethodSettings
s {$sel:unauthorizedCacheControlHeaderStrategy:AwsApiGatewayMethodSettings' :: Maybe Text
unauthorizedCacheControlHeaderStrategy = Maybe Text
a} :: AwsApiGatewayMethodSettings)

instance Core.FromJSON AwsApiGatewayMethodSettings where
  parseJSON :: Value -> Parser AwsApiGatewayMethodSettings
parseJSON =
    String
-> (Object -> Parser AwsApiGatewayMethodSettings)
-> Value
-> Parser AwsApiGatewayMethodSettings
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsApiGatewayMethodSettings"
      ( \Object
x ->
          Maybe Bool
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> Maybe Double
-> Maybe Bool
-> Maybe Text
-> AwsApiGatewayMethodSettings
AwsApiGatewayMethodSettings'
            (Maybe Bool
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Bool
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe Text
 -> Maybe Double
 -> Maybe Bool
 -> Maybe Text
 -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Bool)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DataTraceEnabled")
            Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Int
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CacheTtlInSeconds")
            Parser
  (Maybe Text
   -> Maybe Int
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"HttpMethod")
            Parser
  (Maybe Int
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Int)
-> Parser
     (Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ThrottlingBurstLimit")
            Parser
  (Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Bool)
-> Parser
     (Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CacheDataEncrypted")
            Parser
  (Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Text)
-> Parser
     (Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LoggingLevel")
            Parser
  (Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Bool)
-> Parser
     (Maybe Bool
      -> Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RequireAuthorizationForCacheControl")
            Parser
  (Maybe Bool
   -> Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Bool)
-> Parser
     (Maybe Text
      -> Maybe Double
      -> Maybe Bool
      -> Maybe Text
      -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CachingEnabled")
            Parser
  (Maybe Text
   -> Maybe Double
   -> Maybe Bool
   -> Maybe Text
   -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Text)
-> Parser
     (Maybe Double
      -> Maybe Bool -> Maybe Text -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ResourcePath")
            Parser
  (Maybe Double
   -> Maybe Bool -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Double)
-> Parser (Maybe Bool -> Maybe Text -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Double)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ThrottlingRateLimit")
            Parser (Maybe Bool -> Maybe Text -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Bool)
-> Parser (Maybe Text -> AwsApiGatewayMethodSettings)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MetricsEnabled")
            Parser (Maybe Text -> AwsApiGatewayMethodSettings)
-> Parser (Maybe Text) -> Parser AwsApiGatewayMethodSettings
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"UnauthorizedCacheControlHeaderStrategy"
                        )
      )

instance Prelude.Hashable AwsApiGatewayMethodSettings

instance Prelude.NFData AwsApiGatewayMethodSettings

instance Core.ToJSON AwsApiGatewayMethodSettings where
  toJSON :: AwsApiGatewayMethodSettings -> Value
toJSON AwsApiGatewayMethodSettings' {Maybe Bool
Maybe Double
Maybe Int
Maybe Text
unauthorizedCacheControlHeaderStrategy :: Maybe Text
metricsEnabled :: Maybe Bool
throttlingRateLimit :: Maybe Double
resourcePath :: Maybe Text
cachingEnabled :: Maybe Bool
requireAuthorizationForCacheControl :: Maybe Bool
loggingLevel :: Maybe Text
cacheDataEncrypted :: Maybe Bool
throttlingBurstLimit :: Maybe Int
httpMethod :: Maybe Text
cacheTtlInSeconds :: Maybe Int
dataTraceEnabled :: Maybe Bool
$sel:unauthorizedCacheControlHeaderStrategy:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
$sel:metricsEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
$sel:throttlingRateLimit:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Double
$sel:resourcePath:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
$sel:cachingEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
$sel:requireAuthorizationForCacheControl:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
$sel:loggingLevel:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
$sel:cacheDataEncrypted:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
$sel:throttlingBurstLimit:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Int
$sel:httpMethod:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Text
$sel:cacheTtlInSeconds:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Int
$sel:dataTraceEnabled:AwsApiGatewayMethodSettings' :: AwsApiGatewayMethodSettings -> Maybe Bool
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"DataTraceEnabled" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
dataTraceEnabled,
            (Text
"CacheTtlInSeconds" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
cacheTtlInSeconds,
            (Text
"HttpMethod" 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
httpMethod,
            (Text
"ThrottlingBurstLimit" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
throttlingBurstLimit,
            (Text
"CacheDataEncrypted" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
cacheDataEncrypted,
            (Text
"LoggingLevel" 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
loggingLevel,
            (Text
"RequireAuthorizationForCacheControl" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
requireAuthorizationForCacheControl,
            (Text
"CachingEnabled" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
cachingEnabled,
            (Text
"ResourcePath" 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
resourcePath,
            (Text
"ThrottlingRateLimit" Text -> Double -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Double -> Pair) -> Maybe Double -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Double
throttlingRateLimit,
            (Text
"MetricsEnabled" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
metricsEnabled,
            (Text
"UnauthorizedCacheControlHeaderStrategy" 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
unauthorizedCacheControlHeaderStrategy
          ]
      )