RateLimitedApiKeyProps
- class aws_cdk.aws_apigatewayv2.RateLimitedApiKeyProps(*, api_key_name=None, description=None, value=None, customer_id=None, enabled=None, generate_distinct_id=None, api_stages=None, quota=None, throttle=None)
Bases:
ApiKeyProps
RateLimitedApiKey properties.
- Parameters:
api_key_name (
Optional
[str
]) – A name for the API key. If you don’t specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the API key name. Default: automatically generated namedescription (
Optional
[str
]) – A description of the purpose of the API key. Default: nonevalue (
Optional
[str
]) – The value of the API key. Must be at least 20 characters long. Default: nonecustomer_id (
Optional
[str
]) – An AWS Marketplace customer identifier to use when integrating with the AWS SaaS Marketplace. Default: noneenabled (
Optional
[bool
]) – Indicates whether the API key can be used by clients. Default: truegenerate_distinct_id (
Optional
[bool
]) – Specifies whether the key identifier is distinct from the created API key value. Default: falseapi_stages (
Optional
[Sequence
[Union
[UsagePlanPerApiStage
,Dict
[str
,Any
]]]]) – API Stages to be associated with the RateLimitedApiKey. Default: nonequota (
Union
[QuotaSettings
,Dict
[str
,Any
],None
]) – Number of requests clients can make in a given time period. Default: nonethrottle (
Union
[ThrottleSettings
,Dict
[str
,Any
],None
]) – Overall throttle settings for the API. Default: none
- ExampleMetadata:
infused
Example:
# api: apigwv2.WebSocketApi # stage: apigwv2.WebSocketStage key = apigwv2.RateLimitedApiKey(self, "rate-limited-api-key", customer_id="test-customer", api_stages=[apigwv2.UsagePlanPerApiStage( api=api, stage=stage )], quota=apigwv2.QuotaSettings( limit=10000, period=apigwv2.Period.MONTH ), throttle=apigwv2.ThrottleSettings( rate_limit=100, burst_limit=200 ) )
Attributes
- api_key_name
A name for the API key.
If you don’t specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the API key name.
- Default:
automatically generated name
- Link:
- api_stages
API Stages to be associated with the RateLimitedApiKey.
- Default:
none
- customer_id
An AWS Marketplace customer identifier to use when integrating with the AWS SaaS Marketplace.
- description
A description of the purpose of the API key.
- enabled
Indicates whether the API key can be used by clients.
- generate_distinct_id
Specifies whether the key identifier is distinct from the created API key value.
- quota
Number of requests clients can make in a given time period.
- Default:
none
- throttle
Overall throttle settings for the API.
- Default:
none
- value
The value of the API key.
Must be at least 20 characters long.