An API Gateway Lambda proxy integration returns a Python object directly, and clients receive a malformed-response error. Which response change should the developer make?

Published
  1. Return any object shape and change only the function log level.
  2. Set an S3 object metadata field to the HTTP status code.
  3. Return the integration required response envelope with statusCode, headers as needed, and a correctly serialized body.
  4. Remove the response body and assume every API operation should return HTTP 200.

Comments — 0