Class RateLimitedApiKeyProps
- Namespace
- Amazon.CDK.AWS.APIGateway
- Assembly
- Amazon.CDK.AWS.APIGateway.dll
RateLimitedApiKey properties.
public class RateLimitedApiKeyProps : IRateLimitedApiKeyProps, IApiKeyProps, IApiKeyOptions, IResourceOptions
- Inheritance
-
RateLimitedApiKeyProps
- Implements
- Inherited Members
Examples
RestApi api;
var key = new RateLimitedApiKey(this, "rate-limited-api-key", new RateLimitedApiKeyProps {
CustomerId = "hello-customer",
Resources = new [] { api },
Quota = new QuotaSettings {
Limit = 10000,
Period = Period.MONTH
}
});
Remarks
ExampleMetadata: infused
Constructors
RateLimitedApiKeyProps()
public RateLimitedApiKeyProps()
Properties
ApiKeyName
A name for the API key.
public string? ApiKeyName { get; set; }
Property Value
Remarks
If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the API key name.
Default: automically generated name
ApiStages
API Stages to be associated with the RateLimitedApiKey.
public IUsagePlanPerApiStage[]? ApiStages { get; set; }
Property Value
Remarks
Default: none
CustomerId
An AWS Marketplace customer identifier to use when integrating with the AWS SaaS Marketplace.
public string? CustomerId { get; set; }
Property Value
Remarks
Default: none
DefaultCorsPreflightOptions
Adds a CORS preflight OPTIONS method to this resource and all child resources.
public ICorsOptions? DefaultCorsPreflightOptions { get; set; }
Property Value
Remarks
You can add CORS at the resource-level using addCorsPreflight
.
Default: - CORS is disabled
DefaultIntegration
An integration to use as a default for all methods created within this API unless an integration is specified.
public Integration? DefaultIntegration { get; set; }
Property Value
Remarks
Default: - Inherited from parent.
DefaultMethodOptions
Method options to use as a default for all methods created within this API unless custom options are specified.
public IMethodOptions? DefaultMethodOptions { get; set; }
Property Value
Remarks
Default: - Inherited from parent.
Description
A description of the purpose of the API key.
public string? Description { get; set; }
Property Value
Remarks
Default: none
Enabled
Indicates whether the API key can be used by clients.
public bool? Enabled { get; set; }
Property Value
- bool?
Remarks
Default: true
GenerateDistinctId
Specifies whether the key identifier is distinct from the created API key value.
public bool? GenerateDistinctId { get; set; }
Property Value
- bool?
Remarks
Default: false
Quota
Number of requests clients can make in a given time period.
public IQuotaSettings? Quota { get; set; }
Property Value
Remarks
Default: none
Resources
A list of resources this api key is associated with.
public IRestApi[]? Resources { get; set; }
Property Value
- IRestApi[]
Remarks
Default: none
Throttle
Overall throttle settings for the API.
public IThrottleSettings? Throttle { get; set; }
Property Value
Remarks
Default: none
Value
The value of the API key.
public string? Value { get; set; }
Property Value
Remarks
Must be at least 20 characters long.
Default: none