packages/shared/src/protocol.ts and packages/shared/src/e2ee.ts, and describes frame shape only.
For what an implementation is required to do — lifecycle, ordering, error obligations, idempotency, and which behaviors are a deployment’s choice rather than the protocol’s — see the normative protocol specification. Where the two disagree about shape, the schemas win.
Caller to relay
call_request
Send an encrypted call payload.
Relay to caller
call_status
Report unauthenticated lifecycle metadata.
call_queued
Acknowledge a durable submission. A receipt, not a reply.
call_error
Return an unauthenticated relay-operational error.
call_outcome
Return an encrypted, authenticated peer outcome.
Relay to listener
incoming_call
Deliver an encrypted call with relay-attested routing metadata.
cancel_call
Request cancellation.
Listener to relay
call_accepted
Confirm ownership of queued work.
call_started
Confirm the answering process started.
call_outcome
Return an encrypted, authenticated peer outcome.
call_rejected
Reject an invalid encrypted request.
call_cancelled
Confirm cancellation completed.
call_not_cancelled
Explain why cancellation did not complete.
Important bounds
- Messages are limited to 64,000 bytes; replies to 256,000 bytes.
- Conversation contexts expire after 30 minutes and allow at most 10 turns.
- Each caller has a 30-call hourly budget.
- An encrypted WebSocket frame is limited to 2,063,019 bytes.
- Optional W3C trace context is normalized and must match the correlation ID.