Skip to main content

Connecting Telegram

Every Telegram bot needs a bot token, which you get from Telegram itself. This page walks you from zero to a live bot.

1. Get a token from @BotFather

  1. Open Telegram and search for @BotFather (the official bot, with a blue checkmark).
  2. Send /newbot.
  3. Choose a display name (e.g. My Quick Bot) and a username that ends in bot (e.g. my_quick_bot).
  4. BotFather replies with a token that looks like 123456789:AAExampleTokenStringHere.
danger

Your token is a secret. Anyone with it can control your bot. Never paste it into your .botgami source or share it. Botgami stores it securely when you connect.

2. Connect it in Botgami

  1. In your bot's workspace, open the Connect panel.
  2. Paste the token from BotFather.
  3. Click Connect.

Botgami validates the token, links your .botgami bot to that Telegram bot, and enables incoming updates. You don't choose between polling and webhooks — Botgami handles delivery for you. Just connect and enable.

3. Go live

Click Publish. Your bot is now live. Open it in Telegram (tap the t.me/your_bot_username link BotFather gave you) and send /start.

Optional BotFather polish

Back in @BotFather you can also:

  • /setdescription — text shown on the bot's profile and the "What can this bot do?" screen.
  • /setcommands — register your slash commands so they autocomplete in Telegram's UI. List them as command - description, e.g. start - Open the menu.
  • /setuserpic — set the bot's avatar.
tip

Registering commands with /setcommands only changes Telegram's UI hints. The flows that actually handle them are your flow ... on command "/..." definitions in Botgami.

Troubleshooting

  • Nothing happens on /start — make sure you clicked Publish after connecting, and that you have a flow ... on command "/start".
  • "Unauthorized" — the token is wrong or was revoked. Generate a fresh one with /token in @BotFather and reconnect.

Next