Search code examples
c#wcfasp.net-web-apiasp.net-web-api-routing

Accept WCF request in WebAPI


I need to enable my webAPI REST service to accept a request in the format of:

www.someURL.com/OldService.svc

I am working on an existing application that used to use WCF. These methods do not have to return anything but a 200 response. We need the REST service to handle this call so we can retire the old WCF service, but systems will fail if we don't support this WCF request.

Has anybody done this before?

edit:

Is it possible to do this with just adding a new route?


Solution

  • You can add a WCF service (.svc) to a Web API project by simply adding a New Item and selecting Web, it will then show up in the list as WCF Service.