{"id":20215891,"url":"https://github.com/pkarpovich/tg-relay-bot","last_synced_at":"2025-07-25T09:13:11.374Z","repository":{"id":239370167,"uuid":"799343681","full_name":"pkarpovich/tg-relay-bot","owner":"pkarpovich","description":"Forward messages seamlessly from HTTP and SMTP to a Telegram channel","archived":false,"fork":false,"pushed_at":"2024-05-12T16:44:38.000Z","size":31,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-05-12T22:27:13.343Z","etag":null,"topics":["golang","http","message-relay","smtp","telegram-bot"],"latest_commit_sha":null,"homepage":"","language":"Go","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/pkarpovich.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}},"created_at":"2024-05-11T21:08:36.000Z","updated_at":"2024-06-19T11:02:08.252Z","dependencies_parsed_at":"2024-05-11T22:26:51.826Z","dependency_job_id":"063a6af6-c676-4bf9-aa63-01fc5ce3077a","html_url":"https://github.com/pkarpovich/tg-relay-bot","commit_stats":null,"previous_names":["pkarpovich/tg-relay-bot"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pkarpovich/tg-relay-bot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkarpovich%2Ftg-relay-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkarpovich%2Ftg-relay-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkarpovich%2Ftg-relay-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkarpovich%2Ftg-relay-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pkarpovich","download_url":"https://codeload.github.com/pkarpovich/tg-relay-bot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pkarpovich%2Ftg-relay-bot/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266983523,"owners_count":24016559,"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-07-25T02:00:09.625Z","response_time":70,"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":["golang","http","message-relay","smtp","telegram-bot"],"created_at":"2024-11-14T06:25:19.852Z","updated_at":"2025-07-25T09:13:11.357Z","avatar_url":"https://github.com/pkarpovich.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tg-relay-bot\n\n## Introduction\n\n`tg-relay-bot` is a universal messaging bot that bridges communication between HTTP requests or SMTP emails and a\nTelegram bot channel. This service is particularly useful for integrating Telegram notifications into various web\nservices, alert systems, or any application requiring immediate message forwarding to a Telegram channel.\n\n## Features\n\n- **HTTP and SMTP Integration**: Accepts incoming messages from both HTTP requests and SMTP emails.\n- **Telegram Forwarding**: Automatically forwards messages to a designated Telegram bot channel.\n\n## Configuration\n\nYou could configure the bot by setting the following environment variables:\n\n- `TELEGRAM_TOKEN`: The Telegram bot token.\n- `TELEGRAM_SUPER_USERS`: A comma-separated list of Telegram user IDs that are allowed to interact with the bot.\n- `HTTP_SECRET`: The secret key for authenticating incoming HTTP requests.\n- `SMTP_ALLOWED_HOSTS`: A comma-separated list of allowed email domains.\n\n## Usage\n\n### Sending a Message via HTTP\n\n```bash\ncurl -X POST http://localhost:8080/send -d '{\"message\": \"Your message here\"}'\n```\n\n### Sending a Message via SMTP\n\nSend an email to the configured SMTP server and it will be automatically forwarded to the Telegram channel.\n\n## Contributing\n\nContributions are welcome! Feel free to open an issue or submit a pull request.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpkarpovich%2Ftg-relay-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpkarpovich%2Ftg-relay-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpkarpovich%2Ftg-relay-bot/lists"}