{-# 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.DataExchange.Types.ImportAssetFromApiGatewayApiRequestDetails
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.DataExchange.Types.ImportAssetFromApiGatewayApiRequestDetails where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.DataExchange.Types.ProtocolType
import qualified Amazonka.Prelude as Prelude

-- | The request details.
--
-- /See:/ 'newImportAssetFromApiGatewayApiRequestDetails' smart constructor.
data ImportAssetFromApiGatewayApiRequestDetails = ImportAssetFromApiGatewayApiRequestDetails'
  { -- | The API description. Markdown supported.
    ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
apiDescription :: Prelude.Maybe Prelude.Text,
    -- | The API Gateway API key.
    ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
apiKey :: Prelude.Maybe Prelude.Text,
    -- | The API Gateway API ID.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
apiId :: Prelude.Text,
    -- | The API name.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
apiName :: Prelude.Text,
    -- | The Base64-encoded MD5 hash of the OpenAPI 3.0 JSON API specification
    -- file. It is used to ensure the integrity of the file.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
apiSpecificationMd5Hash :: Prelude.Text,
    -- | The data set ID.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
dataSetId :: Prelude.Text,
    -- | The protocol type.
    ImportAssetFromApiGatewayApiRequestDetails -> ProtocolType
protocolType :: ProtocolType,
    -- | The revision ID.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
revisionId :: Prelude.Text,
    -- | The API stage.
    ImportAssetFromApiGatewayApiRequestDetails -> Text
stage :: Prelude.Text
  }
  deriving (ImportAssetFromApiGatewayApiRequestDetails
-> ImportAssetFromApiGatewayApiRequestDetails -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ImportAssetFromApiGatewayApiRequestDetails
-> ImportAssetFromApiGatewayApiRequestDetails -> Bool
$c/= :: ImportAssetFromApiGatewayApiRequestDetails
-> ImportAssetFromApiGatewayApiRequestDetails -> Bool
== :: ImportAssetFromApiGatewayApiRequestDetails
-> ImportAssetFromApiGatewayApiRequestDetails -> Bool
$c== :: ImportAssetFromApiGatewayApiRequestDetails
-> ImportAssetFromApiGatewayApiRequestDetails -> Bool
Prelude.Eq, ReadPrec [ImportAssetFromApiGatewayApiRequestDetails]
ReadPrec ImportAssetFromApiGatewayApiRequestDetails
Int -> ReadS ImportAssetFromApiGatewayApiRequestDetails
ReadS [ImportAssetFromApiGatewayApiRequestDetails]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ImportAssetFromApiGatewayApiRequestDetails]
$creadListPrec :: ReadPrec [ImportAssetFromApiGatewayApiRequestDetails]
readPrec :: ReadPrec ImportAssetFromApiGatewayApiRequestDetails
$creadPrec :: ReadPrec ImportAssetFromApiGatewayApiRequestDetails
readList :: ReadS [ImportAssetFromApiGatewayApiRequestDetails]
$creadList :: ReadS [ImportAssetFromApiGatewayApiRequestDetails]
readsPrec :: Int -> ReadS ImportAssetFromApiGatewayApiRequestDetails
$creadsPrec :: Int -> ReadS ImportAssetFromApiGatewayApiRequestDetails
Prelude.Read, Int -> ImportAssetFromApiGatewayApiRequestDetails -> ShowS
[ImportAssetFromApiGatewayApiRequestDetails] -> ShowS
ImportAssetFromApiGatewayApiRequestDetails -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ImportAssetFromApiGatewayApiRequestDetails] -> ShowS
$cshowList :: [ImportAssetFromApiGatewayApiRequestDetails] -> ShowS
show :: ImportAssetFromApiGatewayApiRequestDetails -> String
$cshow :: ImportAssetFromApiGatewayApiRequestDetails -> String
showsPrec :: Int -> ImportAssetFromApiGatewayApiRequestDetails -> ShowS
$cshowsPrec :: Int -> ImportAssetFromApiGatewayApiRequestDetails -> ShowS
Prelude.Show, forall x.
Rep ImportAssetFromApiGatewayApiRequestDetails x
-> ImportAssetFromApiGatewayApiRequestDetails
forall x.
ImportAssetFromApiGatewayApiRequestDetails
-> Rep ImportAssetFromApiGatewayApiRequestDetails x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ImportAssetFromApiGatewayApiRequestDetails x
-> ImportAssetFromApiGatewayApiRequestDetails
$cfrom :: forall x.
ImportAssetFromApiGatewayApiRequestDetails
-> Rep ImportAssetFromApiGatewayApiRequestDetails x
Prelude.Generic)

-- |
-- Create a value of 'ImportAssetFromApiGatewayApiRequestDetails' 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:
--
-- 'apiDescription', 'importAssetFromApiGatewayApiRequestDetails_apiDescription' - The API description. Markdown supported.
--
-- 'apiKey', 'importAssetFromApiGatewayApiRequestDetails_apiKey' - The API Gateway API key.
--
-- 'apiId', 'importAssetFromApiGatewayApiRequestDetails_apiId' - The API Gateway API ID.
--
-- 'apiName', 'importAssetFromApiGatewayApiRequestDetails_apiName' - The API name.
--
-- 'apiSpecificationMd5Hash', 'importAssetFromApiGatewayApiRequestDetails_apiSpecificationMd5Hash' - The Base64-encoded MD5 hash of the OpenAPI 3.0 JSON API specification
-- file. It is used to ensure the integrity of the file.
--
-- 'dataSetId', 'importAssetFromApiGatewayApiRequestDetails_dataSetId' - The data set ID.
--
-- 'protocolType', 'importAssetFromApiGatewayApiRequestDetails_protocolType' - The protocol type.
--
-- 'revisionId', 'importAssetFromApiGatewayApiRequestDetails_revisionId' - The revision ID.
--
-- 'stage', 'importAssetFromApiGatewayApiRequestDetails_stage' - The API stage.
newImportAssetFromApiGatewayApiRequestDetails ::
  -- | 'apiId'
  Prelude.Text ->
  -- | 'apiName'
  Prelude.Text ->
  -- | 'apiSpecificationMd5Hash'
  Prelude.Text ->
  -- | 'dataSetId'
  Prelude.Text ->
  -- | 'protocolType'
  ProtocolType ->
  -- | 'revisionId'
  Prelude.Text ->
  -- | 'stage'
  Prelude.Text ->
  ImportAssetFromApiGatewayApiRequestDetails
newImportAssetFromApiGatewayApiRequestDetails :: Text
-> Text
-> Text
-> Text
-> ProtocolType
-> Text
-> Text
-> ImportAssetFromApiGatewayApiRequestDetails
newImportAssetFromApiGatewayApiRequestDetails
  Text
pApiId_
  Text
pApiName_
  Text
pApiSpecificationMd5Hash_
  Text
pDataSetId_
  ProtocolType
pProtocolType_
  Text
pRevisionId_
  Text
pStage_ =
    ImportAssetFromApiGatewayApiRequestDetails'
      { $sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: Maybe Text
apiDescription =
          forall a. Maybe a
Prelude.Nothing,
        $sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: Maybe Text
apiKey = forall a. Maybe a
Prelude.Nothing,
        $sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiId = Text
pApiId_,
        $sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiName = Text
pApiName_,
        $sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiSpecificationMd5Hash =
          Text
pApiSpecificationMd5Hash_,
        $sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
dataSetId = Text
pDataSetId_,
        $sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ProtocolType
protocolType = ProtocolType
pProtocolType_,
        $sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
revisionId = Text
pRevisionId_,
        $sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: Text
stage = Text
pStage_
      }

-- | The API description. Markdown supported.
importAssetFromApiGatewayApiRequestDetails_apiDescription :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails (Prelude.Maybe Prelude.Text)
importAssetFromApiGatewayApiRequestDetails_apiDescription :: Lens' ImportAssetFromApiGatewayApiRequestDetails (Maybe Text)
importAssetFromApiGatewayApiRequestDetails_apiDescription = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Maybe Text
apiDescription :: Maybe Text
$sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
apiDescription} -> Maybe Text
apiDescription) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Maybe Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: Maybe Text
apiDescription = Maybe Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The API Gateway API key.
importAssetFromApiGatewayApiRequestDetails_apiKey :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails (Prelude.Maybe Prelude.Text)
importAssetFromApiGatewayApiRequestDetails_apiKey :: Lens' ImportAssetFromApiGatewayApiRequestDetails (Maybe Text)
importAssetFromApiGatewayApiRequestDetails_apiKey = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Maybe Text
apiKey :: Maybe Text
$sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
apiKey} -> Maybe Text
apiKey) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Maybe Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: Maybe Text
apiKey = Maybe Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The API Gateway API ID.
importAssetFromApiGatewayApiRequestDetails_apiId :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_apiId :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_apiId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
apiId :: Text
$sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
apiId} -> Text
apiId) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiId = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The API name.
importAssetFromApiGatewayApiRequestDetails_apiName :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_apiName :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_apiName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
apiName :: Text
$sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
apiName} -> Text
apiName) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiName = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The Base64-encoded MD5 hash of the OpenAPI 3.0 JSON API specification
-- file. It is used to ensure the integrity of the file.
importAssetFromApiGatewayApiRequestDetails_apiSpecificationMd5Hash :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_apiSpecificationMd5Hash :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_apiSpecificationMd5Hash = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
apiSpecificationMd5Hash :: Text
$sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
apiSpecificationMd5Hash} -> Text
apiSpecificationMd5Hash) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: Text
apiSpecificationMd5Hash = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The data set ID.
importAssetFromApiGatewayApiRequestDetails_dataSetId :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_dataSetId :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_dataSetId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
dataSetId :: Text
$sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
dataSetId} -> Text
dataSetId) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
dataSetId = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The protocol type.
importAssetFromApiGatewayApiRequestDetails_protocolType :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails ProtocolType
importAssetFromApiGatewayApiRequestDetails_protocolType :: Lens' ImportAssetFromApiGatewayApiRequestDetails ProtocolType
importAssetFromApiGatewayApiRequestDetails_protocolType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {ProtocolType
protocolType :: ProtocolType
$sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> ProtocolType
protocolType} -> ProtocolType
protocolType) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} ProtocolType
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ProtocolType
protocolType = ProtocolType
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The revision ID.
importAssetFromApiGatewayApiRequestDetails_revisionId :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_revisionId :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_revisionId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
revisionId :: Text
$sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
revisionId} -> Text
revisionId) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: Text
revisionId = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

-- | The API stage.
importAssetFromApiGatewayApiRequestDetails_stage :: Lens.Lens' ImportAssetFromApiGatewayApiRequestDetails Prelude.Text
importAssetFromApiGatewayApiRequestDetails_stage :: Lens' ImportAssetFromApiGatewayApiRequestDetails Text
importAssetFromApiGatewayApiRequestDetails_stage = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ImportAssetFromApiGatewayApiRequestDetails' {Text
stage :: Text
$sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
stage} -> Text
stage) (\s :: ImportAssetFromApiGatewayApiRequestDetails
s@ImportAssetFromApiGatewayApiRequestDetails' {} Text
a -> ImportAssetFromApiGatewayApiRequestDetails
s {$sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: Text
stage = Text
a} :: ImportAssetFromApiGatewayApiRequestDetails)

instance
  Prelude.Hashable
    ImportAssetFromApiGatewayApiRequestDetails
  where
  hashWithSalt :: Int -> ImportAssetFromApiGatewayApiRequestDetails -> Int
hashWithSalt
    Int
_salt
    ImportAssetFromApiGatewayApiRequestDetails' {Maybe Text
Text
ProtocolType
stage :: Text
revisionId :: Text
protocolType :: ProtocolType
dataSetId :: Text
apiSpecificationMd5Hash :: Text
apiName :: Text
apiId :: Text
apiKey :: Maybe Text
apiDescription :: Maybe Text
$sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> ProtocolType
$sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
$sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
..} =
      Int
_salt
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
apiDescription
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
apiKey
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
apiId
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
apiName
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
apiSpecificationMd5Hash
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
dataSetId
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` ProtocolType
protocolType
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
revisionId
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
stage

instance
  Prelude.NFData
    ImportAssetFromApiGatewayApiRequestDetails
  where
  rnf :: ImportAssetFromApiGatewayApiRequestDetails -> ()
rnf ImportAssetFromApiGatewayApiRequestDetails' {Maybe Text
Text
ProtocolType
stage :: Text
revisionId :: Text
protocolType :: ProtocolType
dataSetId :: Text
apiSpecificationMd5Hash :: Text
apiName :: Text
apiId :: Text
apiKey :: Maybe Text
apiDescription :: Maybe Text
$sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> ProtocolType
$sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
$sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
apiDescription
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
apiKey
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
apiId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
apiName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
apiSpecificationMd5Hash
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
dataSetId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf ProtocolType
protocolType
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
revisionId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
stage

instance
  Data.ToJSON
    ImportAssetFromApiGatewayApiRequestDetails
  where
  toJSON :: ImportAssetFromApiGatewayApiRequestDetails -> Value
toJSON
    ImportAssetFromApiGatewayApiRequestDetails' {Maybe Text
Text
ProtocolType
stage :: Text
revisionId :: Text
protocolType :: ProtocolType
dataSetId :: Text
apiSpecificationMd5Hash :: Text
apiName :: Text
apiId :: Text
apiKey :: Maybe Text
apiDescription :: Maybe Text
$sel:stage:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:revisionId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:protocolType:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> ProtocolType
$sel:dataSetId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiSpecificationMd5Hash:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiName:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiId:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Text
$sel:apiKey:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
$sel:apiDescription:ImportAssetFromApiGatewayApiRequestDetails' :: ImportAssetFromApiGatewayApiRequestDetails -> Maybe Text
..} =
      [Pair] -> Value
Data.object
        ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
            [ (Key
"ApiDescription" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
                forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
apiDescription,
              (Key
"ApiKey" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
apiKey,
              forall a. a -> Maybe a
Prelude.Just (Key
"ApiId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
apiId),
              forall a. a -> Maybe a
Prelude.Just (Key
"ApiName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
apiName),
              forall a. a -> Maybe a
Prelude.Just
                ( Key
"ApiSpecificationMd5Hash"
                    forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
apiSpecificationMd5Hash
                ),
              forall a. a -> Maybe a
Prelude.Just (Key
"DataSetId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
dataSetId),
              forall a. a -> Maybe a
Prelude.Just (Key
"ProtocolType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= ProtocolType
protocolType),
              forall a. a -> Maybe a
Prelude.Just (Key
"RevisionId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
revisionId),
              forall a. a -> Maybe a
Prelude.Just (Key
"Stage" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
stage)
            ]
        )