none
How to handle the http header values in biztalk RRS feed

  • Question

  • Hello,

    We have  the json request and json response maintained in our biztalk application . Biztalk server 2010. have used http adapter at the receive port.

    previously we dint have any headers values in both request and response.

    now the new requirement is  the client will  pass  3 new parameters  from the http header . and based on some conditions we have to send back the same parameters in response header with json response.

    How can we access the header values in orchestration and how to return back the header values with response in orchestration.


    Thanks ,

    Rajeshwari M.L 


    Tuesday, September 6, 2016 11:05 AM

Answers

  • Hi rajeshwari,

    Are you using BizTalk 2010 and Http adapter?

    If you are using Http adapter then you can set the custom http header in orchestration sth like.

    MSG_RESP_OUT(HTTP.UserHttpHeaders) = "userName: ABHI password: welcome";

    AND to read the http header in orchestration,

    StrVar = MSG_IN(Http.InboundHttpHeaders); 


    Manish



    • Edited by Manish kumar Tuesday, September 6, 2016 11:40 AM
    • Marked as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    Tuesday, September 6, 2016 11:20 AM
  • Hi,

    Apart from what Manish said, you can as well use BRE Pipeline Framework to achieve this (Especially inmessaging only solution scenarios)

    Please read the section HTTP header Manipulation section in the following article:

    https://adventuresinsidethemessagebox.wordpress.com/2015/06/28/bre-pipeline-framework-v1-6-0-now-published-on-codeplex-new-feature-breakdown/


    Regards Pushpendra Singh : Please mark the reply as answer or vote it up, as deemed fit.


    • Edited by Pushpendra K Singh Tuesday, September 6, 2016 12:54 PM
    • Proposed as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    • Marked as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    Tuesday, September 6, 2016 12:52 PM

All replies

  • Hi rajeshwari,

    Are you using BizTalk 2010 and Http adapter?

    If you are using Http adapter then you can set the custom http header in orchestration sth like.

    MSG_RESP_OUT(HTTP.UserHttpHeaders) = "userName: ABHI password: welcome";

    AND to read the http header in orchestration,

    StrVar = MSG_IN(Http.InboundHttpHeaders); 


    Manish



    • Edited by Manish kumar Tuesday, September 6, 2016 11:40 AM
    • Marked as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    Tuesday, September 6, 2016 11:20 AM
  • Hi,

    Apart from what Manish said, you can as well use BRE Pipeline Framework to achieve this (Especially inmessaging only solution scenarios)

    Please read the section HTTP header Manipulation section in the following article:

    https://adventuresinsidethemessagebox.wordpress.com/2015/06/28/bre-pipeline-framework-v1-6-0-now-published-on-codeplex-new-feature-breakdown/


    Regards Pushpendra Singh : Please mark the reply as answer or vote it up, as deemed fit.


    • Edited by Pushpendra K Singh Tuesday, September 6, 2016 12:54 PM
    • Proposed as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    • Marked as answer by Angie Xu Friday, October 7, 2016 2:42 AM
    Tuesday, September 6, 2016 12:52 PM
  • Hi,

    A small note on top of this,

    Though HTTP does not define any limit. However most web servers do limit size of headers they accept. For example in Apache default limit is 8KB, in IIS it's 16K. Server will return "413 Entity Too Large" error if headers size exceeds that limit.

    So better to keep the size within limits of Servers where your application is hosted for HTTP Headers.

    Hope this Helps!!!!

    Please Mark as Answered if You Satisfy with Reply.

    • Proposed as answer by vikas.a.mehta Wednesday, September 7, 2016 4:46 AM
    Wednesday, September 7, 2016 4:46 AM