2 Answers
- Newest
- Most votes
- Most comments
0
That looks fine to me unless you've enabled multi-value headers in which case the response structure is different. Can you provide more information such as logging output from your Lambda containing the request and the response logged just before "return response"?
0
So, I just had this issue, and since an AWS engineer helped me resolve it, I figure I post the answer here too.
All your headers have to have a string value. Returning a number, or something other than a string in the header, guarantees you a 502 and InvalidResponseError. I don't think this is mentioned anywhere in the AWS documentation.
answered 9 months ago
Relevant content
- asked 2 years ago
- asked 6 months ago
- AWS OFFICIALUpdated 10 months ago
- AWS OFFICIALUpdated 21 hours ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago
What language is that you're using?
I am using nodejs (javascript)