Skip to content

Channels

Channels are named topics that events are published to and consumed from. Channel IDs are URL-safe slugs: lowercase alphanumeric characters and hyphens, 3-64 characters long.

GET /api/v1/channels

Returns channels visible to the caller. Without auth, only public channels are returned. With a token, private channels matching the token’s scopes are also included. Admin tokens see all channels.

200 OK

{
"channels": [
{
"id": "market-signals",
"name": "Market Signals",
"description": "Real-time trading signals",
"tags": ["finance", "trading"],
"is_public": true,
"event_count": 1420,
"last_event_at": "2025-01-15T09:30:00Z",
"created_at": "2025-01-01T00:00:00Z",
"meta": null
}
]
}
POST /api/v1/channels

Creates a new channel and returns a scoped token for publishing and subscribing.

Admin token required.

FieldTypeRequiredDescription
idstringYesChannel ID. 3-64 chars, lowercase alphanumeric + hyphens.
namestringYesHuman-readable display name.
descriptionstringNoChannel description.
tagsstring[]NoTags for categorization.
is_publicbooleanNoWhether the channel is publicly readable. Defaults to true.
configobjectNoChannel configuration. Set config.strict_types: true to enforce schema validation, and define schemas in config.types.
metaobjectNoChannel metadata (display settings, runtime state). Never validated by the server.

201 Created

{
"id": "market-signals",
"token": "eyJhbGciOiJFZERTQSIs..."
}
StatusCondition
400Invalid channel ID format.
400config.strict_types: true without config.types.
409Channel with this ID already exists.
PATCH /api/v1/channels/:channelId

Updates an existing channel. Only provided fields are modified.

Admin token required.

ParamTypeDescription
channelIdstringChannel ID.

All fields are optional. Only include the fields you want to change.

FieldTypeDescription
namestringDisplay name.
descriptionstringChannel description.
tagsstring[]Tags for categorization.
is_publicbooleanPublic visibility.
configobjectChannel configuration (includes strict_types, types, storage).

200 OK

{
"id": "market-signals",
"name": "Market Signals (Updated)",
"description": "Real-time trading signals from multiple sources",
"tags": ["finance", "trading", "crypto"],
"is_public": true,
"config": null
}
StatusCondition
404Channel not found.
PATCH /api/v1/channels/:channelId/meta

Performs a shallow merge on the channel’s meta field. Setting a key to null deletes it.

Admin token required.

ParamTypeDescription
channelIdstringChannel ID.

A JSON object of key-value pairs to merge into the existing meta:

{
"display_order": 1,
"icon": "chart"
}

To remove a key, set it to null:

{
"icon": null
}

200 OK

Returns the full updated meta object.

StatusCondition
404Channel not found.
DELETE /api/v1/channels/:channelId

Permanently deletes a channel and all its events, webhooks, and subscriptions.

Admin token required.

ParamTypeDescription
channelIdstringChannel ID.

204 No Content

No response body.

StatusCondition
404Channel not found.