Skip to content

Set CORS Header for default API Gateway responses (4xx/5xx) #74

Description

@clebert
No description provided.

Activity

  1. unstubbable commented on Apr 6, 2020

    @unstubbable
    Collaborator

    Maybe this could work:

    new CfnGatewayResponse(stack, 'ApiGatewayUnauthorizedResponse', {
        statusCode: '4xx',
        responseType: 'DEFAULT_4XX',
        restApiId: restApi.restApiId,
        responseParameters: {
          'gatewayresponse.header.Access-Control-Allow-Origin': "'*'",
        },
      });
  2. unstubbable commented on Apr 6, 2020

    @unstubbable
    Collaborator
  3. removed their assignment
    on Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions