Have not been able to find a single example or documentation showing how to properly do a use swagger to define a mock integration for API Gateway. I just want to set up a mock integration as a stand-in backend to develop with:
x-amazon-apigateway-integration:
type: mock
responses:
default:
statusCode: 200
responseParameters:
method.response.header.Access-Control-Allow-Methods: “‘GET,HEAD,OPTIONS’”
method.response.header.Access-Control-Allow-Headers: “‘Content-Type,Authorization,X-Amz-Date,X-Api-Key,X-Amz-Security-Token’”
method.response.header.Access-Control-Allow-Origin: “‘*’”
passthroughBehavior: when_no_match
requestTemplates:
application/json: “{"statusCode": 200}”
responseTemplates: “{"helloBody": "helloBodyData"}”
what it do?
Related discussions: