Answer the question
In order to leave comments, you need to log in
Messenger API, REST + WS or pure WebSocket?
The essence of the issue is this, I decided to download the messenger for the sake of interest, several technological issues immediately arose.
One of them is how to build an API?
Is it worth mixing REST for state management (by type, change user data, authorization, get profile data, etc.) and WebSocket for communication, of course.
Or is it worth doing everything on sockets at once?
Answer the question
In order to leave comments, you need to log in
You can combine, you can not combine. You can generally chat through long-polling
Just pure WebSocket with its additional point-to-point traffic encryption inside the WSS pipe. All service traffic (login/logout, states, etc.) is in the same place.
So that you can use messaging both on the web and in any native applications for different operating systems.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question