WebSocket Example

To make this client works properly start the Regoch Websocket Server. Open your browser's Developer Tools » Console.

Connection Test



Message Properties

{id:string, from:string, to:string|string[], cmd:string, payload?:any}

Questions






Send message



- send to all but not the sender
- send to all clients
- send same message consecutive 100x to one receiver

Room

room:

message:

Server Commands

nickname:
route:


Incoming Messages



Message format examples:



Test on, once, off, offAll

1. Start the messages which will be send every one second ---
2. Open this page in another tab and test on, once, off, offAll by clicking the buttons down.
- will start to receive the messages
- will receive only one message
- will turn of receiving the messages
- will turn of receiving the all messages
message: