AWS::ApiGateway::RestApiThe AWS::ApiGateway::RestApi resource creates a REST API. For more information, see [restapi:create](https://docs.aws.amazon.com/apigateway/latest/api/API_CreateRestApi.html) in the *Amazon API Gateway REST API Reference*. On January 1, 2016, the Swagger Specification was donated to the [OpenAPI initiative](https://docs.aws.amazon.com/https://www.openapis.org/), becoming the foundation of the OpenAPI Specification.
17 configurable properties. Click a row to see details.
| Property | Type | Flags |
|---|---|---|
ApiKeySourceType | string | |
BinaryMediaTypes | Array<string> | |
Body | objectstring | Write-only |
BodyS3Location | S3Location | Write-only |
CloneFrom | string | Write-only |
Description | string | |
DisableExecuteApiEndpoint | boolean | |
EndpointAccessMode | string | |
EndpointConfiguration | EndpointConfiguration | |
FailOnWarnings | boolean | Write-only |
MinimumCompressionSize | integer | |
Mode | string | Write-only |
Name | string | |
Parameters | objectstring | Write-only |
Policy | objectstring | |
SecurityPolicy | string | |
Tags | Array<Tag> |
Values returned after the resource is created. Access these with Fn::GetAtt.
| Attribute | Type | Description |
|---|---|---|
RestApiId | string | - |
RootResourceId | string | - |
A minimal template with required properties and common optional ones.
AWSTemplateFormatVersion: "2010-09-09"
Description: Sample template for AWS::ApiGateway::RestApi
Resources:
MyResource:
Type: AWS::ApiGateway::RestApi
Properties:
Tags:
- Key: Environment
Value: Production
Description: !Ref "AWS::StackName"
Name: !Ref "AWS::StackName"Permissions CloudFormation needs in your IAM role to manage this resource.
apigateway:GETapigateway:GETapigateway:POSTapigateway:PUTapigateway:PATCHapigateway:UpdateRestApiPolicys3:GetObjectiam:PassRoleapigateway:GETapigateway:DELETEapigateway:PATCHapigateway:PUTapigateway:UpdateRestApiPolicys3:GetObjectiam:PassRoleapigateway:GETapigateway:DELETEEverything you need to know about ApiGateway on one page. HD quality, print-friendly.
Download Free InfographicRestApiId