{"id":30230155,"url":"https://github.com/libresign/star-tracker","last_synced_at":"2025-10-13T16:35:14.607Z","repository":{"id":309421069,"uuid":"1036230129","full_name":"LibreSign/star-tracker","owner":"LibreSign","description":"Track GitHub starts and send events to Telegrma group","archived":false,"fork":false,"pushed_at":"2025-08-11T19:06:09.000Z","size":21,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-01T02:00:04.195Z","etag":null,"topics":["github-stars","github-webhook","hacktoberfest","stargazers","stars","telegram"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LibreSign.png","metadata":{"files":{"readme":"README.md","changelog":null,"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}},"created_at":"2025-08-11T18:53:20.000Z","updated_at":"2025-08-11T19:06:13.000Z","dependencies_parsed_at":"2025-08-11T21:17:15.926Z","dependency_job_id":null,"html_url":"https://github.com/LibreSign/star-tracker","commit_stats":null,"previous_names":["libresign/star-tracker"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/LibreSign/star-tracker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LibreSign%2Fstar-tracker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LibreSign%2Fstar-tracker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LibreSign%2Fstar-tracker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LibreSign%2Fstar-tracker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LibreSign","download_url":"https://codeload.github.com/LibreSign/star-tracker/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LibreSign%2Fstar-tracker/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279016090,"owners_count":26085802,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-13T02:00:06.723Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["github-stars","github-webhook","hacktoberfest","stargazers","stars","telegram"],"created_at":"2025-08-14T22:24:44.761Z","updated_at":"2025-10-13T16:35:14.602Z","avatar_url":"https://github.com/LibreSign.png","language":"JavaScript","readme":"# GitHub Stars to Telegram Webhook\n\nA standalone Node.js application that listens to **GitHub Webhook** `star` events and sends a notification to a Telegram chat whenever a repository receives or loses a star.\n\n## Features\n\n* ✅ Listens for GitHub **star** events (`created` and `deleted`).\n* ✅ Sends a message to a Telegram group or channel.\n* ✅ Supports multiple languages via **i18next**.\n* ✅ Validates GitHub webhook payloads using HMAC signatures (`X-Hub-Signature-256`).\n* ✅ No external framework — pure Node.js HTTP server.\n\n## How it Works\n\n1. GitHub sends a webhook payload when a user stars or unstars your repository.\n2. The application validates the signature using the shared `WEBHOOK_SECRET`.\n3. It formats a message with repository info, starrer username, and current star count.\n4. The message is sent to your configured Telegram chat via the Bot API.\n\n## Requirements\n\n* A **Telegram Bot Token** from [@BotFather](https://t.me/BotFather)\n* A **Telegram Chat ID** (group, channel, or direct chat)\n* A **GitHub Webhook** configured to send **star** events\n\n## Installation\n\nClone this repository:\n\n```bash\ngit clone https://github.com/yourusername/github-stars-to-telegram.git\ncd github-stars-to-telegram\n```\n\nCreate a `.env` file in the project root:\n\n```env\nWEBHOOK_SECRET=your-github-webhook-secret\nTELEGRAM_BOT_TOKEN=123456:ABC-DEF...\nTELEGRAM_CHAT_ID=-1001234567890\nLANGUAGE=pt\nPORT=3000\n```\n\nWake up the environment with `docker compose up`\n\n## GitHub Webhook Setup\n\n1. Go to your repository **Settings → Webhooks → Add webhook**.\n2. Set:\n\n   * **Payload URL:** `https://your-domain.com/webhook`\n   * **Content type:** `application/json`\n   * **Secret:** same as `WEBHOOK_SECRET` in your `.env`\n3. Select **Let me select individual events** → check **Star**.\n4. Save.\n\n## Telegram Bot Setup\n\n1. Create a bot with [@BotFather](https://t.me/BotFather).\n2. Copy the **Bot Token** to `TELEGRAM_BOT_TOKEN` in `.env`.\n3. Add the bot to your group/channel and make sure it has permission to send messages.\n4. Find your chat ID:\n\n   * You can use [@RawDataBot](https://t.me/RawDataBot) or the Telegram Bot API (`getUpdates`).\n\n## Testing\n\nSet the environment `DEBUG` as `1`.\n\nYou can mock a webhook call using `curl`:\n\n```bash\nBODY='{\"action\":\"created\", ... }'\n\ncurl -X POST http://localhost:3000/webhook \\\n    -H \"Content-Type: application/json\" \\\n    -H \"X-GitHub-Event: star\" \\\n    --data \"$BODY\"\n```\n\n## Internationalization (i18n)\n\nThis project uses **i18next** for translations. You can add more languages in the `src/locales` folder and send a new PR.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibresign%2Fstar-tracker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flibresign%2Fstar-tracker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flibresign%2Fstar-tracker/lists"}