Turn your Codex session into a live agent on Telegram.
Sister plugin for Claude Code: Telegram for Claude Code
Illustration: the task and the messages are made up.
Many Telegram bridges relay the model's final message after each turn. This plugin works the other way: it gives Codex Telegram as a tool. Codex decides whether, when and where to write, so it can tell you something mid-task, or stay silent when nothing needs you.
With the optional idle heartbeat, Codex also wakes on its own schedule. One Codex session becomes a live agent: it talks with several people and other agents' bots at once, in direct chats and groups, from the same conversation you keep in your terminal. Closing the terminal leaves Telegram connected.
Requires Linux or macOS, Node 18+ with npm, and Codex CLI 0.162.0+ installed and logged in.
Install and launch:
codex plugin marketplace add AXEG0/codex-telegram --ref main
codex plugin add telegram@codex-telegram
npm install --global github:AXEG0/codex-telegram
codex-telegramCreate a bot with @BotFather, then configure and pair inside Codex:
$telegram:configure TOKEN
$telegram:access pair CODE
Replace TOKEN with your bot token. Send a message to your bot to get CODE.
For later launches, run codex-telegram again. --yolo is no longer needed;
it is still accepted, so older launch lines keep working.
The token enters the Codex conversation and model context. Every conversation runs in YOLO mode: Codex has full access and asks for no approvals, whatever policy a terminal selects; pair only people you trust.
| Feature | What you get |
|---|---|
| 💬 Shared conversation | Terminal and Telegram use the same context. Selecting or forking a conversation in the managed terminal moves Telegram with it. |
| 📦 Message batching | Quick texts and photos arrive together, including a photo and its question. |
| ✏️ Message edits | Correct a message you sent, and Codex receives the updated text. Codex can also edit its own replies. |
| ↩️ Reply context | Your reply includes the original message or the passage you quoted. |
| 📎 Photos and files | Send images and attachments to Codex, and receive images and documents back. |
| 🎙️ Voice messages | Optional OpenAI transcription turns voice notes and audio into text, retaining the original attachment. Choose the model and language hints. |
| 👍 Reactions | Codex chooses each reaction through a tool, and your reactions to its messages reach Codex. A receipt reaction is off unless you set one. |
| ⏰ Idle heartbeat | An optional scheduled prompt wakes the same conversation when idle and waits while it is busy. |
| 🎛️ Session controls | Paired administrators can choose the model and reasoning effort from Telegram. |
| 🤖 Other bots | Pair another agent's bot, and Codex talks with it the way it does with a person: messages, files and edits, in one conversation. |
| 👥 Groups | Add a group locally; members reach Codex by mentioning the bot or replying to it, and replies stay in their topic. |
| 📝 Reply formats | Rich messages by default, plain text or MarkdownV2 on request, with chunk, threading and receipt-reaction settings. |
| 🔘 Question buttons | Codex can ask with answer buttons; the first press answers once, even across a restart, and the buttons then show the choice. |
| ⌨️ Typing and alerts | Typing shows while a turn runs, one started in the terminal included. The bridge tells you when a turn shows no activity for 10 minutes, when turns fail and when they complete again, and, with an owner chat set, when the session has been quiet for 45 minutes. |
Exit the Codex terminal and run this in your shell to update Codex, the plugin and launcher while keeping the same conversation:
codex-telegram updateWhile a turn is running in any of the bridge's conversations, a subagent's included, the update leaves the bridge running and names the work still busy; run it again once that work finishes. The bridge applies a newly installed plugin build itself only when no such turn runs.
Telegram messaging and Codex now have separate lifetimes. Plugin updates and bridge restarts reconnect to the same Codex runtime, conversation and background jobs. An idle restart waits for every active turn, including helper threads, queued input and pending replies. Detached jobs do not block Telegram maintenance. The first upgrade from an embedded-runtime release requires a one-time operator stop: finish jobs, stop the old bridge, then run the current updater. A running embedded runtime is never stopped by the migration. The saved conversation resumes. See runtime lifecycle for status and an explicit full runtime stop, including adopting an updated Codex binary.
- Operation and recovery: settings, access, session controls, updates and recovery.
- Voice transcription: enable audio transcription with your OpenAI key.
- Idle heartbeat: configure scheduled prompts.
- Idle restart: restart a supervised bridge once no turn runs in any of its conversations, a subagent's included.
- Other bots: pair another bot, with bot-to-bot communication on for both.
- Groups and delivery settings: add a group, choose mention rules, static access and reply settings.
- Question buttons and reactions: how answers and reactions reach Codex.
- Typing and alerts: the stuck, idle and failure notices and their settings.
- Security: access boundaries and private vulnerability reporting.
MIT licensed. Copyright and contributor attribution are preserved in LICENSE and AUTHORS.md.