AWS Compute Blog

Category: Amazon API Gateway

Error Handling Patterns in Amazon API Gateway and AWS Lambda

Ryan Green @ryangtweets Software Development Engineer, API Gateway A common API design practice is to define an explicit contract for the types of error responses that the API can produce. This allows API consumers to implement a robust error-handling mechanism which may include user feedback or automatic retries, improving the usability and reliability of applications […]

Using API Gateway with VPC endpoints via AWS Lambda

To isolate critical parts of their app’s architecture, customers often rely on Virtual Private Cloud (VPC) and private subnets. Today, Amazon API Gateway cannot directly integrate with endpoints that live within a VPC without internet access. However, it is possible to proxy calls to your VPC endpoints using AWS Lambda functions. This post guides you […]

Amazon API Gateway mapping improvements

Yesterday we announced the new Swagger import API. You may have also noticed a new first time user experience in the API Gateway console that automatically creates a sample Pet Store API and guides you though API Gateway features. That is not all we’ve been doing: Over the past few weeks, we’ve made mapping requests and responses easier. […]

Indexing Amazon DynamoDB Content with Amazon Elasticsearch Service Using AWS Lambda

September 8, 2021: Amazon Elasticsearch Service has been renamed to Amazon OpenSearch Service. See details. Stephan HadingerSr Mgr, Solutions Architecture Mathieu Cadet Account Representative NOTE: It was recently brought to our attention that this post contains instructions that reference a now deprecated Lambda blueprint. We are in the process of updating this post to correct this. A […]

Using Amazon API Gateway as a proxy for DynamoDB

This post is written by Andrew Baird, AWS Solutions Architect. Amazon API Gateway has a feature that enables customers to create their own API definitions directly in front of an AWS service API. This tutorial will walk you through an example of doing so with Amazon DynamoDB. You can use the solution described here in […]

Introducing custom authorizers in Amazon API Gateway

Today Amazon API Gateway is launching custom request authorizers. With custom request authorizers, developers can authorize their APIs using bearer token authorization strategies, such as OAuth using an AWS Lambda function. For each incoming request, API Gateway verifies whether a custom authorizer is configured, and if so, API Gateway calls the Lambda function with the […]

Using API Gateway stage variables to manage Lambda functions

Ed Lima, Cloud Support Engineer There’s a new feature on Amazon API Gateway called stage variables. Stage variables act like environment variables and can be used to change the behavior of your API Gateway methods for each deployment stage; for example, making it possible to reach a different back end depending on which stage the […]