Amazon API Gateway regional API to AWS Lambda

API Gateway → AWS Lambda

Create a REST regional API and a Lambda function.

This pattern deploys an Amazon API Gateway REST regional API with a Lambda integration.
The AWS Lambda function is written in Python 3.9. The function returns a small message and a status code to the caller.
The inline code of the Lambda function is written in the template itself.

< Back to all patterns

GitHub icon Download this pattern (.zip)

GitHub icon View this pattern on GitHub


Clone repo

git clone https://github.com/aws-samples/serverless-patterns/cd serverless-patterns/apigw-rest-regional-lambda

Deploy

sam deploy


Testing

Once the application is deployed, retrieve the API URL provided as output and open it in a browser page.
You can also make the request from Postman or from a terminal using the curl command.

Cleanup

Delete the stack: sam delete.

Created by:

Alice Goumain

Alice Goumain

Cloud Support Engineer in Serverless @ AWS

Follow on LinkedIn