Where you are: docs → reference → api → comms Read this first: api.md See also: subsystems/comms.md · api/operator.md
TL;DR Four endpoints manage operator voice comms: join, leave, set mute, get status. Audio itself flows over WebTransport bidirectional streams, not REST — see subsystems/comms.md for the full protocol.
Purpose: join the voice comms channel.
Handler: control/api_comms.go → (*API).handleCommsJoin.
Request body (control.commsJoinRequest): { "operatorId": "op-1", "name": "Alice" }.
Response 200: full ControlRoomState.
Errors: 400 (missing operatorId/name), 409 (comms.ErrCommsFull), 501 (comms disabled), 503 (comms.ErrOpusUnavailable).
Handler: (*API).handleCommsLeave.
Request body (control.commsLeaveRequest): { "operatorId": "op-1" }.
Purpose: mute / unmute a participant (self or someone else depending on role).
Handler: (*API).handleCommsMute.
Request body (control.commsMuteRequest): { "operatorId": "op-1", "muted": true }.
Errors: 404 (comms.ErrNotInComms).
Handler: (*API).handleCommsStatus. Response 200: internal.CommsState.
- Reference: api.md · state-broadcast.md · api/operator.md
- Subsystems: comms.md