Skip to main content

Channels API

Retrieve channel connection status and activity metrics from the OpenClaw gateway.

List channels

GET /api/channels
Requires session authentication. Returns the status of all messaging channels based on real-time gateway session data. The endpoint queries the gateway for active sessions and infers channel status from session keys. Webchat status is determined by gateway health, while other channels (Telegram, Discord, WhatsApp) are marked as connected when sessions with matching keys exist.

Response

{
  "channels": [
    {
      "name": "Webchat",
      "provider": "webchat",
      "status": "connected",
      "lastActive": "2026-03-30T01:00:00Z",
      "messages": 42
    },
    {
      "name": "Telegram",
      "provider": "telegram",
      "status": "connected",
      "lastActive": "2026-03-30T00:45:00Z",
      "messages": 15
    },
    {
      "name": "Discord",
      "provider": "discord",
      "status": "not-configured",
      "lastActive": null,
      "messages": 0
    },
    {
      "name": "WhatsApp",
      "provider": "whatsapp",
      "status": "not-configured",
      "lastActive": null,
      "messages": 0
    }
  ],
  "gatewayHealth": "healthy",
  "source": "gateway"
}

Channel object

FieldTypeDescription
namestringDisplay name of the channel
providerstringChannel identifier: webchat, telegram, discord, or whatsapp
statusstringConnection status (see table below)
lastActivestring | nullISO 8601 timestamp of the most recent activity on this channel, or null if no activity
messagesnumberTotal message count across all sessions for this channel

Channel statuses

StatusCondition
connectedChannel has active sessions or (for webchat) the gateway is healthy
not-configuredNo sessions found for this channel
unreachableGateway health check failed (webchat only)

Response fields

FieldTypeDescription
channelsarrayList of channel objects
gatewayHealthstringOverall gateway health: healthy or unreachable
sourcestringAlways gateway

Errors

CodeDescription
401Unauthorized — no valid session

Example

curl -X GET https://agentbot.raveculture.xyz/api/channels \
  -H "Cookie: next-auth.session-token=YOUR_SESSION"