I have two sides.
In one side I have direct usage of WebSocket protocol by using libraries/packages like ws (a Node.js WebSocket library) or Socket.io. Here I can use test tools to subscribe against and address starting with ws
or wss
like ws://localhost:8080
and receive updates.
In other side, I use GraphQL Subscription by using components like ApolloGraphQL
. It seems that this way I should use something embedded in GraphQL. Projects developed with this way can not be accessed via ws://
or wss://
addresses, or at least I am not aware of.
My questions is what are differences between two? Are GraphQL Subscription is built on top of WebSocket? If yes, how? How can I access a GraphQL Subscription via ws://
or wss://
urls?
UPDATE: I have read this and this question before, but they did not helped a lot.