AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::ApiGateway::UsagePlan

CfnUsagePlan

The `AWS::ApiGateway::UsagePlan` resource creates a usage plan for deployed APIs. A usage plan sets a target for the throttling and quota limits on individual client API keys. For more information, see [Creating and Using API Usage Plans in Amazon API Gateway](https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-api-usage-plans.html) in the *API Gateway Developer Guide* . In some cases clients can exceed the targets that you set. Don’t rely on usage plans to control costs. Consider using [AWS Budgets](https://docs.aws.amazon.com/cost-management/latest/userguide/budgets-managing-costs.html) to monitor costs and [AWS WAF](https://docs.aws.amazon.com/waf/latest/developerguide/waf-chapter.html) to manage API requests.

Import

import { CfnUsagePlan } from 'aws-cdk-lib/aws-apigateway';

Or use the module namespace:

import * as apigateway from 'aws-cdk-lib/aws-apigateway';
// apigateway.CfnUsagePlan

Properties

Configuration passed to the constructor as CfnUsagePlanProps.

apiStagesOptional
IResolvable | IResolvable | ApiStageProperty[]

The associated API stages of a usage plan.

descriptionOptional
string

The description of a usage plan.

quotaOptional
IResolvable | QuotaSettingsProperty

The target maximum number of permitted requests per a given unit time interval.

tagsOptional
CfnTag[]

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

throttleOptional
IResolvable | ThrottleSettingsProperty

A map containing method level throttling information for API stage in a usage plan.

usagePlanNameOptional
string

The name of a usage plan.

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Get the Amazon API Gateway Cheat Sheet

Everything you need to know about Amazon API Gateway on one page. HD quality, print-friendly.

Download Free Infographic