After upgrading to WebSocket, the first frame must include:
{ "clientId": "your-id", "action": "subscribe", "topic": "updates", "apiToken": "your-token" }
Note: The apiToken field is optional. If omitted, it defaults to "default".
The server automatically scopes all topics by apiToken. Clients use clean topic names like "updates", "all", or "notifications". Internally, the server ensures complete isolation between different apiTokensāpreventing any data leakage across applications.
Example: Two clients with different apiTokens can both subscribe to "updates", but they will only see messages from clients sharing their same apiToken.