amazonka-apigateway-2.0: Amazon API Gateway SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.APIGateway.CreateApiKey

Description

Create an ApiKey resource.

Synopsis

Creating a Request

data CreateApiKey Source #

Request to create an ApiKey resource.

See: newCreateApiKey smart constructor.

Constructors

CreateApiKey' 

Fields

  • customerId :: Maybe Text

    An AWS Marketplace customer identifier , when integrating with the AWS SaaS Marketplace.

  • description :: Maybe Text

    The description of the ApiKey.

  • enabled :: Maybe Bool

    Specifies whether the ApiKey can be used by callers.

  • generateDistinctId :: Maybe Bool

    Specifies whether (true) or not (false) the key identifier is distinct from the created API key value. This parameter is deprecated and should not be used.

  • name :: Maybe Text

    The name of the ApiKey.

  • stageKeys :: Maybe [StageKey]

    DEPRECATED FOR USAGE PLANS - Specifies stages associated with the API key.

  • tags :: Maybe (HashMap Text Text)

    The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.

  • value :: Maybe Text

    Specifies a value of the API key.

Instances

Instances details
ToJSON CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

ToHeaders CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

ToPath CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

ToQuery CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

AWSRequest CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

Associated Types

type AWSResponse CreateApiKey #

Generic CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

Associated Types

type Rep CreateApiKey :: Type -> Type #

Read CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

Show CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

NFData CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

Methods

rnf :: CreateApiKey -> () #

Eq CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

Hashable CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

type AWSResponse CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

type Rep CreateApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.CreateApiKey

newCreateApiKey :: CreateApiKey Source #

Create a value of CreateApiKey with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

CreateApiKey, createApiKey_customerId - An AWS Marketplace customer identifier , when integrating with the AWS SaaS Marketplace.

CreateApiKey, createApiKey_description - The description of the ApiKey.

CreateApiKey, createApiKey_enabled - Specifies whether the ApiKey can be used by callers.

$sel:generateDistinctId:CreateApiKey', createApiKey_generateDistinctId - Specifies whether (true) or not (false) the key identifier is distinct from the created API key value. This parameter is deprecated and should not be used.

CreateApiKey, createApiKey_name - The name of the ApiKey.

CreateApiKey, createApiKey_stageKeys - DEPRECATED FOR USAGE PLANS - Specifies stages associated with the API key.

CreateApiKey, createApiKey_tags - The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.

CreateApiKey, createApiKey_value - Specifies a value of the API key.

Request Lenses

createApiKey_customerId :: Lens' CreateApiKey (Maybe Text) Source #

An AWS Marketplace customer identifier , when integrating with the AWS SaaS Marketplace.

createApiKey_description :: Lens' CreateApiKey (Maybe Text) Source #

The description of the ApiKey.

createApiKey_enabled :: Lens' CreateApiKey (Maybe Bool) Source #

Specifies whether the ApiKey can be used by callers.

createApiKey_generateDistinctId :: Lens' CreateApiKey (Maybe Bool) Source #

Specifies whether (true) or not (false) the key identifier is distinct from the created API key value. This parameter is deprecated and should not be used.

createApiKey_name :: Lens' CreateApiKey (Maybe Text) Source #

The name of the ApiKey.

createApiKey_stageKeys :: Lens' CreateApiKey (Maybe [StageKey]) Source #

DEPRECATED FOR USAGE PLANS - Specifies stages associated with the API key.

createApiKey_tags :: Lens' CreateApiKey (Maybe (HashMap Text Text)) Source #

The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.

createApiKey_value :: Lens' CreateApiKey (Maybe Text) Source #

Specifies a value of the API key.

Destructuring the Response

data ApiKey Source #

A resource that can be distributed to callers for executing Method resources that require an API key. API keys can be mapped to any Stage on any RestApi, which indicates that the callers with the API key can make requests to that stage.

See: newApiKey smart constructor.

Constructors

ApiKey' 

Fields

Instances

Instances details
FromJSON ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Generic ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Associated Types

type Rep ApiKey :: Type -> Type #

Methods

from :: ApiKey -> Rep ApiKey x #

to :: Rep ApiKey x -> ApiKey #

Read ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Show ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

NFData ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Methods

rnf :: ApiKey -> () #

Eq ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Methods

(==) :: ApiKey -> ApiKey -> Bool #

(/=) :: ApiKey -> ApiKey -> Bool #

Hashable ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

Methods

hashWithSalt :: Int -> ApiKey -> Int #

hash :: ApiKey -> Int #

type Rep ApiKey Source # 
Instance details

Defined in Amazonka.APIGateway.Types.ApiKey

newApiKey :: ApiKey Source #

Create a value of ApiKey with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:createdDate:ApiKey', apiKey_createdDate - The timestamp when the API Key was created.

$sel:customerId:ApiKey', apiKey_customerId - An AWS Marketplace customer identifier , when integrating with the AWS SaaS Marketplace.

$sel:description:ApiKey', apiKey_description - The description of the API Key.

$sel:enabled:ApiKey', apiKey_enabled - Specifies whether the API Key can be used by callers.

$sel:id:ApiKey', apiKey_id - The identifier of the API Key.

$sel:lastUpdatedDate:ApiKey', apiKey_lastUpdatedDate - The timestamp when the API Key was last updated.

$sel:name:ApiKey', apiKey_name - The name of the API Key.

$sel:stageKeys:ApiKey', apiKey_stageKeys - A list of Stage resources that are associated with the ApiKey resource.

$sel:tags:ApiKey', apiKey_tags - The collection of tags. Each tag element is associated with a given resource.

$sel:value:ApiKey', apiKey_value - The value of the API Key.

Response Lenses

apiKey_createdDate :: Lens' ApiKey (Maybe UTCTime) Source #

The timestamp when the API Key was created.

apiKey_customerId :: Lens' ApiKey (Maybe Text) Source #

An AWS Marketplace customer identifier , when integrating with the AWS SaaS Marketplace.

apiKey_description :: Lens' ApiKey (Maybe Text) Source #

The description of the API Key.

apiKey_enabled :: Lens' ApiKey (Maybe Bool) Source #

Specifies whether the API Key can be used by callers.

apiKey_id :: Lens' ApiKey (Maybe Text) Source #

The identifier of the API Key.

apiKey_lastUpdatedDate :: Lens' ApiKey (Maybe UTCTime) Source #

The timestamp when the API Key was last updated.

apiKey_name :: Lens' ApiKey (Maybe Text) Source #

The name of the API Key.

apiKey_stageKeys :: Lens' ApiKey (Maybe [Text]) Source #

A list of Stage resources that are associated with the ApiKey resource.

apiKey_tags :: Lens' ApiKey (Maybe (HashMap Text Text)) Source #

The collection of tags. Each tag element is associated with a given resource.

apiKey_value :: Lens' ApiKey (Maybe Text) Source #

The value of the API Key.