I was just wondering are asmx files compatible with REST style requests?
I have some asmx files which need to service some third-party programs which are setup to send REST requests, not SOAP.
Yes, you can use ASMX in .
5) The purpose of ASMX services is to send and receive data using SOAP over HTTP protocol. However, WCF services can send and receive data using any format over different protocols like HTTP, HTTPS, TCP, MSMQ etc.
When web developers talk about . asmx, they know that it is something not too complicated – it can be configured easily. The downside is, it is only callable from HTTP, while . svc is used with HTTP, MSMQ, and can be hosted through different platforms such as the Winforms application.
ASMX provides the ability to build web services that send messages using the Simple Object Access Protocol (SOAP). SOAP is a platform-independent and language-independent protocol for building and accessing web services.
First of all, you should not be using ASMX for new service development: you should use WCF instead. It's much easier with WCF to have the same service handle both SOAP and REST-style endpoints.
The closest that an ASMX service will get to REST is that it can be configured to permit a GET or POST request, in which case it will return plain XML, with no SOAP envelope.
See Configuration Options.
But if you're trying to get "true REST" from ASMX, then you're out of luck.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With