Socket.IO
Socket.IO isn’t plain WebSocket — it has its own framing, namespacing, ack callbacks, and the option to fall back to long-polling. Restura speaks the protocol natively.
What works
Section titled “What works”- Connect to any Socket.IO server, with or without namespacing (
/admin, etc.). - Auth payload on connect — sent in the
authfield of the handshake. - Emit events — pick an event name, send a JSON / string / number payload.
- Listen — subscribe to event names; live messages stream into the transcript.
- Acks desktop only — the callback-based response pattern needs the desktop transport.
- Reconnect — on/off, with backoff settings.
Why ack is desktop-only
Section titled “Why ack is desktop-only”Socket.IO acks require a long-lived stateful association between the client emit and the server response that survives the request boundary. The web app routes Socket.IO through the Worker, which doesn’t preserve that ack-callback handle across the proxy. Desktop opens the socket directly in the Electron main process and gets the ack callback natively.
- If you only need fire-and-forget emits and broadcast listening, the web app is fine.
- If your test relies on
socket.emit('event', payload, (response) => ...), use the desktop app.