1# serverless.yml
2
3...
4
5 resources:
6 Resources:
7 GatewayResponseDefault4XX:
8 Type: 'AWS::ApiGateway::GatewayResponse'
9 Properties:
10 ResponseParameters:
11 gatewayresponse.header.Access-Control-Allow-Origin: "'*'"
12 gatewayresponse.header.Access-Control-Allow-Headers: "'*'"
13 ResponseType: DEFAULT_4XX
14 RestApiId:
15 Ref: 'ApiGatewayRestApi'
16 ```