Extract service callout response content with http status code 302

Hi.
I am using service callout policy inside of a proxy to make call to a target endpoint. Service callout policy returns response with http status code 302. How to access the response variable content in ExtractVariables or JavaScript policy? I am unable to access the variable.

0 2 202
2 REPLIES 2

HTTP 302 is indicating the request invoker to send the request to the URI thats in the response Location header. 

You can access the response content and headers as described in docs. Either find the correct ServiceCallout target and use that in your Apigee proxy OR extract the Location value from the ServiceCallout response and make subsequent calls to the target identified (not an ideal solution).

Thanks. 

I am using service callout to simulate callback request. But the service callout is returning another callback with http status code 302.