ChannelMessage envelope
Snapshot: 0.9.17-patch1 · selected operations. This is a stored schema reference, not a fresh export or confirmation of behavior in another release. Scope and availability.
WebSocket message envelope exchanged on /ws/session. Include the payload object matching the message type.
This snapshot leaves payload objects open with additionalProperties: true. It does not define every payload field or establish which runtime actions a deployment supports.
Required means required within its containing object. Exact schema below retains all constraints and alternatives.
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
type | string | Yes | Not described in snapshot. | enum: ["chat","browser_action","action","action_result","audio","status","control","reconnect","ping","pong","error"] |
sessionId | string | Yes | Not described in snapshot. | — |
messageId | string | Yes | Not described in snapshot. | format: "uuid" |
streamId | string | No | Redis stream id included on replayed runtime-to-browser messages. | — |
timestamp | number | Yes | Unix timestamp in milliseconds. | — |
direction | string | Yes | Not described in snapshot. | enum: ["to_browser","to_ari"] |
chat | object | No | Present when type is chat. | additionalProperties: true |
browserAction | object | No | Present when type is browser_action. | additionalProperties: true |
action | object | No | Present when type is action. | additionalProperties: true |
actionResult | object | No | Present when type is action_result. | additionalProperties: true |
audio | object | No | Present when type is audio. | additionalProperties: true |
status | object | No | Present when type is status. | additionalProperties: true |
control | object | No | Present when type is control; supports enable_text_chat and disable_text_chat commands. | additionalProperties: true |
reconnect | object | No | Present when type is reconnect. | additionalProperties: true |
error | object | No | Present when type is error. | additionalProperties: true |
Exact schema
{
"type": "object",
"description": "WebSocket message envelope exchanged on /ws/session. Include the payload object matching the message type.",
"required": [
"type",
"sessionId",
"messageId",
"timestamp",
"direction"
],
"properties": {
"type": {
"type": "string",
"enum": [
"chat",
"browser_action",
"action",
"action_result",
"audio",
"status",
"control",
"reconnect",
"ping",
"pong",
"error"
]
},
"sessionId": {
"type": "string"
},
"messageId": {
"type": "string",
"format": "uuid"
},
"streamId": {
"type": "string",
"description": "Redis stream id included on replayed runtime-to-browser messages."
},
"timestamp": {
"type": "number",
"description": "Unix timestamp in milliseconds."
},
"direction": {
"type": "string",
"enum": [
"to_browser",
"to_ari"
]
},
"chat": {
"type": "object",
"description": "Present when type is chat.",
"additionalProperties": true
},
"browserAction": {
"type": "object",
"description": "Present when type is browser_action.",
"additionalProperties": true
},
"action": {
"type": "object",
"description": "Present when type is action.",
"additionalProperties": true
},
"actionResult": {
"type": "object",
"description": "Present when type is action_result.",
"additionalProperties": true
},
"audio": {
"type": "object",
"description": "Present when type is audio.",
"additionalProperties": true
},
"status": {
"type": "object",
"description": "Present when type is status.",
"additionalProperties": true
},
"control": {
"type": "object",
"description": "Present when type is control; supports enable_text_chat and disable_text_chat commands.",
"additionalProperties": true
},
"reconnect": {
"type": "object",
"description": "Present when type is reconnect.",
"additionalProperties": true
},
"error": {
"type": "object",
"description": "Present when type is error.",
"additionalProperties": true
}
}
}
For token acquisition and the connection URL, see Request a session token.