@coinseeker/opencode-telegram-plugin
v1.1.3
Published
Control and monitor OpenCode from Telegram with notifications, question replies, and subagent-aware completion.
Maintainers
Readme
OpenCode Telegram Plugin
Control and monitor OpenCode from Telegram.
Install
Paste below into your OpenCode.
Install and configure OpenCode Telegram Plugin by following the instructions here:
https://raw.githubusercontent.com/coin-seeker/opencode-telegram-plugin/refs/heads/main/docs/installation.mdConfigure the npm package in ~/.config/opencode/opencode.json:
{
"plugin": ["@coinseeker/[email protected]"]
}Current stable version: @coinseeker/[email protected].
Restart OpenCode after editing the config. OpenCode resolves npm package plugins on startup.
To update an existing install, replace the previous pinned package entry with @coinseeker/[email protected], keep the rest of the plugin array unchanged, and restart OpenCode.
Configure Telegram
Create ~/.config/opencode/telegram-remote/.env:
mkdir -p ~/.config/opencode/telegram-remote
chmod 700 ~/.config/opencode/telegram-remote
cat > ~/.config/opencode/telegram-remote/.env <<'EOF'
TELEGRAM_BOT_TOKEN=your_bot_token_here
TELEGRAM_ALLOWED_USER_IDS=123456789,987654321
# Optional: skip first-message discovery
# TELEGRAM_CHAT_ID=123456789
EOF
chmod 600 ~/.config/opencode/telegram-remote/.envKeep this file private. Never commit or share your Telegram bot token.
Usage
- Create a Telegram bot with @BotFather.
- Get your numeric Telegram user ID from @userinfobot.
- Add the token and allowed user IDs to the env file above.
- Restart OpenCode.
- Send any message to your bot in a private Telegram chat.
Features
- Root session completion notifications.
- Background subagent-aware completion: child session messages are suppressed and parent completion waits until children finish.
- OpenCode question prompts via Telegram inline buttons.
- Multi-select question prompts with toggle buttons and Done submission.
- Custom free-text answers from Telegram.
- Permission approve/reject buttons from Telegram.
- Multi-session-safe Telegram polling through a file-lock leader model.
- Log file output instead of stdout terminal spam.
- Cross-process remote session listing via
/sessions,/status N,/start_work N,/helpslash commands. - Safety-gated remote
/start-workexecution: verifies agent=plan, idle status, incomplete plan, and no active boulder before dispatching.
Logs
node -e "const os=require('os'); console.log(os.tmpdir() + '/opencoder-telegram.log')"Source
https://github.com/coin-seeker/opencode-telegram-plugin
