Skip to content

mistake PR#19570

Closed
Avimitin wants to merge 3 commits intoanomalyco:devfrom
Avimitin:feature/telegram-channel
Closed

mistake PR#19570
Avimitin wants to merge 3 commits intoanomalyco:devfrom
Avimitin:feature/telegram-channel

Conversation

@Avimitin
Copy link
Copy Markdown

@Avimitin Avimitin commented Mar 29, 2026

editied to avoid polluting future search

Add packages/telegram/ with Telegram bot integration for opencode,
modeled after the existing Slack integration (packages/slack/).

Features:
- Access control: DM pairing, allowlist, group policies, mention patterns
- Session management: chat_id to session mapping for conversation continuity
- Message formatting: <channel> tags matching Claude Code's protocol
- Auto-splitting for Telegram's 4096 char limit
- SSE event subscription for tool execution updates
- Support for text, photo, document, voice, video, sticker messages

Usage: TELEGRAM_BOT_TOKEN=xxx bun run --cwd packages/telegram dev

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions github-actions bot added the needs:compliance This means the issue will auto-close after 2 hours. label Mar 29, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 29, 2026

This PR doesn't fully meet our contributing guidelines and PR template.

What needs to be fixed:

  • PR description is missing required template sections. Please use the PR template.

Please edit this PR description to address the above within 2 hours, or it will be automatically closed.

If you believe this was flagged incorrectly, please let a maintainer know.

@github-actions
Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

Potential Duplicates Found

PR #13373 - feat: Adding OpenCode Telegram Bot
#13373

This is a related PR that also adds Telegram bot integration to OpenCode. You should check if this is addressing a similar or overlapping scope.

PR #15742 - docs(ecosystem): add opencode-telegram-bot
#15742

This is documentation for a Telegram bot integration, which appears related to the above PR.


Related integrations (different platforms, but similar pattern):

These follow the same integration pattern but for different messaging platforms.

XinpianCCBot and others added 2 commits March 29, 2026 00:15
NixOS module at nix/module.nix that manages the opencode Telegram bot
as a systemd service with:

- Configurable package (defaults to nixpkgs opencode with overrideAttrs
  pointing to Avimitin/opencode source)
- Secret management via file paths (botTokenFile, anthropicKeyFile)
- Declarative access.json configuration
- systemd hardening (NoNewPrivileges, ProtectSystem, etc.)
- Auto-created state directories
- Example configuration at nix/example.nix

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace anthropicKeyFile/provider/model options with a single `settings`
option that maps directly to opencode.json. All LLM provider config
(including API key env vars) goes through settings, matching how opencode
is normally configured.

API keys are loaded via `environmentFile` (systemd EnvironmentFile=),
not through Nix options.

Changes:
- settings: Nix attrs → serialized to opencode.json
- environmentFile: for ANTHROPIC_API_KEY, OPENAI_API_KEY, etc.
- Removed anthropicKeyFile, provider, model options
- Updated example with placeholder IDs

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Avimitin Avimitin force-pushed the feature/telegram-channel branch from c01a93a to b9b22ea Compare March 29, 2026 00:26
@Hona
Copy link
Copy Markdown
Member

Hona commented Mar 29, 2026

this should be using opencode - not inside it

@Hona Hona closed this Mar 29, 2026
@Avimitin
Copy link
Copy Markdown
Author

Oh i am sorry it mistakenly open pr to main repo.

@Avimitin Avimitin changed the title feat: add Telegram channel integration mistake PR Mar 29, 2026
@github-actions
Copy link
Copy Markdown
Contributor

Hey! Your PR title mistake PR doesn't follow conventional commit format.

Please update it to start with one of:

  • feat: or feat(scope): new feature
  • fix: or fix(scope): bug fix
  • docs: or docs(scope): documentation changes
  • chore: or chore(scope): maintenance tasks
  • refactor: or refactor(scope): code refactoring
  • test: or test(scope): adding or updating tests

Where scope is the package name (e.g., app, desktop, opencode).

See CONTRIBUTING.md for details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs:compliance This means the issue will auto-close after 2 hours. needs:title

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants