Closed
Description
Expected Behavior
The identitySource
field in APIGatewayRequestAuthorizerEventV2
can be null when the Lambda authorizer is not configured with an identity source (see screenshot from the AWS Console below).
Current Behavior
The current definition does not account for this scenario, leading to an error:
Even the @types/aws-lambda
package has invalid type definition:
Code snippet
APIGatewayRequestAuthorizerEventV2Schema.parse(event);
Steps to Reproduce
When creating a Lambda authorizer, do not specify an identity source.
Possible Solution
add .nullable()
Powertools for AWS Lambda (TypeScript) version
latest
AWS Lambda function runtime
20.x
Packaging format used
npm
Execution logs
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Shipped