Debugging a function returns 502

@DavidWells I’m experiencing the same thing. In my case, I’m proxying a request to an image service that requires authentication. So, my lambda function passes on the image request and attaches additional authentication headers, then proxies the image response directly back to the browser.

This works fine on localhost using netlify-lambda, but I’m getting the exact same error when using Netlify: error decoding lambda response: json: cannot unmarshal object into Go struct field lambdaInvokeResponse.body of type string

I suppose I can convert the image to base64 and deliver it that way, but that’s obviously not at all ideal. Can this please be fixed?