The celerity/channel resource defines a real-time channel for pub/sub messaging, presence tracking, and targeted broadcasting over a WebSocket API. It is an opt-in layer; if no celerity/channel resources are linked to a celerity/api (with protocol: websocket), the channel protocol routes are not registered and there is zero runtime overhead.
Key capabilities include:
- Real-time pub/sub: Deliver messages to all subscribers without manual connection tracking.
- Presence tracking: Broadcast join/leave events for channel members.
- Per-channel auth: Define specific auth guards or subscribe handlers for fine-grained access control.
- Rate limiting: Protect against message amplification via per-channel limits.
- Secure by default: Only declared channels accept subscriptions.
- Reconnection recovery: Automatic restoration of client subscriptions after reconnection.