Skip to content
This repository was archived by the owner on Jan 12, 2023. It is now read-only.
This repository was archived by the owner on Jan 12, 2023. It is now read-only.

Use proper AWS API Gateway error handling #32

@mrserverless

Description

@mrserverless

As per documentation:

https://aws.amazon.com/blogs/compute/error-handling-patterns-in-amazon-api-gateway-and-aws-lambda/

Errors should return with either prefixes:

[BadRequest] | 400
[Forbidden] | 403
[NotFound] | 404
[InternalServerError] | 500

Or as the following payload:

{
    "errorType" : "InternalServerError",
    "httpStatus" : 500,
    "requestId" : "<context.awsRequestId>",
    "message" : "An unknown error has occurred. Please try again."
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions