Honest statement: the ws module exposes NO REST endpoints. It is a socket
contract only. General API conventions live in 00-shared/07; this file maps the
socket contract 1:1 to source, and marks every gap explicitly.
No HTTP endpoints. The module consists of gateway + bridge only (ws.module.ts:6-9). Auth is via JWT on the socket handshake, not via any REST call of this module.
tenant:{tenantId} room — all connected sockets of the tenant
ws-bridge.service.ts:16-22; ws.gateway.ts:76-78
Details:
The bridge relays everyEventBus event (events/event-bus.service.ts:11-14) for
the event's tenant — there is no server-side allow-list of event types.
The envelope is a subset of DomainEvent (events/domain-event.interface.ts:1-8):
actorId and correlationId are dropped by the bridge (ws-bridge.service.ts:17-21) — gap G3.
broadcastToRoom(room, event, data) exists (ws.gateway.ts:80-82) and is used for
ad-hoc room fan-out, but nothing in source calls it today.
Sensitive notifications must define user:{id} convention + RBAC
G5
No Redis pub/sub adapter for sockets
src/infrastructure/redis/ has only REDIS_CLIENT (redis.constants.ts:1-2, redis.module.ts:12-27); no socket.io adapter in src
Multi-instance deployments will fan out only within one process; add socket.io Redis adapter when scaling (plan flags 10k-connection risk, IMPLEMENTATION_PLAN.md:842)
G6
No heartbeat tuning in source
gateway sets no pingInterval/pingTimeout
Relies on socket.io defaults (25 s / 20 s); tune for proxy timeouts
G7
No server-side event allow-list / per-event subscription
No versioning (no REST). Event names follow dot-notation and are additive; clients
must ignore unknown eventTypes (06 §6).
Error signalling is connection-level only (disconnect on auth failure,
ws.gateway.ts:54-56). No application error channel — add one for G-series fixes.