{"id":19451788,"url":"https://github.com/TheFireBugs/BT2Telegram","last_synced_at":"2025-04-25T04:30:30.744Z","repository":{"id":79218542,"uuid":"605410815","full_name":"TheFireBugs/BT2Telegram","owner":"TheFireBugs","description":"宝塔面板Telegram推送通道 (预览版)","archived":false,"fork":false,"pushed_at":"2025-03-17T11:19:18.000Z","size":153,"stargazers_count":16,"open_issues_count":5,"forks_count":4,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-04-03T15:52:30.574Z","etag":null,"topics":["aapanel","bt","btpanel","telegram"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TheFireBugs.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":"2023-02-23T04:58:44.000Z","updated_at":"2025-03-29T19:38:38.000Z","dependencies_parsed_at":null,"dependency_job_id":"4a4aef94-ced5-46a1-90f2-4cfd8d54fbed","html_url":"https://github.com/TheFireBugs/BT2Telegram","commit_stats":null,"previous_names":["thefirebugs/bt2telegram"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheFireBugs%2FBT2Telegram","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheFireBugs%2FBT2Telegram/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheFireBugs%2FBT2Telegram/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheFireBugs%2FBT2Telegram/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TheFireBugs","download_url":"https://codeload.github.com/TheFireBugs/BT2Telegram/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250754542,"owners_count":21481834,"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","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":["aapanel","bt","btpanel","telegram"],"created_at":"2024-11-10T16:43:03.648Z","updated_at":"2025-04-25T04:30:30.734Z","avatar_url":"https://github.com/TheFireBugs.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# \u003ccenter\u003e\u003cstrong\u003eBTG\u003c/strong\u003e\u003c/center\u003e\r\n \r\n\u003cbr\u003e\r\n\r\n![GitHub go.mod Go version](https://img.shields.io/github/go-mod/go-version/JNyaa/BT2Telegram?label=Go%20Version\u0026style=flat-square)\r\n[![GitHub release (latest by date)](https://img.shields.io/github/v/release/JNyaa/BT2Telegram?label=Release%20Version\u0026style=flat-square)](https://github.com/JNyaa/BT2Telegram/release)\r\n[![Apache-2.0](https://img.shields.io/github/license/JNyaa/BT2Telegram?style=flat-square)](https://github.com/JNyaa/BT2Telegram/blob/master/LICENSE)\r\n\r\n[![GitHub issues](https://img.shields.io/github/issues/JNyaa/BT2Telegram?label=Sticker%20Issues\u0026style=flat-square)](https://github.com/JNyaa/BT2Telegram/issues)\r\n[![GitHub Repo stars](https://img.shields.io/github/stars/JNyaa/BT2Telegram?label=Stars\u0026style=flat-square)](https://github.com/JNyaa/BT2Telegram/stargazers)\r\n![GitHub release (latest by date)](https://img.shields.io/github/downloads/JNyaa/BT2Telegram/latest/total?label=Downloads%40Latest\u0026style=flat-square)\r\n![GitHub repo size](https://img.shields.io/github/repo-size/JNyaa/BT2Telegram?style=flat-square)\r\n![GitHub commit activity](https://img.shields.io/github/commit-activity/m/JNyaa/BT2Telegram?style=flat-square)\r\n\r\n\u003cbr\u003e\r\n\r\n---\r\n\r\n\u003cp align=\"center\"\u003e\u003cstrong\u003e宝塔面板的Telegram消息推送通道\u003cstrong\u003e\u003c/p\u003e\r\n\u003cp align=\"center\"\u003e\u003cstrong\u003e该项目年久失修，请自行Fork修改\u003cstrong\u003e\u003c/p\u003e\r\n\r\n\r\n\u003cbr\u003e\r\n\u003cp align=\"center\"\u003e\u003ca href=\"https://github.com/TheFireBugs/BT2Telegram/releases\"\u003eDownload\u003c/a\u003e | \u003ca href=\"https://github.com/TheFireBugs/BT2Telegram/issues\"\u003eIssues\u003c/a\u003e\u003c/p\u003e\r\n\r\n\r\n\u003cbr\u003e\r\n\r\n# 需求\r\n\r\n1. 宝塔需求: 消息通道支持邮件,官方版/开心版均可,不限大陆/国际版\r\n2. 系统需求: Linux建议Kernel 4+, Windows建议内部版本最低18362\r\n\r\n\u003cbr\u003e\r\n\r\n# 配置文件\r\n配置文件为 `btg.yml`\r\n```\r\nbot:\r\n  key: BotAPI的Key，从@BotFather处获取\r\n  chat: ChatID, 如果不知道ChatID，如果想在群组里发送消息，先把机器人拉进群，配置好key后启动，在群内输入指令 `/my`，将ChatID的值复制到配置文件的`bot.chat`中，重新启动机器人即可。chat支持的类型: 群组、频道、私聊(需要先私聊机器人以创建会话)\r\n  api_server: 自定义Telegram Bot API地址 (https://example.com/)\r\nsmtp:\r\n  port: 邮件服务器端口，请务必在防火墙封禁端口\r\n  auth:\r\n    status: 邮件服务器基础验证，默认为false(关)，设置为true以启用验证\r\n    user: 邮件服务器验证用户名\r\n    pass: 邮件服务器验证密码\r\n```\r\n\r\n# 开始搭建\r\n\r\n## 安装\r\n\r\n1. [下载](https://github.com/JNyaa/BT2Telegram/releases) 二进制文件，将其移动到任意文件夹并给予root 777权限\r\n2. 从Github仓库中找到 btg.yml，将其下载并和二进制放在一起 (给予读写权限)\r\n3. 配置btg.yml。\r\n4. [配置systemd](#systemd配置) (必选)\r\n5. [配置宝塔](#宝塔配置) (必选)\r\n\r\n\u003cbr\u003e\r\n\r\n## systemd配置\r\n\r\n1. 从Github仓库中找到 btg.service，将其下载并和二进制放在一起 (给予读写权限)\r\n2. 修改service文件中的目录\r\n3. `mv btg.service /usr/lib/systemd/system/btg.service`\r\n4. `systemctl start btg`\r\n5. 如果需要开机启动，再额外输入命令 `systemctl enable btg`\r\n\r\n\r\n## 宝塔配置\r\n1. 点击 `面板设置-告警通知-告警设置` (如果有问题，点击 `通知设置-设置推送`，点击窗口左下角的`更新列表`即可，配置完后还需要在此再点击一遍`更新列表`)\r\n2. 找到`邮箱-点击设置`\r\n3. 发送人邮箱和SMTP密码随便填 (全填1也行，如果在btg.yml中开启验证，则须与配置文件中一致)\r\n4. SMTP服务器设置为127.0.0.1，端口设置为配置文件中的smtp.port端口\r\n5. 点击保存即可\r\n\r\n后面的收件人邮箱也是随便填，第一次会自动初始化。\r\n\r\n\u003cbr\u003e\r\n\r\n# License\r\nThis software is distributed under Apache-2.0 license.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTheFireBugs%2FBT2Telegram","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTheFireBugs%2FBT2Telegram","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTheFireBugs%2FBT2Telegram/lists"}