Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.cline.bot/llms.txt

Use this file to discover all available pages before exploring further.

This feature currently only applies to Cline CLI.
Connectors let you chat with your agent from messaging platforms. Each incoming message creates or continues an agent session, and the agent’s response is sent back to the conversation.

Setup Wizard

Run cline connect to open an interactive wizard that guides you through platform selection, credential entry, security configuration, and advanced options (provider, model, system prompt, agent mode).
cline connect

Supported Platforms

PlatformDirect CommandRequired Credentials
Telegramcline connect telegramBot username, bot token
Slackcline connect slackBot token, signing secret, base URL
Discordcline connect discordApplication ID, bot token, public key, base URL
Google Chatcline connect gchatService account credentials JSON, base URL
WhatsAppcline connect whatsappPhone number ID, access token, app secret, verify token, base URL
Linearcline connect linearAPI key, webhook signing secret, base URL

Telegram

1

Create a Telegram bot

Open Telegram and start a chat with @BotFather. Send /newbot and follow the prompts:
  1. Enter a display name (e.g., “Cline”)
  2. Enter a username ending in bot (e.g., cline_myname_bot). Must be unique across Telegram.
  3. BotFather responds with your bot token (looks like 7123456789:AAH...)
2

Start the connector

cline connect telegram -m <BOT-USERNAME> -k <BOT-TOKEN>
3

Chat with your bot

Open Telegram, search for your bot’s username, and send a message. The agent processes it and replies in the chat.

Security

By default, anyone who finds your bot can message it and it will execute tasks on your machine. Lock it down with the --hook-command flag.
1

Get your Telegram user ID

Message @userinfobot on Telegram. It replies with your user ID immediately.
2

Start with access control

Replace 12345 with your actual Telegram user ID:
cline connect telegram -m <BOT-USERNAME> -k <BOT-TOKEN> \
  --hook-command 'jq -r ".payload.actor.participantKey" | grep -q "telegram:id:12345" && echo "{\"action\":\"allow\"}" || echo "{\"action\":\"deny\",\"message\":\"unauthorized\"}"'
The --hook-command receives each incoming message with sender info via stdin. Your script returns {"action": "allow"} or {"action": "deny", "message": "reason"}. Without --hook-command, everything is auto-approved.

Slack

Requires a bot token, signing secret, and public base URL.
cline connect slack --token <BOT-TOKEN> --signing-secret <SECRET> --base-url <URL>
Each Slack thread maps to an agent session, so the agent maintains conversation context within a thread.

Discord

Requires an application ID, bot token, public key, and public base URL.
cline connect discord --app-id <ID> --token <TOKEN> --public-key <KEY> --base-url <URL>

Google Chat

Requires a service account credentials JSON file and public base URL.
cline connect gchat --credentials <JSON> --base-url <URL>

WhatsApp

Requires a phone number ID, access token, app secret, webhook verify token, and public base URL.
cline connect whatsapp --phone-id <ID> --token <TOKEN> --app-secret <SECRET> --base-url <URL>

Linear

Requires an API key, webhook signing secret, and public base URL.
cline connect linear --api-key <KEY> --signing-secret <SECRET> --base-url <URL>

Managing Connectors

# Stop all connectors
cline connect --stop

# Stop a specific connector
cline connect telegram --stop

Hook Command Protocol

The --hook-command pattern works across all connectors. The script receives a JSON payload via stdin:
{
  "payload": {
    "actor": {
      "participantKey": "telegram:id:12345",
      "displayName": "User Name"
    },
    "message": "The incoming message text"
  }
}
Return {"action": "allow"} or {"action": "deny", "message": "reason"}.

Running Multiple Connectors

Multiple connectors can run simultaneously. They all share the same hub:
# Terminal 1
cline connect telegram -m my_bot -k $TELEGRAM_TOKEN

# Terminal 2
cline connect slack --token $SLACK_TOKEN --signing-secret $SECRET --base-url $URL
Connectors require the hub. Start it with cline hub start if it doesn’t auto-start.