How to POST a BizTalk message to a web api POST method in from BizTalk 2016. RRS feed

  • Question

  • I am trying to interact with a web API service from a BizTalk server 2016. I was successfully able to his the get request with or without parameters.I am also able to hit the POST method which is having a class object as parameter. But, the class object is always null and it did not get populated. my biztalk message resembles the class object in the POST method. I refered lot of articles in the net. But, did not get the object populated.
    Friday, September 8, 2017 6:56 AM

All replies

  • Hi,

    So how have you verified the message ,what you are sending to the web api .?

    Enable the tracking on the orchestration,send pipeline and send port and track the message instance  . The Web API will be expecting JSON as xml as input ,you so need to use correct pipeline component as well while sending the request and receiving the response

    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply

    Friday, September 8, 2017 8:32 AM
  • Hi abhishek,

    thanks for your response. this is the request message I am passing to the API service.








    my send port configuratin and service code looks like this. Do I need to develop any custom pipeline or any other configuration required.

    Friday, September 8, 2017 9:40 AM
  • What exactly do you mean by 'class object'?

    The thing is, if you're using a typed protocol, like SOAP/WCF, it's more than just a POST.  There has to be some layer that does the serialization/deserialization which you've not mentioned.

    Friday, September 8, 2017 11:44 AM
  • I have achived it in the following way. But not sure is this the right way. if any better way of doing will be useful.I have changed my web API post method slightly like this to get it done.
    Wednesday, September 20, 2017 8:48 AM