Talk to Your Lobster From Anywhere
OpenClaw is running — awesome. But right now you can only talk to it from a terminal on your computer. Let's fix that by connecting it to Telegram, so you can chat with your AI agent from your phone, tablet, or anywhere.
This is the moment it starts feeling like you have a real AI assistant.
Already have OpenClaw installed and just need to add Telegram? These steps work for you too — just skip to Step 1 below. The only difference is you'll need to run openclaw gateway restart instead of openclaw gateway start in Step 4, since OpenClaw doesn't hot-reload channel configs.
Step 1: Create Your Telegram Bot
Every Telegram bot starts with a chat with the BotFather — Telegram's built-in bot for making bots. (Yes, it's bots all the way down.)
- Open Telegram and search for @BotFather
- Type
/newbot - Give your bot a name — this is what people see (e.g., "My OpenClaw Assistant")
- Pick a username ending in
bot(e.g.,myclaw_bot) - BotFather will hand you a token — it looks something like
123456789:ABCdef...
This token is the key to your bot. Anyone who has it can control it. Don't share it, don't post it on GitHub, don't paste it in a group chat. Treat it like a password.
Step 2: Get Your Telegram User ID
OpenClaw needs to know who is allowed to talk to your bot. You'll need your Telegram user ID (it's a number, not your username).
The easiest way to get it:
- Search for @userinfobot in Telegram
- Send it any message
- It replies with your user ID — copy that number
Step 3: Configure OpenClaw
Now let's tell OpenClaw about your Telegram bot. Open the config file:
nano ~/.openclaw/openclaw.jsonThis file has a bunch of other OpenClaw settings in it — don't worry about those. Scroll down until you find the channels section, and add your Telegram config there:
{
"channels": {
"telegram": {
"enabled": true,
"token": "YOUR_BOT_TOKEN_HERE",
"allowedUsers": [YOUR_USER_ID_HERE]
}
}
}Replace YOUR_BOT_TOKEN_HERE with the token from BotFather, and YOUR_USER_ID_HERE with the number you got from @userinfobot.
Don't want to edit JSON by hand? You can also open the Gateway chat at http://127.0.0.1:18789/ and ask your agent to update the config file for you. Just tell it your bot token and user ID — it'll handle the rest.
The allowedUsers list controls exactly who can talk to your bot. Only user IDs in this list will get responses — everyone else gets ignored. For now, just add yourself. You can add friends and family later.
Step 4: Start OpenClaw
If OpenClaw isn't already running, start it up:
openclaw gateway startYou can watch the logs in real time to make sure everything connects properly:
tail -f ~/.openclaw/logs/openclaw.logLook for a line mentioning Telegram — that means the connection is live.
Step 5: Test Incoming Messages
Time for the moment of truth. Open Telegram and find your bot (search for the username you picked in Step 1).
Send it a message:
hello
Now check your logs:
grep -i telegram ~/.openclaw/logs/openclaw.logIf you see your message show up in the logs — the connection is working. Your bot is listening.
Step 6: Test Outgoing Messages
Let's make sure OpenClaw can send messages to you too. Run this from your terminal:
openclaw message send --channel telegram --to YOUR_USER_ID "Hello from OpenClaw!"Check Telegram — you should see the message pop up from your bot.
Step 7: Test Auto-Reply
This is the fun part. Go back to Telegram and ask your bot something:
what time is it
OpenClaw should think about it and reply right there in the chat. If it does — you now have a working AI agent in your pocket.
What's Next?
You've got OpenClaw installed, running, and connected to Telegram. You can chat with your AI agent from anywhere. That's a massive first step.
In the next molt, we'll start making OpenClaw actually useful — installing skills, automating tasks, and putting your lobster to work.
Send your bot at least three different messages and get responses. Try asking it a question, giving it a task, and just having a casual chat. Take a screenshot of the conversation — that's your proof you've completed Molt 1.
