| Socket | Details | Description |
|---|
control | path /v1/accounts/{a}/calls/socket, scope calls, protocol 4 | Call commands and events as JSON text. Send call.hello within five seconds of connecting, then wait for hello. Authenticate with an Authorization: Bearer header or a single-use ?ticket= issued by POST /v1/accounts/{a}/calls/tickets. |
media | path /v1/accounts/{a}/calls/{call}/media, scope calls, protocol 4 | Audio and video for one call you own. Send media.attach within five seconds of connecting, then wait for media.ready. JSON text messages carry track lifecycle and keyframe requests; binary messages carry a 36-byte big-endian WXCM v3 header followed by PCM16 audio or Annex-B H.265/H.264 or JPEG video bytes. Authenticate with an Authorization: Bearer header or a single-use ?ticket= issued by POST /v1/accounts/{a}/calls/tickets. |
Messages you send
call.hello
Announce the protocol versions this client supports. Send it within five seconds of opening the control socket, before any command. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
supportedProtocolVersions | array of integer, required, items min 0, items format uint32 | One to eight distinct positive version numbers. The daemon picks the highest supported version (currently 3 or 4) and answers protocol.error when the list does not include one it speaks. |
call.answer
Answer the incoming call. The first client to answer owns the call; others get already_claimed. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the offered call. |
cameraEnabled | boolean, nullable | Initial camera state when answering a video call. Defaults to true for video calls, ignored for voice calls. |
expectedRevision | integer, required, min 0, format uint32 | The latest offer revision you received. A stale revision is rejected. |
muted | boolean, nullable | Initial microphone mute state when answering. Omitted means false. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.camera
Turn your outgoing camera on or off during a video or conference call. Starts a new video send generation, announced by track.updated. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
enabled | boolean, required | True to enable outgoing video, false to disable it. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.cancel
Cancel your outgoing call before the other side picks up. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of your outgoing call. |
expectedRevision | integer, required, min 0, format uint32 | The latest call revision you received. A stale revision is rejected. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.clear_audio
Discard queued outgoing audio, for example to interrupt a reply. This starts a new send generation, announced by track.updated. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.clear_video
Discard queued outgoing video without turning the camera off for the remote party, for example to interrupt a synthetic video reply. Starts a new video send generation announced by track.updated and asks the sender for a fresh keyframe with parameter sets. Requires call protocol version 4 or newer. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.dial
Start an outgoing call. The socket becomes the call’s owner. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callType | string, required, values voice|video | Whether to place a voice or video call. |
cameraEnabled | boolean, nullable | Initial camera state for video calls. Defaults to true when callType is video, ignored for voice calls. |
muted | boolean, nullable | Initial microphone mute state. Omitted means false. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
target | object, required | Who to call. |
target.contactId | string, required, when kind direct | The contact to call. A group ID is not accepted. |
target.groupId | string, required, when kind conference | The group to call, whose ID ends in @chatroom. |
target.invitees | array of string, required, when kind conference | Contacts to invite: between 1 and 100. |
target.kind | string, required, values direct|conference | direct: A direct call with one contact; conference: A new conference call in a group |
call.hangup
End a call after answering or connecting. In a conference this leaves the call without ending it for the others. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
expectedRevision | integer, required, min 0, format uint32 | The latest call revision you received. A stale revision is rejected. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.invite
Invite more contacts into a connected conference call you own. Results arrive as call.invitation_result. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the conference call. |
contactIds | array of string, required | Contacts to invite: between 1 and 100. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.join
Join a conference call from one of the listed invitations. The socket becomes the call’s owner, as with call.dial. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
cameraEnabled | boolean, nullable | Whether to join with your camera enabled. Omitted means false. |
invitationId | string, required | The invitationId of an entry in conferenceInvitations. |
invitationRevision | integer, required, min 0, format uint32 | The revision of that entry. A stale or used invitation fails with offer_expired. |
muted | boolean, nullable | Whether to join with your microphone muted. Omitted means false. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.mute
Mute or unmute your outgoing audio. This also clears queued audio and starts a new send generation, announced by track.updated. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
muted | boolean, required | True to mute, false to unmute. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.ready
Advertise or withdraw readiness to handle call media. A new connection is passive until it advertises readiness. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
format | object, required, rejects unknown fields | The PCM format you will send and receive. It must match the daemon’s audio format. |
format.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
format.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
format.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
ready | boolean, required | True to advertise readiness, false to withdraw it. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
scope | object, nullable | Which calls readiness covers. Omitted means all. Ignored when withdrawing readiness. |
scope.callId | string, required, when kind offer | ID of the pending incoming call. |
scope.expectedRevision | integer, required, min 0, format uint32, when kind offer | The offer revision you expect; a different revision is rejected. |
scope.kind | string, required, values all|outgoing|offer | all: Incoming and outgoing calls; outgoing: Outgoing calls only; offer: One pending incoming call |
video | object, nullable, rejects unknown fields | Video codecs and bounds this client supports. Omitted for audio-only clients. |
video.maxFps | integer, nullable, min 0, max 255, format uint8 | Maximum frame rate in frames per second. Omitted when no cap is specified. |
video.maxHeight | integer, nullable, min 0, max 65535, format uint16 | Maximum frame height in pixels. Omitted when no cap is specified. |
video.maxWidth | integer, nullable, min 0, max 65535, format uint16 | Maximum frame width in pixels. Omitted when no cap is specified. |
video.receiveCodecs | array of string, default [] | Video codecs deliverable to a receiving client, in preference order. |
video.receiveCodecs[] | string, values h265|h264|jpeg | Video codec exchanged on a call media track. |
video.sendCodecs | array of string, default [] | Video codecs accepted from a sending client, in preference order. |
video.sendCodecs[] | string, values h265|h264|jpeg | Video codec exchanged on a call media track. |
call.reject
Reject the incoming call. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the offered call. |
expectedRevision | integer, required, min 0, format uint32 | The latest offer revision you received. A stale revision is rejected. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
call.watch
Say whether you are watching the video you receive. Watching is on for every call until you turn it off. While it is off, the daemon doesn’t decode or deliver video and asks for less of it; audio and your camera are unaffected. Turning it on again asks for a full picture. Daemons older than 3.6.0 don’t know this command and close the socket, which ends your call. (message, socket control, rejects unknown fields)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
enabled | boolean, required | True to watch, false to stop watching. |
requestId | string, required | Your ID for this command. The command.result repeats it. |
trackId | integer, nullable, min 0, format uint32 | The receive video track this applies to. Omitted means every track, including those added later, and replaces what you set for single tracks. |
Attach the socket to a call you own. Send it first, within five seconds of connecting; the daemon answers media.ready. (message, socket media, rejects unknown fields)
| Field | Type | Description |
|---|
clientId | string, required | The clientId from the control socket’s hello. |
maxSyncSkewMs | integer, nullable, min 0, format uint32 | Maximum audio/video arrival skew in milliseconds absorbed in shared_clock mode (0..=1000, default 400). Valid only when mediaSync is set on call protocol v4+. |
mediaSync | string, nullable, values shared_clock | Optional cross-stream audio/video pacing mode (call protocol v4+). Omit for ordinary live microphone and camera calls. |
ownerToken | string, required | The secret ownerToken from the command.result that claimed the call. Do not log it. |
supportedProtocolVersions | array of integer, required, items min 0, items format uint32 | The protocol versions you support. |
track.start
Start sending media on one of your send tracks for a generation. Send it before the first binary frame, and again after each new generation. (message, socket media, rejects unknown fields)
| Field | Type | Description |
|---|
generation | integer, required, min 0, format uint32 | The generation to start. |
trackId | integer, required, min 0, format uint32 | The send track’s ID. |
video.request_keyframe
Ask the remote sender of a receive video track to emit a fresh keyframe. (message, socket media, rejects unknown fields)
| Field | Type | Description |
|---|
trackId | integer, required, min 0, format uint32 | The receive video track’s ID. |
Messages the daemon sends
call.control
The other party of a direct call changed a control, such as muting their microphone. It needs no reply. (message, socket control)
| Field | Type | Description |
|---|
callId | string, required | ID of the direct call. |
control | object, required | The control and its new value. |
control.enabled | boolean, required, when kind camera | True when the camera is sending video. |
control.kind | string, required, values microphone|camera | microphone: The participant’s microphone; camera: The participant’s camera |
control.muted | boolean, required, when kind microphone | True when the microphone is muted. |
participantId | string, required | The contact whose control changed. |
call.error
A failure that is not tied to a command, such as an invalid message or a missing permission. The daemon then closes the socket, except for outcome_unknown, which follows hello and leaves it open. (message, sockets control|media)
| Field | Type | Description |
|---|
code | string, required, values invalid_request|busy|already_claimed|offer_expired|not_owner|unsupported|media_not_ready|outcome_unknown|capacity|stale|forbidden|closed | What went wrong. |
call.invitation_result
The outcome of each invited contact for a create or invite command, sent to the call’s owner. (message, socket control)
| Field | Type | Description |
|---|
callId | string, required | ID of the conference call. |
requestId | string, required | The requestId of the create or invite command. |
results | array of object, required | One result per invited contact. |
results[] | object | The outcome of inviting one contact. It does not mean the contact joined. |
results[].contactId | string, required | The contact this result is for. |
results[].serviceCode | integer, nullable, min 0, format uint32 | The code the service returned. Omitted when unavailable. |
results[].status | string, required, values submitted|rejected|unknown|uncertain | What happened to the invitation. |
results[].verificationRequired | boolean, required | True when the service asked for a verification step. The event carries no verification link. |
call.offered
An incoming call that can be answered or rejected now. (message, socket control)
| Field | Type | Description |
|---|
offer | object, required | The offer. Send its revision in call.answer or call.reject. |
offer.callId | string, required | ID of the offered call. |
offer.callType | string, required, values voice|video | Whether the call is voice or video. |
offer.callerId | string, required | Contact ID of the caller. |
offer.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
offer.revision | integer, required, min 0, format uint32 | Increases when the offer changes. Send the latest value as expectedRevision when answering or rejecting. |
call.peer_status
The other party of a direct call changed signaling status, such as acknowledging ringing, joining, rejecting, being busy, not answering, or leaving. It needs no reply. (message, socket control)
| Field | Type | Description |
|---|
callId | string, required | ID of the direct call. |
participantId | string, required | Contact ID of the other party. |
status | object, required | Signaling status reported by the service. |
status.code | integer, required, min 0, format uint32 | The status number the service reported. Keep it for codes kind does not name. |
status.kind | string, required, values undefined|joined|invited|acknowledged|left|cancelled|busy|rejected|no_response|unknown | What the code means. |
call.pending
An incoming call that cannot be answered yet, or null when none is pending. (message, socket control)
| Field | Type | Description |
|---|
offer | object, required, nullable | The pending call, or null to clear it. |
offer.callId | string, required | ID of the incoming call. |
offer.callType | string, required, values voice|video | Whether the call is voice or video. |
offer.callerId | string, required | Contact ID of the caller. |
offer.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
offer.phase | string, required, values waiting_for_ready|preparing | What the call is waiting for. |
offer.revision | integer, required, min 0, format uint32 | Increases when the offer changes. |
call.state
The call changed. Sent to every client of the same account. (message, socket control)
| Field | Type | Description |
|---|
call | object, required | The call as it is now. |
call.callId | string, required | ID of the call. |
call.callType | string, required, values voice|video | Whether the call is voice or video. |
call.controls | array of object | The latest controls reported by the other party of a direct call, also given to a newly connected observer. Omitted until one is reported. |
call.controls[] | object | A control reported by one participant. |
call.controls[].control | object, required | The control and its value. |
call.controls[].control.enabled | boolean, required, when kind camera | True when the camera is sending video. |
call.controls[].control.kind | string, required, values microphone|camera | microphone: The participant’s microphone; camera: The participant’s camera |
call.controls[].control.muted | boolean, required, when kind microphone | True when the microphone is muted. |
call.controls[].participantId | string, required | The participant the control belongs to. In a direct call this is the contact ID. |
call.direction | string, required, values incoming|outgoing | Whether this account placed the call or received it. |
call.groupId | string, nullable | The group of a conference call. Omitted for a direct call. |
call.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
call.ownedByThisClient | boolean, required | True when this connection owns the call. Always false in HTTP snapshots. |
call.participants | array of object | The latest conference roster. Omitted for a direct call. |
call.participants[] | object | One participant in a conference call. |
call.participants[].cameraEnabled | boolean, nullable | Whether the participant’s camera is on. Omitted until the server reports it; an omitted value is unknown, not false. |
call.participants[].contactId | string, required | Contact ID of the participant. |
call.participants[].membership | string, required, values joined|invited|left|unknown | Whether the participant is in the room. |
call.participants[].microphoneEnabled | boolean, nullable | Whether the participant’s microphone is on. Omitted until the server reports it; an omitted value is unknown, not false. |
call.participants[].participantId | string, required | ID of the participant within this call. It is not a contact ID; use it to match audio tracks to participants. |
call.participants[].status | object, nullable | Signaling progress, separate from membership. Omitted until reported. |
call.participants[].status.code | integer, required, min 0, format uint32 | The status number the service reported. Keep it for codes kind does not name. |
call.participants[].status.kind | string, required, values undefined|joined|invited|acknowledged|left|cancelled|busy|rejected|no_response|unknown | What the code means. |
call.revision | integer, required, min 0, format uint32 | Increases each time the call changes. Send the latest value as expectedRevision. |
call.state | string, required, values offered|dialing|ringing|connecting|connected|ending|ended|uncertain | Where the call is in its life. |
calls.availability
Whether this account is in a call changed. (message, socket control)
| Field | Type | Description |
|---|
availability | object, required | The new availability. |
availability.busy | boolean, required | True while this account has a call, including one whose outcome is unresolved, so a new call cannot start. |
availability.ownedByThisClient | boolean, required | True when this connection owns that call. |
command.result
The result of a command, matched to it by requestId. Acceptance starts the operation; it does not mean the call connected. (message, socket control)
| Field | Type | Description |
|---|
callId | string, required, nullable | The call the command claimed. Null unless it was a dial, answer or join that succeeded. |
code | string, required, nullable, values invalid_request|busy|already_claimed|offer_expired|not_owner|unsupported|media_not_ready|outcome_unknown|capacity|stale|forbidden|closed | Why the command failed. Null unless status is error. |
ownerToken | string, required, nullable | Secret token for media.attach on the claimed call. Null unless a call was claimed. Do not log it. |
requestId | string, required | The requestId of the command. |
status | string, required, values accepted|replayed|error | Whether the command was accepted, repeated or rejected. |
conference.invitations
Replaces the list of conference calls this account can join. An empty list clears it. (message, socket control)
| Field | Type | Description |
|---|
invitations | array of object, required | The current invitations. |
invitations[] | object | A conference call this account can join. It carries no room credentials. |
invitations[].callerId | string, required | Contact ID of the caller. |
invitations[].groupId | string, required | The group the conference call is in. |
invitations[].invitationId | string, required | Opaque ID for this account. Send it in call.join. |
invitations[].revision | integer, required, min 0, format uint32 | Revision of the invitation. Send it in call.join exactly as listed. |
hello
The first event on the control socket: this connection’s ID and the current calling state. Check protocolVersion before sending commands. (message, socket control)
| Field | Type | Description |
|---|
audioFormat | object, required | The PCM format used for call audio. |
audioFormat.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
audioFormat.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
audioFormat.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
availability | object, required | Whether this account is in a call. |
availability.busy | boolean, required | True while this account has a call, including one whose outcome is unresolved, so a new call cannot start. |
availability.ownedByThisClient | boolean, required | True when this connection owns that call. |
capabilities | object, required | Calling operations that are available. |
capabilities.conferenceAudio | boolean | Audio in conference calls is available. |
capabilities.conferenceCreate | boolean | Starting a conference call in a group is available. |
capabilities.conferenceInvite | boolean | Inviting more contacts into a connected conference call is available. |
capabilities.conferenceJoin | boolean | Joining a conference call from an invitation is available. |
capabilities.conferenceVideo | boolean | Video in conference calls is available. |
capabilities.directAudio | boolean | Direct voice calls with one contact are available. |
capabilities.directVideo | boolean | Direct video calls are available. |
clientId | string, required | ID of this connection. Send it as clientId in media.attach. |
conferenceInvitations | array of object, required | Conference calls this account can join. |
conferenceInvitations[] | object | A conference call this account can join. It carries no room credentials. |
conferenceInvitations[].callerId | string, required | Contact ID of the caller. |
conferenceInvitations[].groupId | string, required | The group the conference call is in. |
conferenceInvitations[].invitationId | string, required | Opaque ID for this account. Send it in call.join. |
conferenceInvitations[].revision | integer, required, min 0, format uint32 | Revision of the invitation. Send it in call.join exactly as listed. |
currentCall | object, required, nullable | The active call, or null. |
currentCall.callId | string, required | ID of the call. |
currentCall.callType | string, required, values voice|video | Whether the call is voice or video. |
currentCall.controls | array of object | The latest controls reported by the other party of a direct call, also given to a newly connected observer. Omitted until one is reported. |
currentCall.controls[] | object | A control reported by one participant. |
currentCall.controls[].control | object, required | The control and its value. |
currentCall.controls[].control.enabled | boolean, required, when kind camera | True when the camera is sending video. |
currentCall.controls[].control.kind | string, required, values microphone|camera | microphone: The participant’s microphone; camera: The participant’s camera |
currentCall.controls[].control.muted | boolean, required, when kind microphone | True when the microphone is muted. |
currentCall.controls[].participantId | string, required | The participant the control belongs to. In a direct call this is the contact ID. |
currentCall.direction | string, required, values incoming|outgoing | Whether this account placed the call or received it. |
currentCall.groupId | string, nullable | The group of a conference call. Omitted for a direct call. |
currentCall.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
currentCall.ownedByThisClient | boolean, required | True when this connection owns the call. Always false in HTTP snapshots. |
currentCall.participants | array of object | The latest conference roster. Omitted for a direct call. |
currentCall.participants[] | object | One participant in a conference call. |
currentCall.participants[].cameraEnabled | boolean, nullable | Whether the participant’s camera is on. Omitted until the server reports it; an omitted value is unknown, not false. |
currentCall.participants[].contactId | string, required | Contact ID of the participant. |
currentCall.participants[].membership | string, required, values joined|invited|left|unknown | Whether the participant is in the room. |
currentCall.participants[].microphoneEnabled | boolean, nullable | Whether the participant’s microphone is on. Omitted until the server reports it; an omitted value is unknown, not false. |
currentCall.participants[].participantId | string, required | ID of the participant within this call. It is not a contact ID; use it to match audio tracks to participants. |
currentCall.participants[].status | object, nullable | Signaling progress, separate from membership. Omitted until reported. |
currentCall.participants[].status.code | integer, required, min 0, format uint32 | The status number the service reported. Keep it for codes kind does not name. |
currentCall.participants[].status.kind | string, required, values undefined|joined|invited|acknowledged|left|cancelled|busy|rejected|no_response|unknown | What the code means. |
currentCall.revision | integer, required, min 0, format uint32 | Increases each time the call changes. Send the latest value as expectedRevision. |
currentCall.state | string, required, values offered|dialing|ringing|connecting|connected|ending|ended|uncertain | Where the call is in its life. |
currentOffer | object, required, nullable | The incoming call that can be answered now, or null. |
currentOffer.callId | string, required | ID of the offered call. |
currentOffer.callType | string, required, values voice|video | Whether the call is voice or video. |
currentOffer.callerId | string, required | Contact ID of the caller. |
currentOffer.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
currentOffer.revision | integer, required, min 0, format uint32 | Increases when the offer changes. Send the latest value as expectedRevision when answering or rejecting. |
currentPendingOffer | object, required, nullable | An incoming call that cannot be answered yet, or null. |
currentPendingOffer.callId | string, required | ID of the incoming call. |
currentPendingOffer.callType | string, required, values voice|video | Whether the call is voice or video. |
currentPendingOffer.callerId | string, required | Contact ID of the caller. |
currentPendingOffer.kind | string, required, values direct|conference | Whether the call is direct or a conference. |
currentPendingOffer.phase | string, required, values waiting_for_ready|preparing | What the call is waiting for. |
currentPendingOffer.revision | integer, required, min 0, format uint32 | Increases when the offer changes. |
protocolVersion | integer, required, min 0, format uint32 | The protocol version the daemon speaks on this socket. |
videoCapabilities | object, nullable | Video codecs and bounds this daemon can exchange. Omitted when video is unavailable. |
videoCapabilities.maxFps | integer, nullable, min 0, max 255, format uint8 | Maximum frame rate in frames per second. Omitted when no cap is specified. |
videoCapabilities.maxHeight | integer, nullable, min 0, max 65535, format uint16 | Maximum frame height in pixels. Omitted when no cap is specified. |
videoCapabilities.maxWidth | integer, nullable, min 0, max 65535, format uint16 | Maximum frame width in pixels. Omitted when no cap is specified. |
videoCapabilities.receiveCodecs | array of string, required | Video codecs deliverable to a receiving client, in preference order. |
videoCapabilities.receiveCodecs[] | string, values h265|h264|jpeg | Video codec exchanged on a call media track. |
videoCapabilities.sendCodecs | array of string, required | Video codecs accepted from a sending client, in preference order. |
videoCapabilities.sendCodecs[] | string, values h265|h264|jpeg | Video codec exchanged on a call media track. |
Sent on the media socket after media.attach succeeds: the audio and video tracks to use. (message, socket media)
| Field | Type | Description |
|---|
protocolVersion | integer, required, min 0, format uint32 | The protocol version the daemon speaks on the media socket. |
receiveTracks | array of object, required | The tracks for media you receive, one per audio or video source. |
receiveTracks[] | object | One audio or video stream: a track you send, or one source you receive. |
receiveTracks[].active | boolean, required, when media video | True when this video track is currently active. |
receiveTracks[].direction | string, required, values send|receive | Whether you send or receive media on this track. |
receiveTracks[].generation | integer, required, min 0, format uint32 | Version of the stream. Frames for an older generation are discarded; a new generation starts after call.clear_audio, call.clear_video, a mute change, a camera toggle, or a format change. |
receiveTracks[].id | integer, required, min 0, format uint32 | Track ID to use in track.start, video.request_keyframe and binary WXCM frames. |
receiveTracks[].media | string, required, values audio|video | audio: One PCM audio stream; video: One video stream |
receiveTracks[].participantId | string, nullable | The conference participant this track carries. Omitted when the track is not tied to a participant. |
receiveTracks[][audio].format | object, required, when media audio | The PCM format of the track. |
receiveTracks[][audio].format.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
receiveTracks[][audio].format.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
receiveTracks[][audio].format.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
receiveTracks[][video].format | object, required, when media video | The negotiated video codec, mode and bounds of the track. |
receiveTracks[][video].format.bitrateKbps | integer, nullable, min 0, format uint32 | Target bitrate in kbps when encoding or transcoding. Omitted for pass-through or JPEG. |
receiveTracks[][video].format.codec | string, required, values h265|h264|jpeg | Codec carried on this track. |
receiveTracks[][video].format.maxFps | integer, required, min 0, max 255, format uint8 | Maximum frame rate in frames per second for this track. |
receiveTracks[][video].format.maxHeight | integer, required, min 0, max 65535, format uint16 | Maximum frame height in pixels for this track. |
receiveTracks[][video].format.maxWidth | integer, required, min 0, max 65535, format uint16 | Maximum frame width in pixels for this track. |
receiveTracks[][video].format.mode | string, required, values passthrough|transcoded | Whether this track passes wire frames straight through or transcodes them. |
sendTracks | array of object, required | The tracks for media you send (audio, plus video when negotiated). |
sendTracks[] | object | One audio or video stream: a track you send, or one source you receive. |
sendTracks[].active | boolean, required, when media video | True when this video track is currently active. |
sendTracks[].direction | string, required, values send|receive | Whether you send or receive media on this track. |
sendTracks[].generation | integer, required, min 0, format uint32 | Version of the stream. Frames for an older generation are discarded; a new generation starts after call.clear_audio, call.clear_video, a mute change, a camera toggle, or a format change. |
sendTracks[].id | integer, required, min 0, format uint32 | Track ID to use in track.start, video.request_keyframe and binary WXCM frames. |
sendTracks[].media | string, required, values audio|video | audio: One PCM audio stream; video: One video stream |
sendTracks[].participantId | string, nullable | The conference participant this track carries. Omitted when the track is not tied to a participant. |
sendTracks[][audio].format | object, required, when media audio | The PCM format of the track. |
sendTracks[][audio].format.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
sendTracks[][audio].format.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
sendTracks[][audio].format.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
sendTracks[][video].format | object, required, when media video | The negotiated video codec, mode and bounds of the track. |
sendTracks[][video].format.bitrateKbps | integer, nullable, min 0, format uint32 | Target bitrate in kbps when encoding or transcoding. Omitted for pass-through or JPEG. |
sendTracks[][video].format.codec | string, required, values h265|h264|jpeg | Codec carried on this track. |
sendTracks[][video].format.maxFps | integer, required, min 0, max 255, format uint8 | Maximum frame rate in frames per second for this track. |
sendTracks[][video].format.maxHeight | integer, required, min 0, max 65535, format uint16 | Maximum frame height in pixels for this track. |
sendTracks[][video].format.maxWidth | integer, required, min 0, max 65535, format uint16 | Maximum frame width in pixels for this track. |
sendTracks[][video].format.mode | string, required, values passthrough|transcoded | Whether this track passes wire frames straight through or transcodes them. |
participant.updated
A conference participant’s membership or microphone changed. A call.state with the new roster follows. (message, socket control)
| Field | Type | Description |
|---|
callId | string, required | ID of the conference call. |
participant | object, required | The participant as it is now. |
participant.cameraEnabled | boolean, nullable | Whether the participant’s camera is on. Omitted until the server reports it; an omitted value is unknown, not false. |
participant.contactId | string, required | Contact ID of the participant. |
participant.membership | string, required, values joined|invited|left|unknown | Whether the participant is in the room. |
participant.microphoneEnabled | boolean, nullable | Whether the participant’s microphone is on. Omitted until the server reports it; an omitted value is unknown, not false. |
participant.participantId | string, required | ID of the participant within this call. It is not a contact ID; use it to match audio tracks to participants. |
participant.status | object, nullable | Signaling progress, separate from membership. Omitted until reported. |
participant.status.code | integer, required, min 0, format uint32 | The status number the service reported. Keep it for codes kind does not name. |
participant.status.kind | string, required, values undefined|joined|invited|acknowledged|left|cancelled|busy|rejected|no_response|unknown | What the code means. |
revision | integer, required, min 0, format uint32 | The call revision after this change. |
protocol.error
The protocol version could not be agreed. The daemon then closes the socket with WebSocket code 1002. (message, sockets control|media)
| Field | Type | Description |
|---|
clientVersions | array of integer, required, items min 0, items format uint32 | The versions the client announced. Empty when the list was invalid. |
code | string, required, values unsupported_protocol_version|invalid_protocol_version | Why the versions were refused. |
serverVersions | array of integer, required, items min 0, items format uint32 | The versions the daemon supports. |
track.added
A receive audio or video track appeared. Frames for it follow. (message, sockets control|media)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
track | object, required | The new track. |
track.active | boolean, required, when media video | True when this video track is currently active. |
track.direction | string, required, values send|receive | Whether you send or receive media on this track. |
track.generation | integer, required, min 0, format uint32 | Version of the stream. Frames for an older generation are discarded; a new generation starts after call.clear_audio, call.clear_video, a mute change, a camera toggle, or a format change. |
track.id | integer, required, min 0, format uint32 | Track ID to use in track.start, video.request_keyframe and binary WXCM frames. |
track.media | string, required, values audio|video | audio: One PCM audio stream; video: One video stream |
track.participantId | string, nullable | The conference participant this track carries. Omitted when the track is not tied to a participant. |
track[audio].format | object, required, when media audio | The PCM format of the track. |
track[audio].format.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
track[audio].format.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
track[audio].format.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
track[video].format | object, required, when media video | The negotiated video codec, mode and bounds of the track. |
track[video].format.bitrateKbps | integer, nullable, min 0, format uint32 | Target bitrate in kbps when encoding or transcoding. Omitted for pass-through or JPEG. |
track[video].format.codec | string, required, values h265|h264|jpeg | Codec carried on this track. |
track[video].format.maxFps | integer, required, min 0, max 255, format uint8 | Maximum frame rate in frames per second for this track. |
track[video].format.maxHeight | integer, required, min 0, max 65535, format uint16 | Maximum frame height in pixels for this track. |
track[video].format.maxWidth | integer, required, min 0, max 65535, format uint16 | Maximum frame width in pixels for this track. |
track[video].format.mode | string, required, values passthrough|transcoded | Whether this track passes wire frames straight through or transcodes them. |
track.removed
A receive track ended. Frames for that generation stop. (message, sockets control|media)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
generation | integer, required, min 0, format uint32 | The generation that ended. |
reason | string, required | Why the track ended. Currently source_unavailable. |
trackId | integer, required, min 0, format uint32 | ID of the track that ended. |
track.updated
A track moved to a new generation or state, for example after call.clear_audio, call.clear_video, a mute change, or call.camera. Send new frames on the new generation. (message, sockets control|media)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
track | object, required | The track with its new generation or state. |
track.active | boolean, required, when media video | True when this video track is currently active. |
track.direction | string, required, values send|receive | Whether you send or receive media on this track. |
track.generation | integer, required, min 0, format uint32 | Version of the stream. Frames for an older generation are discarded; a new generation starts after call.clear_audio, call.clear_video, a mute change, a camera toggle, or a format change. |
track.id | integer, required, min 0, format uint32 | Track ID to use in track.start, video.request_keyframe and binary WXCM frames. |
track.media | string, required, values audio|video | audio: One PCM audio stream; video: One video stream |
track.participantId | string, nullable | The conference participant this track carries. Omitted when the track is not tied to a participant. |
track[audio].format | object, required, when media audio | The PCM format of the track. |
track[audio].format.channels | integer, required, min 0, max 255, format uint8 | Number of interleaved channels. |
track[audio].format.frameMs | integer, required, min 0, max 65535, format uint16 | Length of one audio frame in milliseconds. |
track[audio].format.sampleRate | integer, required, min 0, format uint32 | Samples per second, per channel. |
track[video].format | object, required, when media video | The negotiated video codec, mode and bounds of the track. |
track[video].format.bitrateKbps | integer, nullable, min 0, format uint32 | Target bitrate in kbps when encoding or transcoding. Omitted for pass-through or JPEG. |
track[video].format.codec | string, required, values h265|h264|jpeg | Codec carried on this track. |
track[video].format.maxFps | integer, required, min 0, max 255, format uint8 | Maximum frame rate in frames per second for this track. |
track[video].format.maxHeight | integer, required, min 0, max 65535, format uint16 | Maximum frame height in pixels for this track. |
track[video].format.maxWidth | integer, required, min 0, max 65535, format uint16 | Maximum frame width in pixels for this track. |
track[video].format.mode | string, required, values passthrough|transcoded | Whether this track passes wire frames straight through or transcodes them. |
video.keyframe_requested
Sent on the media socket when the remote party asks your video encoder for a fresh keyframe (IDR with inline parameter sets). (message, socket media)
| Field | Type | Description |
|---|
callId | string, required | ID of the call. |
generation | integer, required, min 0, format uint32 | Generation of your outgoing video track. |
trackId | integer, required, min 0, format uint32 | ID of your outgoing video track. |