January 2019
Intermediate to advanced
490 pages
15h 37m
English
Now, let's create the API by using a CloudFormation template. We will not discuss the components that were already discussed in previous recipes, nor will we discuss the theory for commands that were already discussed within the CLI commands section. The complete code is available in the code files.
With the CloudFormation template, the major change is within the Integration property of the resource type AWS::ApiGateway::Method, as follows:
Integration: Type: AWS IntegrationHttpMethod: POST PassthroughBehavior: WHEN_NO_TEMPLATES RequestTemplates: application/json: "{ \"name\" : $input.json('$.user.name'), \"time\": $input.json('$.greeting.time') }" IntegrationResponses: - StatusCode: 200 ResponseTemplates ...
Read now
Unlock full access