krakend-ce icon indicating copy to clipboard operation
krakend-ce copied to clipboard

Unable to get headers and statuscode using the examples

Open Zeychiel opened this issue 7 months ago • 1 comments

Environment info:

  • KrakenD version: 2.5.0
  • System info: docker
  • Backend technology: Go

Describe what are you trying to do: I try to catch 201 responses from the backend to add a dedicated header ; using a response modifier but .Headers() and .StatusCode() on input.(ResponseWrapper) are nil ; .Data() on the other hand does as expected

This issue: https://github.com/krakend/krakend-ce/issues/488#issuecomment-1157921730 says that this is by design ; but this example from the documentation: https://www.krakend.io/docs/extending/plugin-modifiers/#building-the-plugin image says otherwise.

Is the documentation outdated and it is by design that the values are empty when NOT using no-op ?

Thanks,

Zeychiel avatar Jan 18 '24 09:01 Zeychiel

Hi @Zeychiel you're right that's by design and yes the documentation is wrong. Best regards.

nsitbon avatar Mar 28 '24 08:03 nsitbon