Open channel metadata update
The open_channel:metadata_update event fires when a key-value metadata attribute on an open channel is set, updated, or deleted. Use this event to keep open channel metadata in sync on your app server.
For the complete webhook setup and signature verification guide, see Webhooks overview.
Event type
open_channel:metadata_update
Payload
Envelope
| Field | Type | Required | Description |
|---|---|---|---|
type | String | Yes | "open_channel:metadata_update" |
id | String | Yes | Unique event ID. |
time | Long | Yes | Event generation time (Unix ms). |
data | Array | Yes | Array containing one metadata update object. See Data fields. |
Data fields
| Field | Type | Required | Description |
|---|---|---|---|
channelId | String | Yes | The open channel ID. |
key | String | Yes | The metadata attribute key. |
value | String | No | The attribute value. Not present when operationType is 3 (delete all). |
operationType | Int | Yes | Operation type. See Operation types. |
userId | String | Yes | The user ID of the person who performed the operation. |
time | Long | Yes | Time the operation was performed (Unix ms). |
version | Long | No | Attribute version number. Monotonically increasing; use this field to order or deduplicate events received out of sequence. |
Operation types
| Value | Meaning |
|---|---|
1 | Set — The attribute was created or updated. value contains the new value. |
2 | Delete single — The attribute identified by key was deleted. value is not included. |
3 | Delete all — All metadata attributes for the channel were deleted. key and value may not reflect a specific attribute. |
Example
JSON
{
"type": "open_channel:metadata_update",
"id": "550e8400-e29b-41d4-a716-446655440012",
"time": 1730192400000,
"data": [
{
"channelId": "chatroom_001",
"key": "topic",
"value": "Tech",
"operationType": 1,
"userId": "user_001",
"time": 1730192400000,
"version": 2
}
]
}