Your own bot, one step at a time
About 10 minutes. Everything happens in your browser: your bot token goes to Telegram and your own Cloudflare, never to us.
hi. let's get you a bot.
Before you start
Your bot runs on your own accounts, so you need these three. Already got one? Just tick it.
- Get Telegram ↗
- Sign up ↗
New to Cloudflare? After you sign up (and verify your email) it jumps straight to "create your first Worker" or "Get started". Don't build anything there. Close that tab and come back here: the Deploy button in step 3 makes your Worker for you.
- Sign up ↗
touchgrass is open source (MIT) and runs on Cloudflare's and Telegram's free tiers for normal personal use. We charge nothing for running it.
Open BotFather
- Open BotFather (Telegram's own bot-maker) Open @BotFather ↗
- Page stuck or blank? That's Telegram's link page, not you. Try Open in the Telegram app or Telegram Web ↗. Or just open Telegram and search
@BotFather. - Check the blue tick next to its name. That's the real one.
- Press Start (if you see it).
- Send
/newbot
Name your bot
- Send a name. Anything, e.g.
Moss. Change it any time. - Send a username ending in
bot, e.g.dave_grass_bot. Taken? Try another. - Wait for the reply with your token.
Paste your bot token
- Copy the token from BotFather's reply: the long line with a colon, like
123456789:AAH… - Paste it below and press Check token.
One token = one bot. Already run a touchgrass bot? Make a new one here, or you'll move your old bot's chats to this copy.
Save your keys
We made two random keys for your bot, here in your browser. Cloudflare asks for them in a minute.
Save your two keys somewhere safe
- Setup key: reconnects your bot to Telegram if you ever need to.
- Agent key: lets Claude Code or Codex tell your bot when it's busy (step 6, maybe on another computer).
- A password manager is best. They're only kept in this tab, so they're gone when you close it.
- Lost one later? Set a new value in Cloudflare: your Worker → Settings → Variables and secrets.
Open Cloudflare's deploy page
- Press Deploy (opens a new tab) Deploy to Cloudflare ↗
- Log in to Cloudflare.
- Git account: pick your GitHub account (connect it if it asks). It makes your own copy of the code.
- Tick "Create private Git repository". It starts unticked. Needed if you ever upgrade.
Red "GitHub authorization has expired"? On GitHub open Settings → Applications ↗, uninstall Cloudflare Workers and Pages. Then press Deploy to Cloudflare again, choose New GitHub connection and Install & Authorize for All repositories.
Paste the three values
The form has boxes with these exact names. Copy each one into its box. If a box already has dots in it, clear it first.
… … … Leave everything else as it is: no extra variables needed. A yellow "API token is missing permissions" note is fine to ignore (or pick Create new token). Then press Deploy.
Wait for Ready
- Wait 1–2 minutes while Cloudflare builds your bot.
- Check the newest build says Ready. One failed build first is normal: ignore it.
Connect your bot
In Cloudflare, open your Worker and find Domains (or Settings → Domains & Routes). Copy the workers.dev address there, something like https://touchgrass.yourname.workers.dev, and paste it here.
Say hi
- Open your bot ↗
- Send
/start. It locks itself to you, so nobody else can use it. It offers the name Moss; call it whatever you like. - Tap the
[▮‿▮]button left of the message box. That opens your dashboard (today, progress, settings).
Connect your bot first (step 4).
Optional: hook up your coding agent
On the computer where you run Claude Code. Skip it if you just want water, caffeine and the daily recap. Pick one:
/plugin marketplace add touchgrass-sh/touchgrassThen install touchgrass from the list and paste your bot's address and agent key when it asks.
curl -fsSL touchgrass.sh | shirm touchgrass.sh/install.ps1 | iextouchgrass connect <your worker> <agent key>That one command also hooks up Claude Code.
Lost this page? Send /hook to your bot and tap connect agent: it shows these commands with copy buttons and ticks when you're connected. Everything else is in the guide.