{"id":49543321,"url":"https://github.com/ranjbar-dev/vscode-copilot-telegram-notif","last_synced_at":"2026-05-02T16:31:32.275Z","repository":{"id":349360122,"uuid":"1202029854","full_name":"ranjbar-dev/vscode-copilot-telegram-notif","owner":"ranjbar-dev","description":null,"archived":false,"fork":false,"pushed_at":"2026-04-05T14:00:47.000Z","size":132,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-05T16:05:31.392Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ranjbar-dev.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-05T13:58:44.000Z","updated_at":"2026-04-05T14:00:52.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ranjbar-dev/vscode-copilot-telegram-notif","commit_stats":null,"previous_names":["ranjbar-dev/vscode-copilot-telegram-notif"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/ranjbar-dev/vscode-copilot-telegram-notif","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ranjbar-dev%2Fvscode-copilot-telegram-notif","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ranjbar-dev%2Fvscode-copilot-telegram-notif/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ranjbar-dev%2Fvscode-copilot-telegram-notif/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ranjbar-dev%2Fvscode-copilot-telegram-notif/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ranjbar-dev","download_url":"https://codeload.github.com/ranjbar-dev/vscode-copilot-telegram-notif/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ranjbar-dev%2Fvscode-copilot-telegram-notif/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32542029,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T12:25:33.646Z","status":"ssl_error","status_checked_at":"2026-05-02T12:24:51.733Z","response_time":132,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-05-02T16:31:31.609Z","updated_at":"2026-05-02T16:31:32.263Z","avatar_url":"https://github.com/ranjbar-dev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CopilotNotify\n\nA VS Code extension that sends a **Telegram push notification** when the CopilotNotify custom chat participant finishes responding.\n\n**Privacy-first · Serverless · Participant-turn scoped**\n\n- The extension calls the Telegram Bot API directly from VS Code — no backend, no proxy.\n- Only participant-turn metadata is sent: a generic label, workspace name, duration, and outcome. Prompt text, code content, and file diffs are never read, logged, or transmitted.\n- Notifications are scoped exclusively to the `@copilotnotify` chat participant. The extension does **not** passively monitor Copilot Edits, autocomplete suggestions, or Copilot Chat conversations addressed to other participants.\n\n---\n\n## Prerequisites\n\n### 1. Create a Telegram Bot\n\n1. Open Telegram and search for **@BotFather**.\n2. Send `/newbot` and follow the prompts (choose a name and a username ending in `bot`).\n3. BotFather will reply with a **bot token** in the format `123456789:ABCdef...`. Copy it.\n\n### 2. Retrieve Your Chat ID\n\n1. Start a conversation with your new bot (send it any message).\n2. Open a browser and visit:\n   ```\n   https://api.telegram.org/bot\u003cYOUR_BOT_TOKEN\u003e/getUpdates\n   ```\n3. Find the `\"id\"` field inside `\"chat\"` in the JSON response — that is your **chat ID** (a positive or negative integer).\n\n\u003e **Group / channel chats:** Add the bot to the group/channel first, then send a message mentioning the bot. Use the negative integer ID from `getUpdates`.\n\n### 3. VS Code\n\nVS Code **1.90.0 or later** is required.\n\n---\n\n## Installation\n\n### From Source\n\n```bash\n# Clone the repository\ngit clone https://github.com/ranjbar-dev/vscode-copilot-telegram-notif.git\ncd vscode-copilot-telegram-notif\n\n# Install dependencies\nnpm install\n\n# Compile TypeScript\nnpm run compile\n```\n\nThen press **F5** in VS Code to launch an Extension Development Host with CopilotNotify loaded, or package the extension with:\n\n```bash\nnpx vsce package\n```\n\nand install the generated `.vsix` file via **Extensions: Install from VSIX…** in the Command Palette.\n\n---\n\n## Usage\n\n### First-Time Setup\n\n1. Open the **Command Palette** (`Ctrl+Shift+P` / `Cmd+Shift+P`).\n2. Run **CopilotNotify: Configure Telegram**.\n3. Enter your **bot token** when prompted. It is stored in `vscode.SecretStorage` and never written to disk in plaintext.\n4. Enter your **Telegram chat ID** when prompted. It is saved in VS Code workspace settings.\n\nThe status bar item in the bottom-left corner shows the current state:\n\n| Icon | Meaning |\n|---|---|\n| 🔔 Notify: ON | Extension is enabled and credentials are configured |\n| 🔕 Notify: OFF | Extension is explicitly disabled |\n| ⚠️ Notify: Not Configured | Credentials are missing — run Configure Telegram first |\n\n### Receiving Notifications\n\n1. Open the **GitHub Copilot Chat** panel (`Ctrl+Alt+I` / `Cmd+Option+I`).\n2. Address a message to the CopilotNotify participant:\n   ```\n   @copilotnotify explain this function\n   ```\n3. When the participant turn completes (or is cancelled), CopilotNotify sends a Telegram message to your configured chat.\n\n**Default notification format:**\n```\nCopilot task finished\nWorkspace: my-project\nDuration: 12s\nOutcome: completed\n2026-04-04T10:23:45.000Z\n```\n\n**Minimal notification format** (set `copilotNotify.messageFormat` to `\"minimal\"`):\n```\nCopilot task finished\n2026-04-04T10:23:45.000Z\n```\n\n### Sending a Test Notification\n\nRun **CopilotNotify: Send Test Notification** from the Command Palette. This sends a fixed generic message that bypasses outcome filtering and cooldown, so you can verify credentials without waiting for a real participant turn.\n\n### Enabling and Disabling\n\n- **CopilotNotify: Enable** — turns notifications on and saves the state globally.\n- **CopilotNotify: Disable** — turns notifications off without clearing credentials.\n\n### Viewing Logs\n\nRun **CopilotNotify: Show Logs** to open the `CopilotNotify` Output Channel. All dispatch results, suppression reasons, and warnings are written there.\n\n---\n\n## Configuration Reference\n\nAll settings are in the `copilotNotify` namespace and can be configured in VS Code Settings (UI or `settings.json`).\n\n| Setting | Type | Default | Description |\n|---|---|---|---|\n| `copilotNotify.enabled` | `boolean` | `true` | Master on/off switch for Telegram notifications. |\n| `copilotNotify.telegramChatId` | `string` | `\"\"` | Your Telegram chat ID (personal, group, or channel). Not a secret — the bot token is stored separately in SecretStorage. |\n| `copilotNotify.notifyOnSuccess` | `boolean` | `true` | Send a notification when a participant turn completes normally (`outcome: completed`). Set to `false` to suppress successful-turn notifications. |\n| `copilotNotify.notifyOnFailure` | `boolean` | `true` | Send a notification when a participant turn is cancelled (`outcome: cancelled`). Set to `false` to suppress cancelled-turn notifications. |\n| `copilotNotify.cooldownSeconds` | `integer` | `5` | Minimum seconds between consecutive notifications. Prevents notification floods after rapid successive turns. Set to `0` to disable the cooldown entirely. Negative values are treated as `0`. |\n| `copilotNotify.messageFormat` | `\"default\"` \\| `\"minimal\"` | `\"default\"` | Notification verbosity. `\"default\"` includes label, workspace name (if available), duration, outcome, and ISO timestamp. `\"minimal\"` includes only the label and timestamp. Unrecognized values fall back to `\"default\"` with a warning logged to the Output Channel. |\n\n\u003e **Bot token** is not a VS Code setting — it is stored in `vscode.SecretStorage` under the key `copilotNotify.botToken` and is never written to `settings.json`.\n\n---\n\n## Commands\n\n| Command | Description |\n|---|---|\n| `CopilotNotify: Configure Telegram` | Run the setup wizard to enter or update bot token and chat ID. |\n| `CopilotNotify: Enable` | Enable notifications globally. |\n| `CopilotNotify: Disable` | Disable notifications globally (credentials are preserved). |\n| `CopilotNotify: Send Test Notification` | Send a fixed test message to verify credentials. Bypasses outcome filter and cooldown. |\n| `CopilotNotify: Show Logs` | Open the CopilotNotify Output Channel. |\n\n---\n\n## Known Limitations\n\n- **Participant-scope only.** CopilotNotify detects the completion of its own `@copilotnotify` participant turn. It does **not** monitor Copilot Edits, Copilot Workspace tasks, standard inline autocomplete, or Copilot Chat conversations addressed to other participants (e.g., `@workspace`, `@github`). This is a constraint of the public VS Code Chat Participant API — passive observation of other Copilot surfaces is not exposed.\n- **Duration is wall-clock time.** Task duration is the elapsed time from when the participant handler is invoked to when it resolves. It reflects network round-trip and streaming time, not internal model execution time.\n- **Outcome derives from the cancellation token.** \"Cancelled\" means `token.isCancellationRequested` was `true` when the handler resolved. It does not distinguish user-initiated cancellation from a timeout or error path that sets the token.\n- **Telegram only.** Push notifications are sent exclusively to Telegram in this release. Slack, Discord, and other channels are out of scope.\n- **Single destination.** One bot token and one chat ID per VS Code installation. Multi-destination dispatch is out of scope.\n- **No message history.** Sent notifications are not stored or displayed inside VS Code.\n\n---\n\n## Security Notes\n\n- The bot token is stored in `vscode.SecretStorage`, which is encrypted by the OS credential store. It is never written to `settings.json`, workspace state, or any log file.\n- HTTP requests go directly to `https://api.telegram.org` using the native `fetch` built into the VS Code extension host — no third-party HTTP library, no proxy, no backend.\n\n---\n\n## Changelog\n\nSee `CHANGELOG.md` in the repository for the release history.\n\n---\n\n## License\n\nMIT — see `LICENSE` in the repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Franjbar-dev%2Fvscode-copilot-telegram-notif","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Franjbar-dev%2Fvscode-copilot-telegram-notif","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Franjbar-dev%2Fvscode-copilot-telegram-notif/lists"}