As an enhancement, APISIX could return more telling error message to help users troubleshooting.
For example, with AWS CLI aws sts get-caller-identity, wrong secret key would lead to the following error msg:
The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.
Wrong access key would lead to the following error msg:
The security token included in the request is invalid.
Current State
The
aws-lambda
plugin returns400 Bad Request
for wrong IAM credentials (wrong access key or secret key), or wrong URL.For example, if the URL is missing the ending slash, APISIX will return
400 Bad Request
without further information.The error log is the following and it is not very informative:
Desired State
As an enhancement, APISIX could return more telling error message to help users troubleshooting.
For example, with AWS CLI
aws sts get-caller-identity
, wrong secret key would lead to the following error msg:Wrong access key would lead to the following error msg:
Environment
APISIX version (run
apisix version
): 3.9.0