Quantcast
Channel: WCF, ASMX and other Web Services
Viewing all articles
Browse latest Browse all 555

Connecting to SOAP API using C#

$
0
0

I am trying to implement a client to access an api at https://vendor-ctrip.fws.ctripqa.com/Hotel/OTAReceive/HotelStaticInfoService.asmx.

However I do not know how to pass credentials and other parameters to the webservice.

I have managed to setup a console application using c# and have added the service as a connected service.

// endpoint
HotelStaticInfoServiceSoapClient.EndpointConfiguration endpoint = new HotelStaticInfoServiceSoapClient.EndpointConfiguration();
// client
HotelStaticInfoServiceSoapClient client = new HotelStaticInfoServiceSoapClient(endpoint);
// request
OTA_HotelDescriptiveContentNotifRQ dreq = new OTA_HotelDescriptiveContentNotifRQ();
//response
HotelDescriptiveContentNotifResponse dres = await client.HotelDescriptiveContentNotifAsync(dreq);

Could anyone please direct me in the right direction.

Viewing all articles
Browse latest Browse all 555

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>