Machine’s Telegram Integration lets you connect any of your Machine agents to a Telegram bot. Once connected, anyone who messages your bot on Telegram will receive responses powered by your agent — complete with the model and instructions you’ve configured.
1
User sends message
User sends a message to your Telegram bot
2
Telegram webhooks to Machine
Telegram forwards the message to Machine via webhook
3
Routed to your Agent
Machine routes the message to your selected agent
4
Agent generates response
Your agent processes the message using its configured model and instructions
~2 minBotFather is Telegram’s official tool for creating and managing bots. Open Telegram and search for @BotFather (look for the blue verified checkmark ✓).
1
Start a chat with BotFather
Tap Start or type /start. BotFather will reply with a list of available commands.
2
Create a new bot
Send the command /newbot.
3
Name your bot
BotFather asks: “How are we going to call it?” — type any display name you like, e.g. MyAssistantBot.
4
Choose a username
The username must end in bot or Bot. If it’s taken, BotFather will ask you to try another.
5
Copy your API token
BotFather responds with “Done! Congratulations on your new bot.” and provides:
A link to talk to your bot — e.g. t.me/MyAssistantBot
An API token — looks like 123456789:ABCdefGHIjklMNO...
Keep your token secret! Anyone with this token can control your bot. If it ever gets leaked, revoke it with /revoke in BotFather.
~1 minNow bring that bot token into Machine to link it with one of your agents.
1
Navigate to the Telegram page
In the Machine dashboard sidebar, click Telegram — or go directly to /telegram.
2
Click 'Add Bot'
A configuration dialog will open with three fields.
3
Paste your Bot Token
In the Bot Token field, paste the API token from BotFather. Format: 123456789:ABCdefGHIjklMNO...
4
Select an Agent
Choose which Machine agent should handle incoming messages. This agent’s instructions, personality, and tools will power your bot’s responses.
5
Select a Model (optional)
Optionally pick a specific AI model. If you leave this blank the bot uses the agent’s default model.
6
Click 'Save Configuration'
Machine validates your token, sets up the webhook automatically, and shows a success notification. Your bot appears in the Connected Bots table with a green Active badge.
Your bot is now live! Open Telegram, search for your bot’s username (e.g. @MyAssistantBot), and tap Start.
Copy
@MyAssistantBotonline/start👋 Hello! I'm your Machine-powered assistant. Here's what I can help with…Hey, you're my Telegram botThat's right! I'm connected to your Machine agent. How can I help you today?What can you do?I can help with a variety of tasks — just ask me anything and I'll use all the tools and knowledge my agent has access to!
The bot maintains conversation context within each chat thread, so you can have natural back-and-forth conversations just like chatting with a person.
Customize your agent’s instructions for Telegram’s conversational style. Add instructions like “Keep responses concise and suitable for mobile messaging”
Message Length
Telegram messages tend to be shorter — tune your prompts accordingly
When you add your bot to a group, Machine provides it with context about who is speaking.
By default, bots only see messages that @mention them. To see all messages, use /setprivacy → Disable. Note: Changing privacy requires removing and re-adding the bot to the group.
Disabling privacy increases credit usage as the bot processes all messages in the group.