0

I have a simple AWS implementation using API Gateway, Lambda & DynamoDB. I noticed that AWS API Gateway allows multiple stages. After reading a bit of the docs and playing around with the configuration, it's not obvious to me how I would be able to create new endpoint which could point to a new lambda function.

My current endpoint is something like:

https://xxx.execute-api.us-east-1.amazonaws.com/prod/my-mymethod

I am looking to create something like:

https://xxx.execute-api.us-east-1.amazonaws.com/stage/my-mymethod

which would point to an independent Lambda function.

How exactly can this be done?

1 Answer 1

1

http://docs.aws.amazon.com/apigateway/latest/developerguide/integrating-api-with-aws-services-lambda.html

It would be the same steps you took to create the prod one.

You'd definitely use two lambda functions as because it's modular your changes to your original Lambda will be reflected on both.

1.Create Lambda Function
2.Create API in API Gateway
 2a Create New, 
 2b Click Actions > Create Method > Choose HTTP Method
 2c Whilst HTTP Method is highlighted set "Integration type" to Lambda Function
 2d Choose Lambda Region where your Lambda Function exists
 2e Intellisense will help you fill in the name...
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.