{"id":48130062,"url":"https://github.com/daya0576/he-weather-bot","last_synced_at":"2026-04-04T16:37:13.523Z","repository":{"id":38961888,"uuid":"275111489","full_name":"daya0576/he-weather-bot","owner":"daya0576","description":"🌧 A Telegram weather forecast bot based on the QWeather API ","archived":false,"fork":false,"pushed_at":"2025-07-04T06:19:05.000Z","size":4318,"stargazers_count":190,"open_issues_count":2,"forks_count":21,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-07-04T07:26:58.553Z","etag":null,"topics":["heroku","telegram","telegram-bot","weather-forecast"],"latest_commit_sha":null,"homepage":"","language":"Python","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/daya0576.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":"2020-06-26T08:43:54.000Z","updated_at":"2025-07-04T06:19:08.000Z","dependencies_parsed_at":"2023-01-29T16:30:50.265Z","dependency_job_id":"e0ca6c15-aaef-451f-9bd5-f40d38289ea3","html_url":"https://github.com/daya0576/he-weather-bot","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/daya0576/he-weather-bot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daya0576%2Fhe-weather-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daya0576%2Fhe-weather-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daya0576%2Fhe-weather-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daya0576%2Fhe-weather-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/daya0576","download_url":"https://codeload.github.com/daya0576/he-weather-bot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/daya0576%2Fhe-weather-bot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31405706,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T10:20:44.708Z","status":"ssl_error","status_checked_at":"2026-04-04T10:20:06.846Z","response_time":60,"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":["heroku","telegram","telegram-bot","weather-forecast"],"created_at":"2026-04-04T16:37:09.486Z","updated_at":"2026-04-04T16:37:12.395Z","avatar_url":"https://github.com/daya0576.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌧 QWeatherBot：基于和风天气的 Telegram 机器人\n\n![Active users](https://weather.changchen.me/users/count)\n![GitHub release (latest by date)](https://img.shields.io/github/v/release/daya0576/he-weather-bot?link=https://github.com/daya0576/he-weather-bot/releases/)\n![](https://img.shields.io/badge/Bot%20API-5.1-blue?logo=telegram)\n![Uptime Robot ratio (30 days)](https://img.shields.io/uptimerobot/ratio/m800876059-8ae4cb4cae57d1200261d8e6)\n\n\u003cimg src=\"https://github.com/daya0576/he-weather-bot/blob/master/static/demo.gif?raw=true\" width=\"600\"\u003e\n\n## ✨ Features\n\n- [x] 支持发送定位或地名关键词设置所在地\n- [x] 支持当日气温范围、晚间天气、天气灾害预警、次日天气播报\n- [x] 支持自定义时间订阅天气，自动推送\n- [x] 极端灾害天气预警（暴雨、台风等）\n- [x] 钉钉机器人消息同步\n- [ ] 多语言支持\n\n## 👉 使用说明\n\n无需部署开箱即用，戳链接调戏我：[t.me/he_weather_bot](https://t.me/he_weather_bot)\n\n```shell\nhelp - 帮助\nweather - 获取实时天气（最近两天）\nweather_6h - 获取实时天气（最近六小时）\nset_location - 更新位置\nset_api_key - 设置 API Key\nsubscribe - 开启订阅\nunsubscribe - 关闭订阅\nadd_sub_locations - 新增子位置（支持多个）\ndelete_sub_locations - 移除子位置\n```\n\n## ⚡️ 自部署\ndocker compose 配置文件参考：\n```shell\nservices:\n  app:\n    image: daya0576/he-weather-bot:latest\n    environment:\n      - ENV=production\n      - REDIS_URL=redis://redis:6379\n      - DATABASE_URL=postgresql://postgres:postgres@db:5432/he_weather_bot\n      - TELEGRAM_BOT_WEBHOOK_ENDPOINT=\u003cendpoint\u003e/hook\n      - TELEGRAM_BOT_API_KEY=\u003ctoken\u003e\n    depends_on:\n      - redis\n      - db\n    ports:\n      - \"18880:8080\"\n    networks:\n      - app-network\n  redis:\n    image: redis:alpine\n    # ports:\n    #   - \"6379:6379\"\n    volumes:\n      - redis-data:/data\n    networks:\n      - app-network\n  db:\n    image: postgres:14-alpine\n    environment:\n      - POSTGRES_USER=postgres\n      - POSTGRES_PASSWORD=postgres\n      - POSTGRES_DB=postgres\n    volumes:\n      - postgres-data:/var/lib/postgresql/data\n    networks:\n      - app-network\nvolumes:\n  redis-data:\n  postgres-data:\nnetworks:\n  app-network:\n    driver: bridge\n```\n\n## 🚀 实现原理\n\n[《如何零成本制作一个 telegram 机器人》](https://changchen.me/blog/20210221/buld-telegram-bot-from-scratch/)\n\n## FAQ\n\nQ. 有考虑支持多地区订阅吗(比如关心亲朋好友和出差人员)？  \n支持 `add_sub_locations `命令添加子城市，`delete_sub_locations` 命令清除。\n\nQ. 如何在群中播报？   \n第一步：在群用户里添加机器人   \n第二步：在群的输入框输入 / 符号，根据自动提示，点击输入 /help   \n第三步：点击卡片的“定时订阅”修改推送的时间   \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaya0576%2Fhe-weather-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdaya0576%2Fhe-weather-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaya0576%2Fhe-weather-bot/lists"}