While building that I realized WebSockets unlock a lot more in WordPress than just RTC. Any `add_action` hook can now push a realtime `CustomEvent` to connected browsers without polling or a custom server.
The stack:
- Relay server: Rust (Axum/Tokio), WebSocket-first with SSE fallback
- Event payloads: AES-256-GCM encrypted before leaving WordPress, the relay only ever sees ciphertext
- Publish auth: HMAC-SHA256 signed requests
- Browser connections: short-lived scoped JWTs (5 min, auto-refresh)
- WordPress plugin: open source (GPL-2.0), hosted relay is WPSignal
GitHub - https://github.com/wpsignal/wordsocket/
A few use cases we've seen: live WooCommerce order updates, breaking news flags, realtime comment counts, and collaborative editing via WP 7.0 RTC. Curious what else people would build with a realtime event bus wired into WordPress action hooks?