Monday 15 April 2013

Change Soap Request Header from text/xml to soap/xml for asmx webservice in C# -



Change Soap Request Header from text/xml to soap/xml for asmx webservice in C# -

i need phone call webservice. generated proxy , invoked method. keeps failing. because api expecting soap/xml in header whereas proxy client generated in visual studio sending text/xml in header.

question: possible alter value of content-type header generated proxy client?

wcf - content type text/xml; charset=utf-8 not supported service

this mismatch in client/server bindings, message version in service uses soap 1.2 (which expects application/soap+xml) , version in client uses soap 1.1 (which sends text/xml). wshttpbinding uses soap 1.2, basichttpbinding uses soap 1.1.

it seems wshttpbinding on 1 side , basichttpbinding on other.

you can alter configuration on client side wshttpbinding uses soap 1.2 , impact content type header.

c# xml web-services soap

No comments:

Post a Comment