-
Notifications
You must be signed in to change notification settings - Fork 361
Request path includes API gateway stage twice #668
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Are you using APIGW Rest or HTTP? I wonder if APIGW started sending the stage in the path. Can you print the content of |
HTTP. |
|
Background
I have an API gateway hooked up to a lambda - I don't have any parameter mappings & I'm not using a custom domain. The lambda uses
lambda_http
together withaxum
. The API gateway has a stage calledProd
, the invoke URL is along the lines of:https://blablabla.execute-api.ap-southeast-2.amazonaws.com/Prod
Current outcome
When performing a request such as
POST https://blablabla.execute-api.ap-southeast-2.amazonaws.com/Prod/auth/login
,lambda_http
rewrites the request path to/Prod/Prod/auth/login
.Expected outcome
I would expect the request path to be
/Prod/auth/login
.Other information
While there is a workaround (rewrite the path in middleware), the underlying behavior of including the stage twice is very surprising to me - is is possible I've misconfigured something?
Related discussion in #107 and #450.
The text was updated successfully, but these errors were encountered: