Processing Upstream Responses
Let's take a look at how responses from upstream systems provided by request
/requests
or proxy-request
actions can be processed further.
The body
function provides you with the raw body of an HTTP response. For further processing, it may be necessary to parse the body using functions like json-parse
or xml-parse
:
The $upstream
variable gives additional information about upstream responses like the HTTP status and the headers. The following recursive sub-flow demonstrates a general way how to follow a redirect:
request.xml:
To just pass the upstream response downstream you can use the pass-body
action:
Last updated