cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
KarmaPoliceT2
Level: Powered On

Parse headers returned from http action?

I have an HTTP request which processes just fine and gets back a body, headers, and response code value... however I would like to get the value of a specific header key (the value in the "location" key in my case) for use in a subsequent flow action... 

 

Is this possible? I see the Headers response object, but i have no idea how to parse that to just get the value i am looking for... 

 

Thanks


Accepted Solutions
Community Support Team Rank
Community Support Team

Re: Parse headers returned from http action?

Hi @KarmaPoliceT2,

 

Could you please share a screenshot of your flow's configuration?

Further, could you please share a bit more about your Headers response object?

I have made a test on my side and the flow works well. Please take a try with the following workaround:

 

14.JPG

The flow works successfully as below:

 15.JPG

In your scenario, please type the following expression:

outputs('HTTP')['headers']?['location']

 

Best regards,

Kris 


All Replies
Community Support Team Rank
Community Support Team

Re: Parse headers returned from http action?

Hi @KarmaPoliceT2,

 

Could you please share a screenshot of your flow's configuration?

Further, could you please share a bit more about your Headers response object?

I have made a test on my side and the flow works well. Please take a try with the following workaround:

 

14.JPG

The flow works successfully as below:

 15.JPG

In your scenario, please type the following expression:

outputs('HTTP')['headers']?['location']

 

Best regards,

Kris 

KarmaPoliceT2
Level: Powered On

Re: Parse headers returned from http action?

This worked wonderfully... i wasn't aware of the outputs expression's '?' variable parsing capabilities... thanks!

Racca
Level: Powered On

Re: Parse headers returned from http action?

Is it possibile get the "Request header"?
This is the response header.
Thanks

>