I have an API with 3 environments/stages in my AWS API Gateway (lets call them dev, staging and prod), setted up with a custom authorizer each, and in one of my GET methods I am receiving an inconsistent response from AWS when the authorization token is not valid. For staging and prod I am receiving
{
"Message": "User is not authorized to access this resource with an explicit deny"
}
But for dev I am getting (with the lowercase 'm').
{
"message": "User is not authorized to access this resource with an explicit deny"
}
This is breaking the test suite for dev so it must be fixed. Rolling back to previous deployments make it work correctly, but we didn't change anything for that method (on purpose at least).
Why could this happen?
Thank you in advance
We found the solution, so for anybody interested: the Gateway Responses were returning "message" in lowercase for all responses, probably the "Message" one was hardcoded in the past for any reason and something resetted the values recently. Editing it again did the work.