I am trying to create an AWS::ApiGateway::RestApi using CloudFormation but on startup
aws cloudformation deploy --template file lorem.json --stack-name lorem
This fails and when viewing in the CloudFormation console, I see that the Invalid REST API identifier specified error.

Here is my lorem.json file:
{ "AWSTemplateFormatVersion": "2010-09-09", "Description": "lorem.io Stack", "Resources": { "API": { "Type" : "AWS::ApiGateway::RestApi", "Properties" : { "FailOnWarnings": true, "BodyS3Location": { "Bucket": "cloudformation.lorem.io", "Key": "open-api.json" } } } } }
Here I point to BodyS3Location , which points to an S3 object that contains the following:
{ "swagger": "2.0", "info": { "title": "Lorem.IO API", "version": "1.0.0" }, "definitions": { "Generator": { "type": "object", "properties": { "title": { "type": "string" } } } }, "produces": [ "application/json" ], "paths": { "/generators": { "get": { "responses": { "200": { "schema": { "type": "array", "items": { "$ref": "#/definitions/Generator" } } } } } } } }
Since I provide this file in accordance with the documentation , I do not need to specify the name RestApi, so I do not think that the problem. Any idea on how I will debug that he is unhappy?
Update # 1
I deleted most of my configuration, so the only property I am specifying now is name , and I still get the same error ( Invalid REST API identifier specified ):
{ "AWSTemplateFormatVersion": "2010-09-09", "Description": "lorem.io Stack", "Resources": { "API": { "Type" : "AWS::ApiGateway::RestApi", "Properties" : { "FailOnWarnings": true, "Name": "Hello World" } } } }
According to the documentation, name is the only required attribute. Is this a w / CloudFormation bug or am I missing something?