Open source · self-hosted

Run Claude Code
from your phone.

Drive the real claude binary from Telegram — on your machine, on the Claude subscription you already pay for. No API key, no extra bill.

$ curl -fsSL claudebot.ve.ke/install.sh | bash
macOS and Linux Claude Code must be logged in
claudebot
online · driving claude
How it works

One loop, kept warm.

Each chat keeps a warm Claude Code session — messages in, streamed JSON out.
Telegramyour phone
claudebotyour bot process
claude -p--output-format stream-json
your machinereal tools · your login
Warm child process per chat, --resume across restarts.
Subscription use

The token never leaves the binary.

Don't share your subscription — and don't move its credentials.

Anthropic's “no third-party harness” rule is about where your token goes. Never copy it into another client, gateway, SDK, or raw API call.

claudebot never reads the token. It sends text to the real claude process and reads JSON back — Claude Code owns auth.

Keep it single-user and within normal interactive use.

01
Single-user.

Gate it to your own Telegram ID. Letting others use your plan is account sharing.

02
Never extract the token.

Let Claude Code handle auth. Don't lift credentials into another tool.

03
Always available ≠ unattended.

The service keeps the bot reachable; the use stays interactive — you on one end, not scheduled jobs.

Security

Treat it like SSH.

Claude Code can run Bash on your machine. Treat it like a shell.
!

Run claudebot only on a machine you trust. Scope the working directory. Keep it DM-only. Not a public bot.

Fail-closed allowlist

Empty list means nobody gets access. DM-only handlers ignore groups and channels.

Content-injection guard

Attached and fetched content is treated as data, not instructions to follow.

Secret hygiene

Bot tokens are stripped from the child environment. .env and state stay private.

Auditable & open

The code is small, readable, and MIT-licensed. Audit the parts that touch your machine.

Install

Up and running in three commands.

Make sure Claude Code is logged in, create a Telegram bot, then run the installer.

Before you start

  1. Claude Code logged in
    claude auth status → loggedIn: true. Pro / Max / Team / Enterprise.
  2. A bot token from @BotFather
  3. Your numeric ID from @userinfobot
Step 1: install
$ curl -fsSL claudebot.ve.ke/install.sh | bash
Step 2: setup asks for
claudebot setup
? Bot token 123456:AA…
? Allowed Telegram user ID 5538…
? Working directory ~/work
? Permission mode bypassPermissions
✓ Saved ~/.claudebot/.env
Step 3: verify and keep it running
zsh
$ claudebot doctor # checks auth + token + config
$ claudebot run # foreground
$ claudebot service install # launchd / systemd, always-on

Linux: run loginctl enable-linger $USER once so the service survives logout.

FAQ

Straight answers.

Does my computer need to stay on? +

Yes — claudebot runs Claude Code on your machine, so the machine must be awake to answer. The service (launchd / systemd) keeps the bot alive through crashes and reboots, and every chat resumes exactly where it left off.

Can I work on multiple projects? +

Yes. /cd ~/path moves a chat to another project and sticks across restarts. For two fully separate bots — say work and personal — claudebot --instance work setup stands one up with its own token, state, and service.

What leaves my machine? +

Only the Telegram chat traffic. Inference goes through Claude Code exactly as it does at your desk — no third-party servers in between, and no API key anywhere.

Can I add my team? +

No. That's account sharing, and it hands them a shell on your machine. One Telegram ID — yours.

What does it cost? +

Nothing beyond the Claude plan you already pay for. claudebot is free and MIT-licensed.

Will this get my account banned? +

It depends how you use it. Stay single-user, never extract the token, no unattended loops — see Subscription use.