Questions tagged [amazon-api-gateway]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
13 votes
1 answer
9k views

How do I setup Route 53 to point to Api Gateway

I'm writing a Cloudformation config file to create a website all in one go. This includes, creating lambda functions, creating the API Gateway, Setting up a S3 Bucket, Creating the Route 53 zone and ...
Justin808's user avatar
  • 307
9 votes
4 answers
16k views

How can I use AWS CloudFront and API Gateway side by side for the same domain?

I'm putting that static assets of my website on S3, and setting up CloudFront to distribute them. These essentially holds the content users would need for any GET request on my site, to existing paths ...
Costa Michailidis's user avatar
9 votes
1 answer
18k views

AWS Api Gateway- no integration defined for method

Though I have defined the integration when I try to deploy an api gateway I keep getting "No integration defined for method" error similar to https://stackoverflow.com/questions/46087890/no-...
Surya's user avatar
  • 263
6 votes
1 answer
5k views

Should I use CloudFront in front of API/Web just because I want them on a single domain?

I typically develop my applications with frontend single page application on S3 and backend APIs on a server typically elastic beanstalk (so ELB + EC2). I am confused over what is a good choice to put ...
Jiew Meng's user avatar
  • 241
6 votes
1 answer
4k views

AWS API Gateway Lambda Authorizers + Client certificates

I'm evaluating the use of client certificatates to improve security in an application i'm working on. It all run behind on AWS and pass through an API Gateway with an attached Lambda authorizer. AWS ...
Marcelo Falero's user avatar
5 votes
2 answers
18k views

AWS API gateway as proxy to EC2 based microservices

I have a couple of microservices running on EC2. My intention is to use the AWS API gateway to allow internet access to the EC2 APIs. Incoming Traffic is: internet -> API Gateway -> EC2-server ...
caliph's user avatar
  • 213
4 votes
1 answer
3k views

AWS Lambda, AWS API Gateway, AWS Cloudfront gives 403 error

I run a Django project deployed on AWS lambda using serverless Zappa framework. This can be accessed by a randomly generated link from AWS API Gateway lets say:- randomly-generated-link.aws.amazon....
Abishek's user avatar
  • 141
4 votes
1 answer
5k views

Binary body passthrough from API Gateway to Lambda

I think I've closely followed the documentation and tutorials I've found so far, but I still get this to work. I just can't convince AWS not to touch the binary data I'm posting in the body. In my app,...
Ates Goral's user avatar
3 votes
2 answers
6k views

AWS API Gateway Custom Domain: the domain you provided is already associated with an existing CloudFront distribution

I'm simply attempting to set up a Custom Domain in API Gateway. I have ACM certificate "*.mysite.com.au" that is currently being used to serve a static S3 website out via CloudFront at "beta.mysite....
Strainy's user avatar
  • 143
3 votes
1 answer
2k views

AWS ECS Fargate Target Group Failing HealthChecks

The SpringBoot application is running as an ECS Task in a ECS Service of an AWS Fargate Cluster. The ECS Service is LoadBalanced as such the Tasks spawned by the Services are automatically registered ...
Wei Minn's user avatar
3 votes
0 answers
3k views

Why AWS Cognito client secret is not "secret"

We are setting up SaaS server-to-server auth solution using AWS Cognito + API Gateway using oAuth2 Client credentials flow. And one thing is totally bugging me - I can access App client secret in ...
Lukas LT's user avatar
2 votes
2 answers
4k views

HAProxy as reverse proxy for AWS API Gateway

As the title suggest, I have an AWS API Gateway endpoint that I want to put behind HAProxy. This is my current HAProxy configuration defaults mode http log ...
Rudy Lee's user avatar
  • 165
2 votes
1 answer
3k views

Pointing google domain subdomain at an aws api-gateway API

I have a google managed domain, and a lambda based api in aws api gateway. I want to create a sub domain that points to api gateway. I created an ACM Certificate using aws certificate manager. This ...
JRogerC's user avatar
  • 123
2 votes
1 answer
10k views

How do I pass parameters into a nested stack in Amazon CloudFormation?

I'm using CloudFormation to manage an Amazon API Gateway stack, and trying to (re)use a nested stack to add an OPTIONS method to each of my HTTP endpoint methods so I can respond with CORS headers. ...
Dylan Beattie's user avatar
2 votes
1 answer
535 views

AWS - lambda versions to different gateway stages?

Coming from a "classic/standard" development I'm used to have different deployment stages, e.g. staging and production, each one with its application version. AWS Lambda functions and API ...
fudo's user avatar
  • 141
2 votes
1 answer
572 views

Different http error code and html body

We are using AWS to host our applications. Yesterday we had an issue and were by accident deleted the "Custom domain names" from the API Gateway. The issue was resolved and the services started ...
Oldfighter's user avatar
2 votes
1 answer
5k views

AWS API Gateway with Lambda and KeepAlive (persistent connections)

I'm a bit confused about Keep-Alive with AWS API Gateway. Is this something I need to configure? or maybe be careful with this setting? Because I will use API Gateway to execute Lambda functions, and ...
Enrique's user avatar
  • 143
2 votes
0 answers
114 views

Why is CloudFront failing to pass a header from the origin to the client?

I have CloudFront configured with an API Gateway origin. In the application accessed via API Gateway, my application responds to a particular request with a Content-Disposition header so that the data ...
Bill's user avatar
  • 201
2 votes
0 answers
265 views

Why is CloudFront ApiGateway CloudFront-Viewer-Country reporting US as the country for eu-west-1 distribution and viewer in UK?

I have an AWS CloudFront distribution created using CDK (CloudFrontWebDistribution) fronting an ApiGateway, deployed in eu-west-1 (Dublin). I can see in the API logs that the CloudFront-Viewer-Country ...
John's user avatar
  • 273
2 votes
0 answers
705 views

How to configure Cloudfront for API Gateway with API key enabled?

I configured two API Gateways one with API-key enabled and the other with API-key disabled. For both the API gateways I configured and enabled CloudFront. For the API-gateway which has API-key ...
Surya's user avatar
  • 263
2 votes
0 answers
3k views

Error while invoking private API in AWS

I have created a Private API in AWS API gateway using Internal Application LoadBalancer as HTTP_PROXY integration Request for GET Method. I also attached Resource Policy to this API and created ...
ajay jindal's user avatar
2 votes
1 answer
5k views

Allow other AWS services to invoke Lambda using IAM

Is it possible to grant AWS services (e.g. API gateway, Secrets Manager) permission to invoke a Lambda function using only IAM roles? Normally this is done in the function's policy (resource-based ...
mxxk's user avatar
  • 163
2 votes
0 answers
2k views

AWS CloudFront with API Gateway's Base Path Mapping for IPv6 support

We currently have some APIs set up in API Gateway, with a Custom Domain Name defined with a Regional Endpoint and Base Path Mappings that map incoming requests to the appropriate API and deployment ...
Egal's user avatar
  • 121
1 vote
1 answer
841 views

AWS Lambda as an Application Load Balancer target?

At AWS’ 2018 re:invent, AWS announced that Lambda functions can now be the target of Application Load Balancers (documentation here). I just want to ensure that I understand AWS previous offerings (e....
Dan's user avatar
  • 113
1 vote
1 answer
711 views

AWS HTTP Gateway: private integration routing without path variables

I've been setting up an HTTP gateway for the first time and came across an issue with private integrations. I want all my integrations to be private but it doesn't work well with routing. I have a ...
dmitrybelyakov's user avatar
1 vote
1 answer
214 views

How can I track user requests to my external API on AWS?

I'm a bit of a beginner but I'm working on creating an external API with AWS SAM (using API Gateway and Lambda), and I want a way to track & monitor usage. Some options I was considering: 1. Store ...
A Poor's user avatar
  • 113
1 vote
2 answers
2k views

On AWS, is it possible to have CloudFront proxy requests to API Gateway while maintaining the request's query string?

I have a CloudFront distribution configured with multiple Origins, including an API Gateway deployment. I'm trying to create a Behavior on CloudFront so that any requests received to a /api/* path ...
Carlos H Romano's user avatar
1 vote
1 answer
363 views

Offload query load from MySQL to a JSON file with expiration

I have a server installed in a fixed container with limited bandwidth and CPU. On this server, I have a website that makes a lot of requests to its database. The web app's MySQL database is only ...
Mau's user avatar
  • 113
1 vote
2 answers
1k views

Sharing AWS API Gateway resource between Terraform Workspaces?

I've seen Terraform workspaces recommended for managing different stages (staging, production). That seems to work well with most things as you generally create different resources that have the stage/...
Cristian Vrabie's user avatar
1 vote
1 answer
183 views

AWS CloudFront Wordpress Origin Issue

I facing and issue related to AWS CloudFront and my WordPress website. WP website is behind AWS CF and it utilizes a third party service, let's assume it's a verification service. Scenario is like WP ...
Dakait's user avatar
  • 115
1 vote
1 answer
1k views

DDOS AWS API Gateway protection

I have publicly exposed API Gateway (HTTP). To authenticate you have to provide a valid JWT. I want to secure this APIGW with Cloudfront + WAF. After reading docs I think that API Gateway endpoint is ...
krzysiexp's user avatar
1 vote
1 answer
178 views

Getting issue with VPC in Lambda function

I have attached VPC and private subnets in Lambda function. That is causing the connection issue with the API Gateway/other AWS services. Can anyone suggest the solution for this? Thank you.
Gayathri K's user avatar
1 vote
1 answer
338 views

Terraform aws identity_source

How can I disable the default identity_source when deploying an API Gateway Lambda authorizer using Terraform? resource "aws_api_gateway_authorizer" "authorizer" { name =...
djfdev's user avatar
  • 111
1 vote
0 answers
29 views

AWS API Gateway + Cognito + IAM

I'm working on an API for my company. I'm trying to restrict external users from accessing specific methods of a specific endpoint using IAM + Cognito. Currently I have a single Cognito user pool, ...
Devin Gardner's user avatar
1 vote
0 answers
119 views

ECS task to VPC endpoint/NAT Gateway routing

we have an ECS task that makes Rest API calls of two types: /path1 and /path2 in a Private subnet. We route the requests to Internet Gateway through a NAT gateway present in a public subnet. Flow: ECS ...
pds's user avatar
  • 11
1 vote
1 answer
819 views

What is causing BadRequestException when calling the ExecuteStatement operation on Aurora Serverless db

I have a lambda function that retrieves records from AWS Aurora Serverless db. Now I thought of adding api gateway to trigger the lambda function but I get this error Connect an AWS Lambda function ...
sji gshan's user avatar
1 vote
1 answer
539 views

How do I use AWS SAM to deploy an AWS API Gateway and AWS Java Lambda including POST caching and disabling logging

How do I deploy a lambda Java function with an API gateway REST interface including caching POST methods using AWS Serverless Application Model?
Tim's user avatar
  • 32.2k
1 vote
0 answers
93 views

Serverless Lambda infrastructure for listening to Websocket

I'm still new in the AWS Lambda & Api Gateway world, but it seems a good fit to my new project. I still have some concerns, and I'll be very happy if you can assist. In my new project (Financial ...
Francois's user avatar
1 vote
1 answer
499 views

Access private API from a domain hosted in AWS

I'm trying to make private AWS lambda call made through API gateway and I don't find the right answer on the internet, probably because I'm a beginner in AWS website management. The closest source I ...
Jean-Baptiste's user avatar
1 vote
1 answer
202 views

AWS api_gateway custom authorizer: Whats the ID of my custom authorizer?

Im implementing custom authentication using AWS api gateway and Lambda functions. In Chalice documentation, its stated that I need a authorizer_id to link the lambda function with the desired ...
Vingtoft's user avatar
  • 1,577
1 vote
0 answers
450 views

AWS API Gateway use HTTP instead of HTTPS

I have an IoT device that is posting data to an AWS API Gateway. The device can not currently use HTTPS. Is there any way that I can get the API gateway to accept a standard HTTP POST request?
Reid's user avatar
  • 411
0 votes
2 answers
873 views

dig +trace: no servers could be reached for my domain?

I am building my app in AWS. I have deployed my Reactjs frontend project in an EC2 instance. Instead of users from the external internet world visiting my EC2 instance directly, I want to put it ...
Kid_Learning_C's user avatar
0 votes
1 answer
291 views

AWS: Protecting access to specific ports on an EC2 instance

I have an EC2 instance running an application which provides APIs on port 1000 and 2000. The EC2 instance should be allowed all outgoing traffic as well as any incoming traffic to port 1000. ...
Bobface's user avatar
  • 125
0 votes
2 answers
469 views

Strange requests keep coming to my gateway API on AWS

I have a simple HTTP service built with AWS lambda and API gateway. The Domain pointing to the gateway is hosted by Route53 and the gateway uses certificate from Certificate Manager. It's absolutely ...
glowka's user avatar
  • 111
0 votes
1 answer
307 views

Possible to create an AWS API Gateway to Route all requests to Classic Load Balancer?

I have a questions (hopefully not dumb). I am the IT guy of a business hosting various applications with AWS and we currently have a Classic Load Balancer sitting in front of 2 to 3 EC2 instances ...
realnsleo's user avatar
  • 117
0 votes
1 answer
471 views

How to debug AWS API Getway "Internal message error"?

I have created an API Gateway linked to a (tested and working) Lambda function. I get a {"message":"Internal Server Error"} when I try to access to it, but I have no logs about it,...
GlinesMome's user avatar
0 votes
1 answer
9k views

How to solve python POST response 405 [closed]

How to solve python POST response 405? import requests import json from requests.auth import HTTPBasicAuth myHeaders = { 'accept': 'application/json', 'content-type': 'application/json', 'X-Killbill-...
Sukhen Santra's user avatar
0 votes
1 answer
199 views

API Gateway and VPC access lists

My understanding is that controlling IP address access to AWS api-gateway is via Resource policies. This does not sound ideal as it would involve deploying the API each time new access was required ...
nipy's user avatar
  • 107
0 votes
1 answer
368 views

AWS API Gateway in China

We are planning to launch an app that will be available globally, including China and we plan to use AWS for this. However, because of the "Great Firewall of China" we may run into problems: The app ...
aljo f's user avatar
  • 103
0 votes
1 answer
79 views

Unable to authorize Amazon API Gateway using API Key

As per amazon's documentation (https://docs.aws.amazon.com/apigateway/latest/developerguide/api-gateway-setup-api-key-with-console.html) I am supposed to see a dropdown near API KEY. Although I have ...
Surya's user avatar
  • 263