Calling a web service from an ASP.NET WebAPI application

I have a third-party web service to call from an ASP.NET Web API application. This third party service is not svc or asmx. And all I gave is 2 WSDL for TEST and PROD environments.

https://test.xyz.com/XYZEventService?wsdl

https://xyz.com/XYZEventService?wsdl

Now I plan to add the class library to the web API application and get the links to the services for these services generated using svcutil.exe.

But how can I distinguish between TEST and PROD? Or in an ideal situation, one proxy will work for both?

My question is about the best way to configure and use multiple third-party web services within a single web API application.

+4
source share
1

, - .

TEST, web.config. web.config , URL- TEST.

, web.Release.config, , PROD.

Debug TEST, URL- , Release PROD.

, web.config.

0

Source: https://habr.com/ru/post/1524794/


All Articles