Posted On: Apr 20, 2023

The AWS Serverless Application Model (SAM) Command Line Interface (CLI) announces the launch of local testing support for Amazon API Gateway Lambda authorizers making it easier for developers to locally test their applications containing API Gateway. The AWS SAM CLI is a developer tool that makes it easier to build, test, package, and deploy serverless applications.

Customers can now use the SAM CLI to locally emulate API Gateway Lambda authorizers on their machine using the sam local start-api command. Previously, customers had to use AWS Console or AWS CLI to test their API Gateway Lambda authorizers. With this launch, SAM CLI users can speed up their iteration cycles by testing their authorizer code locally. sam local start-api command supports testing of both Lambda authorizers, and Lambda V2 authorizers.

This feature is available with SAM CLI version 1.80.0+. To learn more about this feature, please see the documentation. You can install the latest version of the SAM CLI by following the instructions in the documentation.