Docs / BrainClaw / Chat Platforms / Telegram

Chat Platforms

Connect Telegram

Create a Telegram bot with @BotFather and connect it to BrainClaw. It takes about two minutes — no server, no admin access.

Before you start

  • A running BrainClaw instance. Provision one from BrainClaw if you haven't already.
  • The Telegram app on your phone or desktop.
1

Open @BotFather in Telegram

In Telegram, search for @BotFather (the official bot with a blue verified checkmark) and open a chat with it. Tap Start.

2

Create a new bot

Send the command /newbot. BotFather will ask for:

  • A name — the display name shown in chats (e.g. “My BrainClaw”).
  • A username — must be unique and end in bot (e.g. my_brainclaw_bot).
3

Copy the bot token

BotFather replies with a token that looks like 123456789:ABCdefGhIJKlmNoPQRstUvWxYz.... Copy it. Keep it secret — anyone with this token can control your bot.

4

Paste the token into BrainClaw

In MegaBrain, open BrainClaw → Settings → Channels, choose Telegram, and paste the token into the Bot Token field. Click Save.

5

Redeploy your instance

Channel changes take effect on the next deploy. In Settings → Instance Controls, click Redeploy and wait for the instance to return to Running.

6

Say hi to your bot

Open your bot in Telegram (use the t.me/<your_bot_username> link BotFather gave you), tap Start, and send a message. BrainClaw will reply — it's the same agent and memory as your web chat.

Tips & troubleshooting

  • Token format. A valid token is digits, a colon, then 30–50 letters/numbers, like 123456789:ABCdef.... If BrainClaw rejects it, re-copy it from BotFather without extra spaces.
  • Rotate a leaked token. If your token is exposed, send /revoke to BotFather, get a new token, and paste it back into BrainClaw.
  • No reply? Make sure the instance is Running and that you clicked Redeploy after saving the token. Send /new in the chat to start a fresh session if needed.
  • Groups. To use the bot in a group, add it to the group; in BotFather you can adjust /setprivacy if you want it to see all messages.