Events
Every event type, with its direction, class, stream and payload.
167 event types. Where more than one document describes an event, the entry shows the owning document's description and links the others.
00 Overview, architecture and conventions
call.epoch_ready
Each call participant posts it after installing a new epoch's media keys. Owned by 15.
mls.epoch_ack
Devices post it after processing each commit (used for media switching and log cleanup). Transport not stated in 00. Owned by 13.
02 Discovery, server metadata and server keys
discovery.metadata_changed
Tells clients to refetch the server's ServerMetadata now (bypassing cache, after 0–30 s jitter, 0–5 s when urgent); payload is only a trigger. Sent within 60 s of a non-cosmetic change (10 s when urgent) to every WebSocket session open on the server, local or remote.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
canonicalDomain | string | Yes | The server whose metadata changed. |
updatedAt | timestamp | Yes | The new updatedAt. |
changes | array<MetadataChange> | Yes | Which parts changed. any of keys, domains, endpoints, auth, limits, features, versions, secure, other; unknown values treated as other |
urgent | boolean | Yes | True when a key was revoked (§11.7). |
discovery.peer_resumed
A federation pin left suspended.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
domain | string | Yes | The domain. |
how | ResumeHow | Yes | How the suspension ended. auto | evidence | admin; unknown treated as auto |
baseUrl | string | Yes | Base URL (the spec gives only its type, string). |
discovery.peer_suspended
A federation pin entered suspended; payload is the PeerPin. Ordinary users never receive it.
03 Client transport, envelopes and errors
error
WebSocket error: envelope with t "error", the problem object in d, re when answering a client message, no ctx or seq. An error that ends the connection is followed by session.closing and a close code.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(problem object members) | ProblemObject | Yes | The problem object (§10.1) is d itself. status = HTTP status of the same condition, or §10.6 status for session.* codes |
Also described in 00 §7.4.
session.closing
Sent by the server before closing a socket on purpose; the server then closes within 1 s.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
reason | ClosingReason | Yes | Why the socket is closing. unknown value: follow reconnect and retryAfterMs |
reconnect | boolean | Yes | Whether the client should reconnect automatically. |
retryAfterMs | integer | No | Minimum delay before reconnecting. ms |
problem | ProblemObject | No | Problem object explaining the close. for session_ended, unauthenticated, unsupported_version and rate_limited |
session.heads
Latest positions of heads-level streams for unread indicators. Control message, coalescable; one right after session.ready/session.subscribed covering new heads subscriptions, then at most one per socket every 2 s listing only changed streams.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
heads | object<ctx-ref, Head> | Yes | Map from context reference to a Head object. keys are context references |
session.hello
First message on every socket: authenticates the socket and sets up subscriptions in one round trip. Reply: session.ready or error.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
token | string | Yes | Client-session access token or, at the bot's home server only, a bot token. Server recognizes the kind from the token itself (bot tokens carry svb_ prefix, 05); no scheme member. §3.1 credential syntax, at most 4,096 characters; never an S2S token |
client | string | Yes | Product and version, e.g. sloppyvoice-desktop/1.0.3. Diagnostics only. 1 to 128 printable ASCII characters |
protocol | string | No | Protocol version the client implements. version grammar major.minor (§12.1); default "1.0" |
features | array<string> | Yes | Features the client supports (§12.2). at most 64 entries; MAY be empty; unknown names ignored |
resume | object<stream, integer> | No | Map stream name -> client position; each entry asks for a full subscription replaying everything after that position. Position 0 asks for the stream from its start. positions integer >= 0 |
subscribe | array<string> | No | Streams to subscribe at level full from their current head, no replay. stream names |
heads | array<string> | No | Context references to subscribe at level heads (§5.7). context references only (community refused with core.invalid_request; me ignored) |
foreground | boolean | No | Initial foreground state (§5.8). A client with a visible UI MUST send true when visible. default false |
Also described in 00 §7.4.
session.ping
Server heartbeat every 30 s (pingIntervalMs) on every ready socket, up to 1 s jitter. Client answers at once with session.pong (re = ping id).
session.pong
Client's answer to the server's session.ping, re = ping id, d {}. Never counts toward the socket rate limit.
Also described in 03 §5.9.
session.ready
Reply to a successful session.hello (re = hello id). Followed per stream by session.resync_required if needed, replays, then live events.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
conn | uuidv7 | Yes | Identifies this connection, for diagnostics and support. |
account | string | Yes | The session's account. canonical address (01) |
did | string | Yes | The session's device ID. did grammar (§8.4) |
server | string | Yes | The server's canonical domain. canonical domain |
protocol | string | Yes | Highest protocol version of the client's major version that the server implements. major.minor |
features | array<string> | Yes | Effective feature set: intersection of server metadata features and hello features. |
pingIntervalMs | integer | Yes | Server ping interval (§5.9). 30000 in this version |
idleTimeoutMs | integer | Yes | Idle timeout (§5.9). 75000 in this version |
authExpiresAt | timestamp|null | Yes | The socket's authentication deadline (when the hello token expires); null for a non-expiring token such as a bot token without expiresAt. |
subscriptions | array<SubscriptionResult> | Yes | Subscription results (§5.6). one per stream named in the hello, plus me |
session.reauth
Extends the socket's authentication deadline in-band without reconnecting. Counts toward the socket rate limit. Reply: session.reauthed or error.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
token | string | Yes | Typically the access token a silent refresh (05) or remote-session renewal (06) just produced. §3.1 syntax; a currently valid token of the same client session |
session.reauthed
Answer to an accepted session.reauth (re set) with the new deadline.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
authExpiresAt | timestamp|null | Yes | New authentication deadline; null for a non-expiring token. |
session.resync_required
The server can't bring a stream up to date by replay; client refetches state over HTTP. MAY be sent at any time.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
stream | string | Yes | The stream. stream name |
reason | ResyncReason | Yes | Why replay is impossible. unknown value treated like gap_too_large |
headSeq | integer | Yes | Stream head when sent; live events continue from headSeq + 1. |
Also described in 00 §7.4.
session.state
Tells the server whether the user can currently see the app. No reply.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
foreground | boolean | Yes | true when the user can see the app; false otherwise. foreground: true at most once per 5 s; false any time and applied at once |
session.subscribe
Adds or changes subscriptions after session.ready. At least one member MUST be non-empty; invalid payload gets a non-fatal error core.invalid_request. Reply: session.subscribed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
resume | object<stream, integer> | No | Resume entries; for an already-subscribed stream restarts it from the given position with replay (gap repair). as in session.hello |
subscribe | array<string> | No | Full subscriptions from head; for a stream already full returns ok with current headSeq. Naming a heads stream here upgrades it to full. as in session.hello |
heads | array<string> | No | Heads subscriptions; naming a full stream here downgrades it to heads. as in session.hello |
session.subscribed
Answer to session.subscribe (re set). Replays and session.resync_required for the new subscriptions follow it.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
subscriptions | array<SubscriptionResult> | Yes | Subscription results. one result per stream named, any order |
session.subscription_ended
The server ended a subscription on its own (continuous authorization lost: kick, ban, leave, needs_encryption, permission change, deletion, device revocation, session end).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
stream | string | Yes | The stream. stream name |
problem | ProblemObject | Yes | Why: e.g. core.forbidden, core.gone, security.account_required, or an owner's code. |
session.unsubscribe
Removes subscriptions. Streams not subscribed, and me, are ignored. Reply: session.unsubscribed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
streams | array<string> | Yes | Streams to remove. at least one entry |
session.unsubscribed
Answer to session.unsubscribe (re set). Server MUST NOT send any event of a removed stream afterwards.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
streams | array<string> | Yes | The streams the server removed. |
05 Accounts, login, sessions, devices and bots
account.deleted
The account was deleted; sent before device sockets are closed (§16.2 step 2).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | Canonical address. |
kind | AccountKind | Yes | user | bot |
inc | base64url | Yes | Receivers apply only to this incarnation. |
deletedAt | timestamp | Yes | |
igen | integer | Yes | Last identity generation. 0 if never secure |
reason | DeletionReason | Yes | user | owner | admin | unconfirmed; unknown treated as admin |
account.profile_changed
S2S hint that the public profile changed, coalesced over 60 s; lane normal; orderKey d.addr; unknown -> ignored. Receiver refetches if cached profileVersion is lower; discards cache on a different inc.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | |
inc | base64url | Yes | |
profileVersion | integer | Yes | New version. |
account.suspended
S2S notice of suspension; receivers end remote sessions of (addr, inc) within 60 s and revoke voice leases; restoration sends nothing. Lane high; orderKey canonical address; no expiresAt; no give-up hook; unknown -> ignored.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | |
inc | base64url | Yes | Apply only to this incarnation. |
kind | AccountKind | Yes | user | bot |
suspendedAt | timestamp | Yes |
account.updated
Any change to the Account object, including state, security and profile.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
account | Account | Yes |
auth.provider_linked
A provider was linked (§10.3).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
link | ProviderLink | Yes |
auth.provider_unlinked
A provider was unlinked (§10.4), or a link created by a replayed code was undone (§6.6).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
linkId | uuidv7 | Yes |
bot.created
A bot was created (§15.2).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
bot | Bot | Yes |
bot.deleted
The bot was deleted.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | Bot's canonical address. |
bot.updated
Any change to the bot or its tokens.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
bot | Bot | Yes |
device.added
A device record was created by login, sign-up or bot-token creation; via login raises W4d on other devices.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
device | DeviceRecord | Yes | |
via | DeviceAddedVia | Yes | login | signup | bot_token; unknown treated as login |
device.updated
Rename, enrolment change, bot token rotation.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
device | DeviceRecord | Yes |
06 Federation
federation.session_ended
A remote session was ended (no seq, ctx = me); sent on each WebSocket of the session before session.closing (session_ended) and close code 4004.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sessionId | uuidv7 | Yes | The ended session. |
reason | SessionEndReason | Yes | Why it ended (§6.8, plus expired or extension_limit).Client treats unknown value as admin |
retry | boolean | Yes | Whether the client should silently try to create a new session. |
07 Identity keys, certificates and verification
device.revoked
A device of the account was revoked (§11.8), or a DeviceRevocation was attached later (§11.7). Sent in both §11.8 cases, including an unlisted device (unenrolled, or of an insecure account), where state is the unchanged current state; delivered with actor to every session of every device of the subject, including unenrolled ones (§12.3).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sub | string | Yes | Subject |
did | string | Yes | The revoked device 16 bytes base64url |
revokedAt | timestamp | Yes | Time of the revocation RFC 3339; the RevokedEntry at when there is one |
igen | integer | Yes | Current igen |
dkf | string | No | Thumbprint of the revoked device's DSK present when the device was listed |
ver | integer | Yes | ver of state |
state | string (IdentityState JWS) | Yes | IdentityState after the revocation for an unlisted device, the unchanged current state |
rev | string (DeviceRevocation JWS) | No | The DeviceRevocation JWS, if one exists hint only; evidence only inside state (§8.2 rule 3) |
actor | Actor | No | As in §12.1 only to own devices |
Also described in 00 §6 HP-7, §7.5, 06 §10.1, 07 §12.2, §12.3.
identity.changed
An account's identity generation, security state or device set grew (upgrade, re-upgrade, reset, downgrade or device registration); delivered to every session of every device of the subject, including unenrolled ones, with actor.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sub | string | Yes | Subject canonical address |
change | IdentityChangeKind | Yes | Kind of change (hint)upgraded, reset, downgraded or device_added; unknown value = unspecified change, act only on state |
ver | integer | Yes | ver of state |
igen | integer | Yes | igen of state |
prevIgen | integer | Yes | igen before the change |
sec | string | Yes | sec of stateinsecure or secure |
state | string (IdentityState JWS) | Yes | The IdentityState JWS after the change; the only evidence |
device | AddedDevice | No | The added device required when change is device_added; {"did": string, "plat": string} |
actor | Actor | No | The initiating device and time of the change only on delivery to the subject's own devices; {"did", "plat", "changedAt" (RFC 3339)}; MUST NOT be sent S2S or to anyone else |
Also described in 00 §6 HP-7, §7.5, 06 §10.1, 07 §12.1, §12.3.
identity.refresh_hint
Sent once per session by a DM hosting server that received an S2S identity.changed or device.revoked to every other participant of every DM or group DM that includes the subject; never replayed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sub | string | Yes | Canonical address of the subject |
ver | integer | Yes | ver of state |
state | string (IdentityState JWS) | Yes | The IdentityState JWS the hosting server received with the S2S event |
08 Turning on encryption, pairing, backup and the vault
backup.updated
Sent to the account's enrolled devices other than the writer after a KeyBackup update; devices update prevVer and apply §5.6.4, without downloading the backup.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
igen | integer | Yes | Identity generation. |
ver | integer | Yes | New backup version (use as prevVer). |
vgen | integer | Yes | Vault generation in backup. |
phraseId | base64url | Yes | Phrase ID of the active backup. 16 bytes |
updatedAt | timestamp | Yes | Write time. |
updatedBy | string | Yes | Writer. did |
pairing.message
Relays one pairing protocol message to the participant it is addressed to.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
pairingId | uuidv7 | Yes | Session ID. |
n | integer | Yes | Message index. from 1 |
type | enum PairingMessageType | Yes | Message type. |
from | string | Yes | Sender device. did |
body | object | Yes | Type-specific body. |
sentAt | timestamp | Yes | When the server accepted it. |
Also described in 00 §8 F4.
pairing.requested
Sent to every enrolled device of the account when a new device creates a pairing session; shows the M5 approval prompt.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(PairingSession) | PairingSession | Yes | The session. §6.2 |
Also described in 00 §6 HP-14, §8 F4.
pairing.updated
Sent to both participants on every state change, and to every prompted device when the session leaves waiting (so prompts disappear).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(PairingSession) | PairingSession | Yes | The session. §6.2 |
vault.changed
Sent to the account's enrolled devices (with open WebSocket) other than the writer after records are written or deleted.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
igen | integer | Yes | Vault igen. |
vseq | integer | Yes | New vseq. |
items | array<{rid, type, bucket, ver, deleted}> | Yes | Changed records. at most 100 |
truncated | boolean | Yes | More changed; read the change feed. |
vault.grant_needed
Sent to enrolled devices other than the named one when a device with a valid box key has no grant for the current generation; at most once per 10 min per device.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
igen | integer | Yes | Identity generation. |
vgen | integer | Yes | Current generation. |
did | string | Yes | Device that needs a grant. |
vault.key_rotated
Sent to the account's enrolled devices after a new vault generation is created.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
igen | integer | Yes | Identity generation. |
vgen | integer | Yes | New generation. |
createdBy | string | Yes | Rotating device. did |
vault.rotation_needed
Sent to the account's enrolled devices when a device is delisted (other than by reset); triggers rotation.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
igen | integer | Yes | Identity generation. |
vgen | integer | Yes | Current (old) generation. |
pendingAt | timestamp | Yes | When rotation became pending. |
did | string | Yes | Delisted device. |
reason | string | Yes | Why delisted. 05 revokedReason; unknown treated as other |
phraseChangePending | boolean | Yes | A new recovery phrase is required (lost_or_stolen). |
09 Communities, membership, channels and security transitions
channel.created
Channel created or became visible; viewer-dependent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
channel | Channel | Yes |
channel.deleted
Channel deleted or hidden from this account; viewer-dependent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | |
address | string | Yes | |
security | string | Yes | |
securedAt | timestamp|null | Yes | |
upgradeSeq | integer|null | Yes | |
reason | string | Yes | lost_access does not set pin deletedSeenAt deleted|lost_access |
channel.security_changed
Channel became secure (channel or server upgrade).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | |
security | string | Yes | secure |
securedAt | timestamp | Yes | |
upgradeSeq | integer | Yes | u |
preUpgradeHistory | string | Yes | kept|deleted |
cause | string | Yes | channel_upgrade|server_upgrade |
by | string|null | Yes | Upgrading admin |
version | integer | Yes | Channel version |
Also described in 00 §6 HP-12.
channel.updated
Channel changed; viewer-dependent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
channel | Channel | Yes | |
changed | array<string> | Yes | Names of changed members |
previousAddress | string | No | present on address change |
community.layout_changed
Category/channel order changed (layout PATCH or any category create/change/delete); viewer-dependent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
categories | array<Category> | Yes | |
channels | array<{ctx, categoryId, position}> | Yes | only channels the recipient can view |
community.list_changed
The account's community list changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
op | string | Yes | upsert|remove |
domain | string | Yes | |
entry | CommunityListEntry|null | Yes |
community.security_changed
Server upgrade completed (U2).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
domain | string | Yes | Canonical domain |
secure | boolean | Yes | true |
securedAt | timestamp | Yes | |
version | integer | Yes | Community version |
cause | string | Yes | server_upgrade |
by | string | Yes | Admin who upgraded address |
community.updated
Community settings or icon changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
community | Community | Yes | Full object |
invite.created
Invite created.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
invite | Invite | Yes |
invite.revoked
Invite revoked.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes | |
code | string | Yes | |
by | string | Yes | address |
member.joined
A membership started.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
scope | string | Yes | channel|community |
member | ChannelMember|CommunityMember | Yes |
member.left
A member left by choice.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
scope | string | Yes | channel|community |
addr | string | Yes | |
reason | string | Yes |
member.rejected
Pending request rejected, expired or closed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
reason | string | Yes | rejected|expired|closed |
member.removed
A membership ended for another reason; never says who removed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
scope | string | Yes | channel|community |
addr | string | Yes | |
reason | string | Yes | kicked|banned|lost_access|account_deleted|community_left |
member.requested
A pending join request was made.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
member | CommunityMember | Yes | state pending |
member.updated
A membership record changed (e.g. needs_encryption, reactivation, rules acceptance, unban).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
scope | string | Yes | channel|community |
member | ChannelMember|CommunityMember | Yes | includes accountSecurity only on the member's own account stream |
10 Roles, permissions, moderation and reports
moderation.applied
A moderation action was applied to the recipient; never names the moderator; sent before delivery is cut.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
action | enum ModerationAction | Yes | kick|ban|timeout|server_mute|restriction |
scope | string|null | Yes | community|server|null |
ctx | string|null | Yes | |
until | timestamp|null | Yes | |
reason | string|null | Yes | only if showReason |
moderation.lifted
A moderation action on the recipient ended (if they still have a session).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
action | enum ModerationAction | Yes | |
ctx | string|null | Yes | |
scope | string|null | Yes |
moderation.logged
New audit entry, to holders of view_audit_log (restricted entries: admins only).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
entry | AuditLogEntry | Yes |
moderation.policy_updated
AntiSpamPolicy changed; viewer-dependent payload filtered per recipient.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
policy | AntiSpamPolicy | Yes |
moderation.server_mute_changed
A member's server mute started or ended.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
address | string | Yes | |
muted | boolean | Yes | |
until | timestamp|null | Yes |
permission.changed
The recipient's own effective permissions changed (hint; clients still recompute).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string|null | Yes | Channel or null for community |
permissions | array<Permission> | Yes |
permission.overwrite_removed
An overwrite was removed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
targetType | enum OverwriteTargetType | Yes | |
roleId | uuidv7 | No | when targetType role |
address | string | No | when targetType member |
permission.overwrite_set
An overwrite was set; not a timeline item; sent before access is cut.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
overwrite | PermissionOverwrite | Yes |
report.created
A report the recipient can see was created (no content).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes | |
ctx | string|null | Yes | |
kind | enum ReportKind | Yes | |
category | enum ReportCategory | Yes | |
target | string | Yes | |
routing | enum ReportRouting | Yes | |
origin | enum ReportOrigin | Yes | |
createdAt | timestamp | Yes |
report.forwarded
S2S event (via 06 POST /v1/federation/events) from the forwarding server to the target's home server; payload d is ReportForwardedPayload. Delivered by 06's S2S event delivery (POST {target home}/v1/federation/events: ingest, retry, dedupe by event ID); 10 states no event class.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
d | ReportForwardedPayload | Yes |
Also described in 00 §6 HP-11, §7.5, 06 §10.1.
report.resolved
To the reporter: their report was resolved, with a coarse outcome.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes | |
outcome | enum ReportOutcome | Yes | action_taken|reviewed |
report.updated
A visible report changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes | |
status | enum ReportStatus | Yes | |
resolution | enum ReportResolution|null | Yes | |
assignee | string|null | Yes | |
forwardedTo | array<string> | Yes | |
updatedAt | timestamp | Yes |
role.created
A role was created. Audience: community stream subscribers.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
role | Role | Yes |
role.deleted
A role was deleted.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
roleId | uuidv7 | Yes |
role.member_added
A member was granted a role.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
roleId | uuidv7 | Yes | |
address | string | Yes |
role.member_removed
A member lost a role.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
roleId | uuidv7 | Yes | |
address | string | Yes |
role.reordered
Role positions changed; lists every role.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
positions | array<{roleId, position}> | Yes | every role |
role.updated
A role changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
role | Role | Yes |
11 Messages, attachments, read state and presence
message.created
New root message (the only timeline-item event of this doc); d is a Message without ctx and seq; reduced {withheld:true} for non-entitled subscribers; tombstone/current forms on replay.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
type | string | No | Item type discriminator. "message"; present in timeline pages only |
mid | uuidv7 | Yes | Root message mid. |
carrier | CarrierType | Yes | Carrier type of the root message. plain or sealed; unknown treated as sealed (placeholder) |
sender | Sender | Yes | Who sent it. |
createdAt | timestamp | Yes | Server timestamp of acceptance. |
content | MessageContent | No | Current content (root or latest edit). plain and not deleted |
sealed | SealedMessage | No | Root SealedMessage as posted; absent once edited. sealed, not deleted, not edited |
edit | EditEntry|null | No | Latest edit (self-contained) or null. sealed only |
mentions | array<string> | No | Server-validated mention hint of the root. sealed only |
mentionAll | boolean | Yes | Server-validated mentionAll: true only if asked for and permitted. |
attachmentIds | array<uuidv7> | No | IDs currently bound (root's or latest edit's). sealed, when any are bound |
editedAt | timestamp|null | Yes | Time of latest edit or null. |
deleted | Deletion|null | Yes | null or how it was deleted. |
reactions | array<ReactionSummary> | No | Aggregated plain reactions. required unless deleted; may be empty |
reactionEntries | array<ReactionEntry> | No | Inlined sealed reaction entries. when there are sealed reaction entries; up to INLINE_REACTION_ENTRIES (100), oldest first |
reactionEntryCount | integer | No | Total sealed reaction entries; fetch rest via §7.3 if larger than inlined. with reactionEntries |
updatedSeq | integer | Yes | seq of latest entry that changed this message (creation, edit, reaction add/remove, deletion). |
Also described in 00 §7.4.
message.deleted
A root message was deleted by author or moderator; d is DeleteEvent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
target | uuidv7 | Yes | Deleted root message. |
by | DeletedBy | Yes | author or moderator. unknown treated as moderator |
mid | uuidv7 | No | Delete entry's mid. when by is author |
deletedAt | timestamp | Yes | When. |
message.edited
A root message was edited; d is EditEvent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
target | uuidv7 | Yes | Edited root message. |
mid | uuidv7 | Yes | Edit entry mid. |
carrier | CarrierType | Yes | plain or sealed. |
sender | Sender | Yes | Editing account and device. |
createdAt | timestamp | Yes | Edit's server timestamp (new editedAt). |
content | EditContent | No | The edit. plain |
sealed | SealedMessage | No | The edit. sealed |
mentions | array<string> | No | Edit's validated hint. sealed |
mentionAll | boolean | Yes | Edit's validated mentionAll. |
attachmentIds | array<uuidv7> | No | Remaining IDs. sealed, when target had bound attachments |
message.purged
Prefix purge: every root message with seq <= throughSeq is gone; delivered to every subscriber.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
throughSeq | integer | Yes | Every root message with seq <= throughSeq and everything attached is gone. |
reason | PurgeReason | Yes | Why. retention, pre_upgrade_deleted or admin; unknown treated as admin |
presence.snapshot
Sent (SHOULD) to a session that just subscribed to the context.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
items | array<Presence> | Yes | Snapshot. non-offline accounts with access to the context; at most PRESENCE_SNAPSHOT_MAX (1,000); no order |
truncated | boolean | Yes | true if more existed. |
presence.updated
Targeted to sessions entitled to see the account's presence (§11.4) and to the account's own sessions.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string (canonical address) | Yes | Canonical address. |
name | string | Yes | Display name (01). |
status | EffectiveStatus | Yes | Effective status. online, idle, dnd or offline; unknown treated as online |
statusText | string|null | Yes | Custom status. null whenever status is offline |
statusEmoji | string|null | Yes | Status emoji. null whenever status is offline |
updatedAt | timestamp | Yes | When this presence last changed. |
reaction.added
A reaction entry was added; d is ReactionEntry without seq.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
mid | uuidv7 | Yes | Reaction entry mid; removing the reaction = deleting this mid. |
target | uuidv7 | Yes | Root message mid. |
carrier | CarrierType | Yes | plain or sealed. |
sender | Sender | Yes | Who reacted. |
createdAt | timestamp | Yes | Server timestamp. |
key | string | No | Reaction key. plain only |
sealed | SealedMessage | No | Encrypted reaction. sealed only; kind reaction, ref = root mid; plaintext ReactionContent |
reaction.removed
A reaction entry was removed; d is ReactionRemovedEvent.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
target | uuidv7 | Yes | Removed reaction entry's mid. |
message | uuidv7 | Yes | Root message it was on. |
by | DeletedBy | Yes | author or moderator. unknown treated as moderator |
mid | uuidv7 | No | Delete entry's mid. when by is author |
read.updated
The account's read position changed; to the account's own sessions on this server.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | The context. |
readSeq | integer | Yes | Everything with seq <= readSeq counts as read. >= 0; 0 = nothing read |
updatedAt | timestamp|null | Yes | When readSeq last changed. |
headSeq | integer | Yes | Context's latest seq. |
lastMessageSeq | integer | Yes | seq of newest visible non-deleted root message. 0 if none; grant-only items don't count |
unreadCount | integer | Yes | Visible non-deleted root messages with seq > readSeq. 0-1,000 (capped); excludes own messages and grant-only items |
unreadCapped | boolean | Yes | true if true count exceeds 1,000 (clients show '999+'). |
mentionCount | integer | Yes | Unread messages mentioning this account (mentions, validated mentionAll, reply ping). 0-1,000; from hints in secure contexts |
typing.started
Targeted to sessions of other accounts that can see the context.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sender | Sender | Yes | Typing account. did is the typing device |
expiresInMs | integer | No | How long to show it. only on typing.started: 8,000 |
typing.stopped
Emitted on typing:false only; never on TTL expiry or message acceptance.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sender | Sender | Yes | Typing account. did is the typing device |
12 Direct messages and group DMs
dm.block_updated
A DM block was added or removed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | |
blocked | boolean | Yes | |
block | DmBlock|null | Yes | null when unblocked |
dm.call_logged
Call started/ended entry; phase started is a content event.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | (15) |
phase | enum CallLoggedPhase | Yes | unknown ignored |
by | string | Yes | caller's address |
video | boolean | Yes | |
at | timestamp | Yes | |
durationMs | integer | No | ended only |
answered | boolean | No | ended only |
dm.closed
DM closed (timeline item, K5 for host_secure).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
reason | enum DmClosedReason | Yes | |
marker | string|null | Yes | K5 or null |
dm.created
DM created (timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
kind | enum DmKind | Yes | |
createdBy | string | Yes | |
security | enum DmSecurity | Yes | |
participants | array<string> | Yes | addresses |
name | string|null | Yes | |
replaces | object|null | Yes |
dm.entry_updated
Hosting server → participant's home: keeps the DM index entry current; also coalesced activity hint.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | Context reference. |
recipient | string | Yes | Participant concerned. homed at the receiver |
recipientInc | string | Yes | Participant's incarnation as recorded by hosting server. |
kind | enum DmKind | Yes | Current value. as §6.1 |
security | enum DmSecurity | Yes | Current value. as §6.1 |
state | enum DmState | Yes | Current value. as §6.1 |
closedReason | enum DmClosedReason|null | Yes | Current value. as §6.1 |
name | string|null | Yes | Current value. as §6.1 |
owner | string|null | Yes | Current value. as §6.1 |
replaces | object|null | Yes | Current value. as §6.1 |
participants | array<{addr, name, kind, inc, state, security}> | Yes | Participants. as §8.2 |
yourState | enum ParticipationState | Yes | Recipient's own participation state. |
yourReason | string|null | Yes | Recipient's own reason, if any. |
lastSeq | integer | Yes | DM's lastSeq. |
lastActivityAt | timestamp|null | Yes | Timestamp of latest content event, or null. |
dm.index_removed
A DM index entry was deleted (DELETE or end of 30-day declined period).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes |
dm.index_updated
A DM index entry changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
entry | DmIndexEntry | Yes | without pendingEvents |
dm.participant_added
Participant added (timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
participant | DmParticipant | Yes | filtered per §6.5 |
addedBy | string | Yes |
dm.participant_removed
Participant left/removed (timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | |
reason | enum ParticipantReason | Yes | as visible to the receiver (§6.5) |
by | string|null | Yes | remover's address for removed via §12.3; null otherwise, including hosting-server removals |
dm.participant_updated
Participant state/role changed; timeline line "{person} joined" only when state becomes active in a group DM.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
addr | string | Yes | |
state | enum ParticipationState | Yes | |
role | enum ParticipantRole | Yes |
dm.request
Hosting server → recipient's home: one batch of an invitation (first contact).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
invitationId | uuidv7 | Yes | Assigned by the hosting server to this invitation. |
batch | integer | Yes | Batch number. 1, 2, 3, … |
truncated | boolean | Yes | True when the size limit stopped further events. |
ctx | string | Yes | Context reference. |
kind | enum DmKind | Yes | direct or group. |
host | string | Yes | Canonical domain of hosting server. MUST equal the S2S token's iss |
recipient | string | Yes | Invited participant. homed at the receiver |
recipientInc | string | Yes | Recipient's incarnation as recorded by the hosting server. |
inviter | {addr, name, kind, inc} | Yes | The inviter (sender of the request). |
createdBy | string | Yes | Creator's canonical address (for host legitimacy check). |
participants | array<{addr, name, kind, inc, state, security}> | Yes | Current participants. filtered as §6.5; recipient's own entry shows pending |
security | enum DmSecurity | Yes | DM security at time of this batch. |
state | enum DmState | Yes | DM state. |
name | string|null | Yes | Group name or null. |
replaces | object|null | Yes | Predecessor when a successor. {host, ctx} |
communityHints | array<string> | No | Copied from creator's/adder's request. <=10; batch 1 only |
identityStates | array<string> | No | IdentityStates of secure participants. IdentityState JWSs, each at most 24 h old; batch 1 and any batch after an identity change |
welcome | base64url|null | Yes | MLSMessage carrying the Welcome that added the recipient's devices. secure DMs only, in the batch that first follows it |
events | array<event envelope> | Yes | Durable DM events (dm.*, message.created, and for secure DMs 13's handshake events). seq order; from the invitation's start event or after previous batch |
Also described in 00 §6 HP-9, 06 §10.1.
dm.request_received
A message request (batch) arrived.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
request | DmRequest (list form) | Yes | |
batch | integer | Yes |
dm.request_resolved
A message request changed state.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | uuidv7 | Yes | |
state | enum DmRequestState | Yes |
dm.response
Recipient's home → hosting server: accept/decline/block/unblock.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | Context reference. |
recipient | string | Yes | Responding participant. MUST be homed at the sender (iss) |
recipientInc | string | Yes | Responding account's incarnation. |
invitationId | uuidv7|null | Yes | Invitation answered. null for unblock and responses not tied to one invitation; informative |
action | enum DmResponseAction | Yes | accept, decline, block or unblock. unknown values ignored |
at | timestamp | Yes | When the user (or auto-accept rule) acted; used for last-writer-wins. |
Also described in 00 §7.5, §6 HP-9, 06 §10.1.
dm.security_changed
Security mode switched (timeline item, K1/K2).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
security | enum DmSecurity | Yes | new |
previous | enum DmSecurity | Yes | |
generation | integer | Yes | generation now in force, or the retired one when becoming insecure |
lastSeqBefore | integer | Yes | last seq under previous mode |
marker | enum SecurityChangedMarker | Yes | K1 or K2; unknown treated as none |
cause | enum SecurityChangedCause | Yes | unknown ignored |
dm.security_eligible
Computed security became secure; DM is upgrading; an enrolled device must bootstrap (not a timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
generation | integer | Yes | next group generation |
participants | array<{addr, security}> | Yes | every current participant |
Also described in 00 §8 F8.
dm.settings_changed
Group name or owner changed (timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
name | string|null | No | only if changed |
owner | string|null | No | only if changed |
by | string|null | Yes | null when the hosting server made the change |
dm.settings_updated
DmSettings changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
settings | DmSettings | Yes |
dm.state_changed
DM state changed (not a timeline item).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
state | enum DmState | Yes | new |
previous | enum DmState | Yes | |
reason | enum StateChangedReason | Yes | unknown ignored |
13 MLS profile
mls.commit_needed
Asks the designated committer to commit pending proposals (or a self-update for group_info_refresh) within 3 s.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
epoch | integer | Yes | Epoch whose pending proposals need a commit |
proposalRefs | array<string> | Yes | Every pending proposal ref may be empty for group_info_refresh |
reason | CommitNeededReason | Yes | Why removal|key_rotation|reissue|group_info_refresh; unknown: commit anyway |
deadlineMs | integer | Yes | Deadline 3000 |
round | integer | Yes | Designation round 1 for first pass, then 2, 3... |
Also described in 00 §6 HP-3.
mls.group_created
A group was bootstrapped (epoch 0); sent in full to every subscriber of the context stream.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
generation | integer | Yes | Generation |
epoch | integer | Yes | Epoch 0 |
ekid | base64url | Yes | ekid(0) |
creator | object | Yes | Bootstrapping device {addr, did} |
mls.group_retired
The generation is retired; move to nextGeneration if not null.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
generation | integer | Yes | Retired generation |
reason | GroupRetiredReason | Yes | Why context_insecure|context_deleted|state_lost|operator; unknown: treat as operator |
nextGeneration | integer|null | Yes | Next generation null when the context is no longer secure |
mls.handshake
An accepted commit; HandshakeRecord for eligible devices, reduced payload {groupId, epoch, newEpoch, kind} for other subscribers.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
epoch | integer | Yes | The epoch the commit was made in |
newEpoch | integer | Yes | Epoch after the commit epoch + 1 |
kind | HandshakeKind | Yes | Commit sender kind external | member; unknown: process by MLS content |
commit | base64url | Yes | The commit MLSMessage exactly as submitted |
committer | object | Yes | Committer's canonical address, device ID, leaf index {addr, did, leaf}; leaf is the index in the new epoch |
proposals | array<ServerProposal> | Yes | Full ServerProposal objects the commit references empty if none |
identityStates | array<string> | Yes | Evidence attached by the server (§8.3) IdentityState JWSs; never empty (at least the committer's) |
ekid | base64url | Yes | Reference ekid of newEpoch: settled value once settled, else committer's provisional value 8 bytes, 11 chars |
ekidSettled | boolean | Yes | Whether ekid is settled always false in the mls.handshake event |
commitHash | base64url | Yes | Commit hash SHA-256 of the commit MLSMessage bytes |
welcomeFor | array<object> | No | Devices added by Welcome DMs only; {addr, did} each |
at | timestamp | Yes | Acceptance time |
Also described in 00 §6 HP-2, §7.4.
mls.keypackages_low
The device's regular KeyPackages fell below 10 after a claim, or its last-resort KeyPackage was handed out, or after a KeyPackage store restore.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
did | string | Yes | Device |
available | integer | Yes | Regular KeyPackages left |
lastResort | boolean | Yes | Last-resort stored |
lastResortUsed | boolean | Yes | Last-resort handed out |
target | integer | Yes | Refill target 50 |
mls.proposal
A server proposal was issued; ServerProposal for eligible devices, reduced payload {groupId, epoch, ref, type} for others.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group the proposal belongs to group_id format §4.1 |
epoch | integer | Yes | The epoch the proposal is bound to |
ref | base64url | Yes | Proposal identifier SHA-256 ProposalRef (RFC 9420 §5.2), 43 chars |
type | ServerProposalType | Yes | Proposal type remove | group_context_extensions |
proposal | base64url | Yes | The signed proposal MLSMessage, wire format mls_public_message |
reason | RemovalReason | Yes | Server annotation (not signed) §13.1; unknown values: treat as lost_access |
target | object | No | The leaf to remove (server annotation, not signed) {addr, did, leaf}; required for type remove |
evidence | object | No | Evidence supporting device_revoked, identity_changed, account_downgraded (not signed) {identityState: JWS} and/or {deviceRevocation: JWS} |
reissueOf | base64url | No | ref of the proposal this one replaces after an external commit (§13.5) |
issuedAt | timestamp | Yes | Issue time |
mls.resync_required
Tells one device to resync (§10.5) after a random 0–2 s delay.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
generation | integer | Yes | Generation |
epoch | integer | Yes | Server's current epoch |
reason | ResyncRequiredReason | Yes | Why fork|commit_unprocessable|duplicate_leaf|state_lost; unknown: resync |
mls.welcome
A Welcome is pending for this device; fetch with GET …/mls/welcome.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
groupId | string | Yes | Group ID |
generation | integer | Yes | Generation |
epoch | integer | Yes | Join epoch |
14 Sealed messages, history visibility and sharing
15 Calls: control, leases, routing and continuity
call.ended
The call ended.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
reason | CallEndReason | Yes | End reason. §2.4; unknown → treat as context_closed |
endedAt | timestamp | Yes | End time. |
next | object | No | Mode of the replacement call. {"security": …} only for security_upgraded; a hint only |
call.epoch_switch
Call control switched mediaEpoch.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
epoch | integer | Yes | New mediaEpoch. |
Also described in 00 §6 HP-5.
call.lease_changed
The participant's own audio or video membership changed; says why.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(payload) | VoiceLease | Yes | New VoiceLease. |
call.migrate
Planned relay migration: rejoin with planned: true.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
reason | string | Yes | Why. drain | rebalance; unknown → drain |
deadlineMs | integer | Yes | Migration window. 10000 |
call.moved
The participation moved to the user's other device (Move voice here); terminal for this device.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
pid | integer | Yes | Old pid. |
sameCall | boolean | Yes | true if the other device joined this same call, false if another call on this server. |
call.participant_joined
A participation was admitted.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
participant | Participant | Yes | The new participant. |
rejoined | boolean | No | New pid after a timed-out/session_expired seat was rejoined; play no join sound. default false |
movedFrom | integer | No | Old pid when Move voice here landed in the same call; no leave/join sound. |
call.participant_left
A seat was removed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
pid | integer | Yes | Removed pid. |
addr | string | Yes | Canonical address. |
reason | SeatRemovalReason | Yes | Why. left | timeout | removed | revoked | session_expired | moved | switched | call_ended; unknown → left |
call.participant_updated
A participant's state, mute flags, sources or leafIndex changed, or a seat was restored.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
participant | Participant | Yes | Updated participant. |
call.ring_ended
A target's ring ended.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | The DM context. |
callId | uuidv7 | Yes | The call. |
addr | string | Yes | Target. |
reason | RingEndReason | Yes | Why. answered | declined | timeout | cancelled; unknown → cancelled |
call.ring_updated
The call's Ring changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
ringing | Ring or null | Yes | Current ring. |
ended | object | No | Present when a target's ring just ended. {addr, reason} with reason as for call.ring_ended |
call.ringing
Incoming DM call ring.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | The DM context. |
callId | uuidv7 | Yes | The call. |
by | object | Yes | Caller. {addr, name} |
security | string | Yes | Call security. |
video | boolean | Yes | Caller started with webcam. |
expiresAt | timestamp | Yes | This target's ring expiry. |
call.route_changed
The call's videoRoute changed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
videoRoute | VideoRoute | Yes | dc or sfu. |
call.started
A call was created; sent before the first call.participant_joined.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
call | Call | Yes | The new call. |
call.state
Current call or null; sent after the SubscriptionResult and before any later call event; the catch-up mechanism.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
call | Call or null | Yes | Current call. |
call.tick
Lease tick: a LeaseSnapshot; discarded if queued > 250 ms.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(payload) | LeaseSnapshot | Yes | The snapshot. |
Also described in 00 §6 HP-15, §7.4, 15 §4.4, §6.5.
relay.closing
The relay is ending the session.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
reason | RelayClosingReason | Yes | Why. unknown → unexpected drop |
retryAfterMs | integer | Yes | Retry hint. 0 with drain |
relay.error
Problem with a control message the client sent; never ends the session.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(payload) | problem object (00 §7.9) | Yes | Problem. code relay.bad_message or core.rate_limited |
relay.ping
Client keepalive every 5 s.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
n | integer | Yes | Ping counter. incrementing |
relay.pong
Relay echoes ping n at once.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
n | integer | Yes | Echoed counter. |
relay.subscribe
Which sources 1, 2, 3 this receiver wants; replaces previous list.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
sources | array<{pid, sourceId}> | Yes | Wanted sources. starts empty; relay MUST accept ≥ 32 entries; source 0 never subscribed |
relay.welcome
Relay's first message on a session, followed at once by the newest call.tick.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
pid | integer | Yes | Session pid. |
relaySessionId | string | Yes | Session ID. |
maxInboundKbps | integer | Yes | Cap on everything this session may send. default 10,000 |
sfu.closed
The SFU session was closed.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
sfuSessionId | uuidv7 | Yes | The SFU session. assigned by call control |
reason | SfuClosedReason | Yes | Why. route_changed | negotiation_timeout | removed | sfu_failed; unknown → sfu_failed |
sfu.offer
Server-initiated SFU renegotiation; answer within 10 s.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
sfuSessionId | uuidv7 | Yes | The SFU session. assigned by call control |
negotiationId | uuidv7 | Yes | Fresh per server offer. |
offer | string | Yes | SDP offer. |
tracks | array<Track> | Yes | Transceivers. |
sfu.tracks_changed
Track states changed (e.g. paused by lease enforcement).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | uuidv7 | Yes | The call. |
sfuSessionId | uuidv7 | Yes | The SFU session. assigned by call control |
tracks | array<Track> | Yes | Transceivers. |
16 Audio
call.media_feedback
Listener-to-sender loss report (audio_loss) for one audio stream, used only to tune the sender's Opus in-band FEC; from is set by the relay. Protected hop by hop (DTLS) only, in every mode. 15's message table lists its direction as client → client (through the relay) and relay → client; 16 defines only listener-sent audio_loss.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
kind | string | Yes | Feedback kind defined by this documentaudio_loss |
sourceId | integer | Yes | The reported stream of the sender to0 or 2 |
lossPermille | integer | Yes | Frames missing at the network level (before FEC) over the report interval 0–1,000; floor(1,000 × lost / expected) |
latePermille | integer | Yes | Frames that arrived after their playout deadline (§9.3) 0–1,000; floor(1,000 × late / expected) |
bufferTargetMs | integer | Yes | The listener's current jitter-buffer target T (§9.3) for this stream0–1,000 |
received | integer | Yes | Distinct sequence numbers received in the interval 0–65,535; capped at 65,535 |
Also described in 15 §6.6, §16.2.
18 Media end-to-end encryption
media.attestation
Control-channel message (15 §6.5 envelope, t = media.attestation) carrying one MediaAttestation: a DSK labelled signature over the 8-byte frame hashes of one batch of consecutive counters of one KID. Sent on the relay control channel whatever route the frames took, including sources sent through the SFU (SFU sessions have no control channel). The relay sets from and forwards it unchanged otherwise to every listener except the sender, whether or not they subscribed to the source on the relay. Sent only in secure calls; best-effort control traffic subject to 15 §6.5 rate limits.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
t | string | Yes | Control-channel message type (15 §6.5 envelope). "media.attestation" |
from | integer | Yes | The sending participant's pid. pid; set by the relay |
d.v | integer | Yes | Format version. 1; receivers ignore a message with any other value |
d.callId | uuidv7 | Yes | The call's callId. lowercase hyphenated; must be this call's callId |
d.epoch | integer | Yes | The MLS epoch of the KID's keys. low 4 bits MUST equal the KID's residue |
d.src | integer | Yes | The KID's sourceId, repeated in clear so a relay can route without parsing the KID. 0-3; must equal the KID's sourceId |
d.kid | string | Yes | The KID. kid-string: decimal, no leading zeros, value < 2^56 |
d.first | integer | Yes | First counter of the batch. 0 to 2^32 - 1 |
d.last | integer | Yes | Last counter of the batch. first <= last <= first + 255 and last <= 2^32 - 1 |
d.hashes | base64url | Yes | Concatenated frame hashes in counter order. exactly 8 x (last - first + 1) octets |
d.sig | base64url | Yes | Ed25519 labelled signature (label media-attest) over MediaAttestationContent. 64 octets |
19 Notifications and push
notification.created
A new notification record; desktop clients turn non-silent ones into OS notifications.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
record | NotificationRecord | null | Yes | The record. null in reduced payload for devices not in targets |
id | string | No | Record id. only in reduced payload |
badge | integer | Yes | Badge. per receiving session's device |
notification.settings_changed
A notification settings entry changed (deleted entries sent with defaults).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
scope | enum SettingsScope | Yes | Which settings. global | community | context |
settings | NotificationSettings | CommunityNotificationSettings | ContextNotificationSettings | Yes | The new settings. |
notification.state_changed
Records that moved to a state (read, dismissed, withdrawn).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ids | array<string> | Yes | Record IDs. at most 100; per-session filtered by targets; may be [] |
state | enum RecordState | Yes | New state. unknown -> no action except badge |
badge | integer | Yes | Badge. |
notification.updated
Full new state of a changed record (ring ended, items withdrawn, preview dropped).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
record | NotificationRecord | null | Yes | The record. null in reduced payload |
id | string | No | Record id. only in reduced payload |
badge | integer | Yes | Badge. |
notify.event
S2S event from hosting server to recipient's home server (06 event envelope, batching, retries, dedup); lane high for ring kinds, normal otherwise; orderKey = recipient canonical address.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
recipient | string | Yes | Account to notify. canonical address homed at receiver |
kind | enum NotificationKind | Yes | Kind. S2S kinds only; unknown -> ignored |
host | string | Yes | Hosting server canonical domain. MUST equal S2S token iss |
ctx | string | Yes | Context. context reference |
ctxKind | enum CtxKind | Yes | channel | direct | group. agree with ctx prefix |
ctxName | string | null | Yes | Context name. <= 100 scalar values |
ctxAddr | string | null | Yes | Channel canonical address. channels only |
community | object | null | Yes | Community. {name} <= 100 scalar values, channels only |
security | enum Security | Yes | Mode when sequenced. unknown -> secure |
sender | AddressRef | webhook Sender | Yes | Latest trigger's sender or caller. except withdrawn |
at | timestamp | Yes | Latest trigger time. |
items | array<NotifyItem> | No | Triggers. message kinds; 1-20, oldest first |
count | integer | No | Triggers represented. message kinds; >= items length |
otherSenders | integer | No | Distinct other senders. message kinds |
preview | Preview | null | No | Preview. insecure message kinds only |
ticket | EventTicketRef | No | Event ticket. message kinds |
call | NotifyCall | No | Call info. call kinds |
withdrawn | array<string> | No | Withdrawn mids. withdrawn; 1-50 mids |
previewOnly | boolean | No | Edit, not delete. withdrawn only; default false |
Also described in 00 §2.9, §4.9, §6 HP-9, 06 §10.1.
notify.triggered
In-app notification for mention/reply/mention_all/dm_message triggers, sent attentive or not; clients MUST NOT show an OS notification for it.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
ctx | string | Yes | Context. context reference |
kind | enum NotifyItemKind | Yes | Trigger kind. mention | reply | mention_all | dm_message; unknown -> dm_message for display |
seq | integer | Yes | seq of triggering event. |
mid | string | Yes | Triggering entry. root mid, or edit entry mid for an edit that newly mentions |
sender | AddressRef | webhook Sender | Yes | Sender. {addr, name, kind}; kind user|bot|webhook; webhook has no addr; unknown kind -> user |
at | timestamp | Yes | Event timestamp. |
push.registration_removed
The home server deleted a push registration; the owning client re-registers silently if it can.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
id | string | Yes | Registration id. |
did | string | Yes | Device id. |
reason | enum RegistrationRemovedReason | Yes | Why. gone | rejected | gateway_not_allowed |
21 Deployment and operations
relayctl.ack
relay -> control. Acknowledges snapshot processing within 100 ms; MAY combine acks produced within 20 ms of each other.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
acks | array<SnapshotAck> | Yes | One entry per processed snapshot. |
relayctl.call_close
control -> relay. The call ended or moved away; relay sends relay.closing (mapped from reason) to remaining sessions, closes them and frees call state (including replay cache entries for that call's tickets once expired).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | The call. |
reason | CallCloseReason | Yes | Why the call is closed; decides the relay.closing reason sent to clients. ended | restarted | migrated | lost | unknown; unknown value treated as unknown |
relayctl.call_drain
control -> relay. Starts the old relay's part of a planned relay migration (15 §6.9): relay.closing drain with retryAfterMs 0 to every session, keep forwarding under snapshots, close remaining sessions at the deadline (session_down drain_deadline), keep call state until call_close or 15 s after the deadline with no snapshot.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | The call to drain. |
deadlineMs | integer | Yes | Time after receipt at which remaining sessions are closed. 10000 in this version; any other value treated as 10,000 |
relayctl.call_open
control -> relay. Creates call state (no-snapshot state, forwards nothing until a snapshot) before the first snapshot of a call on that relay: on assignment, on migration to the relay, and on resynchronisation. Repeated identical open is a no-op; changing security, ctx or url is refused with core.conflict. Reply relayctl.error only on failure.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | The call. 15 §2.5.1 |
ctx | string | Yes | Used for logs and for the ticket ctx check of §6.7 rule 2. context reference |
security | CallSecurity | Yes | The call's fixed mode (15 §2.1 rule 3); used for the protection-flag check of 16 §4.9.2. insecure | secure; unknown value MUST be refused with core.invalid_request |
url | string | Yes | Relay URL the call is assigned to; RelayTickets carry it as aud (15 §5.1). one of the relay's hello urls |
profiles | array<RelayProfile> | Yes | Relay profiles allowed in the call. subset of voice-dc/1, video-dc/1; MAY change (applies to new sessions) |
maxInboundKbps | integer | No | Per-session inbound cap for this call. default from the welcome; MAY change (applies to new sessions) |
relayctl.call_stats
relay -> control. Every 5,000 ms, lists each call open on the link in which at least one session subscribes (relay.subscribe) to source 1 or 3; used for 17 §13.2 items 2 and 3. Unknown members ignored.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
calls | array<CallStatsEntry> | Yes | Per-call video fan-out counters. at most 256 entries per message (send several messages if needed) |
relayctl.error
Either direction. Rejects a malformed or unacceptable message; carries a problem object in d and re naming the offending message. Never closes the link by itself.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
(d) | problem object (00 §7.9) | Yes | The problem. code one of core.invalid_request, core.unsupported_version, core.forbidden, core.conflict, relay.call_unknown; data.errors (03 §10.5) points at the offending member for core.invalid_request |
relayctl.hello
relay -> control. The relay's first message on a new control link; answered by relayctl.welcome (re set) or relayctl.error and a close. Nothing else is sent by either side until the welcome.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
relayId | string | Yes | Operator-assigned, stable across restarts of the node. relay-id = 1*64( ALPHA / DIGIT / "." / "_" / "-" ) |
protocol | string | Yes | Binding version. major.minor (03 §12.1 grammar); this document is "1.0" |
urls | array<string> | Yes | Relay URLs at which this node accepts /connect. Call control MUST check every one is allowed for this relayId, else relayctl.error core.forbidden and close 4003. 1–8 relay URLs (15 §6.1 relay-url) |
software | string | No | Product and version, for diagnostics. at most 64 characters |
region | string | No | Operator's location label. 1–64 characters of [a-z0-9-] |
capacity | RelayCapacity | Yes | What the operator configured this node to carry. {maxSessions, maxEgressKbps}, both >= 1 |
state | RelayState | Yes | Current load state (§6.5.3). accepting | full | draining |
calls | array<string> | Yes | callIds this node holds state for under this issuer from an earlier link (§6.8). at most 10,000 entries; empty after a restart |
relayctl.keys
control -> relay. Replaces the relay's key set for the link's issuer; applied atomically; a keysVersion not higher than the held one is ignored. Answered by relayctl.keys_ack. MUST be sent within 1,000 ms of any change to the issuer's sign keys.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
keysVersion | integer | Yes | As in relayctl.welcome. >= 1, never decreases |
keys | array<ServerKey> | Yes | As in relayctl.welcome. 1–16 sign keys |
revoked | array<string> | Yes | As in relayctl.welcome. RFC 7638 thumbprints, last 400 days |
relayctl.keys_ack
relay -> control. Acknowledges relayctl.keys, naming the version the relay now holds. A relay that doesn't ack within 2,000 ms is treated as failed (close 4008).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
keysVersion | integer | Yes | The key-set version the relay now holds. |
relayctl.load
relay -> control. Load and state report, every 5,000 ms and at once when state changes. Used for relay assignment (§6.10).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
state | RelayState | Yes | accepting, full or draining. unknown treated as full |
sessions | integer | Yes | Open sessions on this link's issuer. |
sessionsTotal | integer | Yes | Open sessions on the node, all issuers. |
calls | integer | Yes | Open calls on this link. |
ingressKbps | integer | Yes | Ingress bandwidth. node total over the last 5 s |
egressKbps | integer | Yes | Egress bandwidth. node total over the last 5 s |
cpuPermille | integer | No | Node CPU use. 0–1000 per core-equivalent of capacity |
dropPermille | integer | Yes | Media messages dropped for queue or lateness reasons (16 §8.1). per thousand forwarded, over the last 5 s |
relayctl.ping
control -> relay. Heartbeat every heartbeatMs (1,000 ms); the relay answers relayctl.pong with the same n at once.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
n | integer | Yes | Heartbeat counter echoed in the pong. |
relayctl.pong
relay -> control. Heartbeat reply with the same n. No pong for 3,000 ms makes call control close with 4008 and enter suspect.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
n | integer | Yes | The n of the ping being answered. |
relayctl.session_close
control -> relay. Removes one participation's relay session: relay stops forwarding at once, sends relay.closing with reason and retryAfterMs, closes the peer connection after flush or 1,000 ms, then reports relayctl.session_down reason instructed. Does nothing if no session exists. Sent for every seat removal within 500 ms of the decision and after the snapshot that removes the pid.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | The call. |
pid | integer | Yes | The participant whose session to close. |
reason | RelaySessionCloseReason | Yes | The relay.closing reason to send (15 §6.6). left, removed, revoked, moved, switched, call_ended, call_restarted, session_expired, drain, timeout, overloaded; unknown values passed through unchanged |
retryAfterMs | integer | No | Passed through in relay.closing. |
relayctl.session_down
relay -> control. A session ended. Call control identifies sessions by (relayId, relaySessionId) and ignores a report that isn't the seat's current session.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | The call. |
pid | integer | Yes | The participant. |
relaySessionId | string | Yes | The session that ended. |
reason | SessionDownReason | Yes | Why the session ended. unknown values treated as transport_closed |
downAt | timestamp | Yes | When it ended. RFC 3339 |
relayctl.session_up
relay -> control. Sent within 100 ms after the relay created a session and sent relay.welcome and the first call.tick on it. Call control checks the seat (pid exists and belongs to did); if so records (relayId, relaySessionId) as the seat's current session and applies the 15 §2.6 'relay reports the session up' transition; otherwise sends session_close reason revoked and records a security diagnostic. For a replacement, session_up for the new session MUST precede session_down replaced for the old.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
callId | string | Yes | From the ticket's cid. |
pid | integer | Yes | From the ticket. |
did | string | Yes | Device ID, from the ticket. |
sub | string | Yes | Address, from the ticket. |
relaySessionId | string | Yes | As returned to the client (15 §6.2). at most 64 characters; unique only within one relay |
iceTcp | boolean | Yes | The session uses ICE-TCP; for capacity planning only. |
upAt | timestamp | Yes | When the session came up. RFC 3339 |
relayctl.snapshot
control -> relay. Delivers LeaseSnapshots; the relay processes each in order (unknown_call / invalid / stale / applied) and, on applied, emits it as call.tick to every session of the call. Answered by relayctl.ack.
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
snapshots | array<LeaseSnapshot> | Yes | Snapshots to apply. 1–256 LeaseSnapshots (15 §4.2), at most one per callId per message; each names a call opened on this link |
relayctl.welcome
control -> relay. Accepts the link; carries the issuer, binding version, link ID and the issuer's sign keys. Always replaces the relay's key set for that issuer whatever its version. Followed by resynchronisation (call_open + newest snapshot for every call assigned to the relay; call_close for listed calls not assigned).
| Name | Type | Required | Meaning and constraints |
|---|---|---|---|
issuer | string | Yes | The hosting server. Every call opened on this link belongs to it. Relay MUST check it against its configuration (close 4003 on mismatch). canonical domain |
protocol | string | Yes | Binding version call control will use: the highest minor of the shared major. major.minor |
linkId | uuidv7 | Yes | Names this link, for logs. |
keysVersion | integer | Yes | Version of the key set. >= 1; never decreases for an issuer across restarts and changes of link holder |
keys | array<ServerKey> | Yes | The issuer's ServerKeys (02 §11.1) for RelayTicket validation. 1–16 entries; purpose sign only, with current status |
revoked | array<string> | Yes | Every sign key the issuer revoked in the last 400 days. RFC 7638 thumbprints |
heartbeatMs | integer | Yes | Heartbeat interval (§6.8). 1000 in this version |
maxInboundKbps | integer | Yes | Default inbound cap per session (15 §6.6); a call MAY override it in relayctl.call_open. default 10000 |