Description
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 with axum
. The API gateway has a stage called Prod
, 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?