awsdocs/aws-lambda-developer-guide

urls-invocation - status code 201 -> 502 error

phillclark opened this issue · 1 comments

https://github.com/awsdocs/aws-lambda-developer-guide/blob/main/doc_source/urls-invocation.md

The documemtation here and on the AWS site (https://docs.aws.amazon.com/lambda/latest/dg/urls-invocation.html) shows the ability to use custom statusCode responeses (eg. 201 in the docs) but if you supply anything other than a 200 value from the returned Lambda function, the Function URL response will be a 502 "Internal Server Error".

Ideally, the processing code for the Function URL will accept any status code but failing that the documentation should be adjusted.

Hi Phill, can you share the function code that you are using to test?