Skip to main content
POST
/
v1
/
instances
/
{instance_id}
/
channels
/
{channel}
/
connect
curl -X POST https://api.chowder.dev/v1/instances/ins_abc123/channels/discord/connect \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "config": {
      "token": "MTIz..."
    }
  }'
{
  "channel": "discord",
  "status": "connected",
  "message": "Channel connected successfully."
}
Connects a channel to the instance. What happens next depends on the channel’s connection type:
  • Token-based channels (like Discord or Telegram): provide the required credentials in config and the channel connects immediately.
  • Interactive channels (like WhatsApp): the connection starts a pairing flow. You’ll get back QR data to scan, and the status will be "awaiting_scan" until the user completes the process.
Behind the scenes, this writes the configuration to openclaw.json and restarts the gateway.

Authentication

Requires an org-level API key or a scoped token with the channels permission.

Path Parameters

instance_id
string
required
The ID of the instance.
channel
string
required
The channel identifier (e.g. discord, whatsapp).

Body Parameters

config
object
required
A key-value map of configuration fields for this channel. Use the channel info endpoint to discover which fields are required. For interactive channels, you can optionally provide extra config.

Response

channel
string
The channel identifier.
status
string
Either "connected" (channel is live) or "awaiting_scan" (interactive channels waiting for user action).
qr_data
string
Raw QR code data for interactive channels. Only present when status is "awaiting_scan".
qr_image_base64
string
Base64-encoded PNG image of the QR code. Only present when status is "awaiting_scan".
message
string
An optional human-readable status message.
curl -X POST https://api.chowder.dev/v1/instances/ins_abc123/channels/discord/connect \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "config": {
      "token": "MTIz..."
    }
  }'
{
  "channel": "discord",
  "status": "connected",
  "message": "Channel connected successfully."
}