First of all, RESTful is a stateless and unified interface norm that can be applied to web services. It should not be automatically and only a simple old CRUD service supported by the database.
In the real world, we can hardly say that all web-REST APIs are fully consistent with the norm, in fact they are not in most cases, especially in the stateless part.
For your message-based API, especially if it is bidirectional and event-based, you can use web ports and consider the REST API to expose a single, stateless web interface to create them. And yes, you can use websockets with ASP.NET WebApi there is a lot of tutorial there, even for the new ASP.NET kernel.
Part of the interaction between the services is no different from a regular web browser <=> web service, you just use C # code instead of JS for the client.
I can hardly recommend a WCF that uses SOAP, as it is hardly portable with web standards these days. For example, if you want to use the browser client instead of another ASP.NET service, you will need to make an additional client part of the code to handle the supported functions.
You can use WCF websites , providing almost all the benefits of WCF SOAP.
tl; dr:
- You can mix RESTful and Websockets, it can be better than full REST or full websites.
- Itβs a personal preference to use SOAP over websites, but it has a potential technical debt, considering what you want to do later
- The message API between services is not different from the message API between service and browser
source share