{"id":19493134,"url":"https://github.com/oreoslab/bili","last_synced_at":"2025-04-25T20:31:03.817Z","repository":{"id":37387461,"uuid":"415531353","full_name":"OreosLab/bili","owner":"OreosLab","description":null,"archived":false,"fork":false,"pushed_at":"2023-03-01T03:59:18.000Z","size":16697,"stargazers_count":135,"open_issues_count":14,"forks_count":53,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-04T03:11:32.078Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://oreos.ml/script/2021-10-15-BILIBILI-HELPER.html","language":"Java","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/OreosLab.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":"2021-10-10T08:46:23.000Z","updated_at":"2025-04-01T10:56:00.000Z","dependencies_parsed_at":"2024-11-10T21:26:44.515Z","dependency_job_id":"bf54c7df-3e7b-49e2-b701-84c4927adf9b","html_url":"https://github.com/OreosLab/bili","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OreosLab%2Fbili","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OreosLab%2Fbili/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OreosLab%2Fbili/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OreosLab%2Fbili/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OreosLab","download_url":"https://codeload.github.com/OreosLab/bili/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250890275,"owners_count":21503461,"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":[],"created_at":"2024-11-10T21:24:32.270Z","updated_at":"2025-04-25T20:31:03.413Z","avatar_url":"https://github.com/OreosLab.png","language":"Java","readme":"\u003cdiv align=\"center\"\u003e\n\u003ch1 align=\"center\"\u003eBILIBILI-HELPER\u003c/h1\u003e\n\n[![GitHub stars](https://img.shields.io/github/stars/OreosLab/bili?style=flat-square)](https://github.com/OreosLab/bili/stargazers)\n[![GitHub forks](https://img.shields.io/github/forks/OreosLab/bili?style=flat-square)](https://github.com/OreosLab/bili/network)\n[![GitHub issues](https://img.shields.io/github/issues/OreosLab/bili?style=flat-square)](https://github.com/OreosLab/bili/issues)\n[![GitHub license](https://img.shields.io/github/license/OreosLab/bili?style=flat-square)](https://github.com/OreosLab/bili/blob/main/LICENSE)\n[![GitHub All Releases](https://img.shields.io/github/downloads/OreosLab/bili/total?style=flat-square)](https://github.com/OreosLab/bili/releases)\n[![Docker Pulls](https://img.shields.io/docker/pulls/superng6/bilibili-helper?style=flat-square)](https://hub.docker.com/r/superng6/bilibili-helper)\n[![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/OreosLab/bili?style=flat-square)](https://github.com/OreosLab/bili/releases)\n[![Hits](https://hits.seeyoufarm.com/api/count/incr/badge.svg?url=https%3A%2F%2Fgithub.com%2FJunzhouLiu%2FBILIBILI-HELPER-PRE\u0026count_bg=%2379C83D\u0026title_bg=%23555555\u0026icon=\u0026icon_color=%23E7E7E7\u0026title=hits\u0026edge_flat=true)](https://hits.seeyoufarm.com)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FJunzhouLiu%2FBILIBILI-HELPER-PRE.svg?type=small)](https://app.fossa.com/projects/git%2Bgithub.com%2FJunzhouLiu%2FBILIBILI-HELPER-PRE?ref=badge_small)\n\n\u003c/div\u003e\n\n## 工具简介\n\n这是一个利用 Linux 定时任务、Java Jar、云函数、Docker、青龙面板等方式完成哔哩哔哩（Bilibili）每日投币、赛事预测、点赞、分享视频、直播签到、银瓜子兑换硬币、漫画每日签到等任务，简单配置即可每日轻松获取 65 经验值，快来和我一起成为 Lv6 吧 \\~\\~\\~\\~\n\n**如果觉得好用，顺手点个 Star 吧 ❤**\n\n~~**仓库地址：[JunzhouLiu/BILIBILI-HELPER](https://github.com/OreosLab/bili)**~~\n\n**请不要滥用相关 API，让我们一起爱护 B 站 ❤**\n\n## 功能列表\n\n* [x] 通过 docker 或者云函数执行定时任务。_【运行时间可自定义】_\n* [x] 哔哩哔哩漫画每日自动签到，自动阅读 1 章节。\n* [x] 每日自动从热门视频中随机观看 1 个视频，分享一个视频。\n* [x] 每日从热门视频中选取 5 个进行智能投币。_【如果投币不能获得经验了，则不会投币】_\n* [x] 投币支持下次一定啦，可自定义每日投币数量。_【如果检测到你已经投过币了，则不会投币】_\n* [x] 大会员月底使用快到期的 B 币券，给自己充电，一点也不会浪费哦，默认开启。_【已支持给指定 UP 充电】_\n* [x] 大会员月初 1 号自动领取每月 5 张 B 币券和福利。\n* [x] 每日哔哩哔哩直播自动签到，领取签到奖励。_【直播你可以不看，但是奖励咱们一定要领】_\n* [x] 投币策略更新可配置投币喜好。_【可配置优先给关注的 up 投币】_\n* [x] 自动送出即将过期的礼物。_【默认开启，未更新到新版本的用户默认关闭】_\n* [x] 支持推送执行结果到微信，钉钉，飞书等。\n* [x] 支持赛事预测。_【支持反向预测】_\n\n[点击快速开始使用](#一快速使用)\n\n[点击快速查看自定义功能配置](#自定义功能配置)\n\n# 目录\n\n* [目录](#目录)\n  * [开始使用](#开始使用)\n    * [获取执行所需的 cookies](#获取执行所需的-cookies)\n    * [一、快速使用](#一快速使用)\n    * [二、使用 Docker](#二使用-docker)\n    * [三、使用腾讯云函数](#三使用腾讯云函数)\n    * [四、使用 GitLab CI/CD](#四使用-gitlab-cicd)\n    * [五、使用青龙管理面板](#五使用青龙管理面板)\n  * [自定义功能配置](#自定义功能配置)\n    * [配置文件参数](#配置文件参数)\n  * [免责声明](#免责声明)\n  * [API 参考列表](#api-参考列表)\n  * [致谢](#致谢)\n  * [讨论群](#讨论群)\n  * [License](#license)\n  * [Stargazers over time](#stargazers-over-time)\n\n## 开始使用\n\n### 获取执行所需的 cookies\n\n1. 浏览器打开并登录 [bilibili][1] 网站。\n2. 按 F12 打开 「开发者工具」 打开 网络/NetWork -\u003e 找到并点击 nav 请求。\n3. 下拉请求详情，复制完整的 cookie 和 UA 备用。cookie 和 ua 只需要选中，右键复制值即可。\n\n![准备 cookie](docs/images/ck.webp)\n\n[1]: https://www.bilibili.com/\n\n### 一、快速使用\n\n* **需要本地有 Java8 执行环境。**\n\n1. 点击 [bili/release][3]，下载已发布的版本，解压后压缩包内应该包含一个 jar 包和一份`config.json`文件。\n2. 将获取的到的 `Cookie` 字符串和 UA 字符串填写到 `config.json` 中的 `biliCookies` 和 `userAgent` 字段值中。\n3. 在当前目录执行 `java -jar BILIBILI-HELPER.jar` 即可开始执行任务。如果 `config.json` 和 jar 包不在同一目录，可通过例如 `java -jar BILIBILI-HELPER.jar /tmp/config.json` 的方式指定特定路径的配置文件。\n\n[3]: https://github.com/OreosLab/bili/releases/latest\n\n### 二、使用 Docker\n\n* **基于本项目的 docker 封装项目：[SuperNG6/docker-bilibili-helper](https://github.com/SuperNG6/docker-bilibili-helper)**\n\n* **基于本项目的 docker 镜像：[superng6/bilibili-helper](https://hub.docker.com/r/superng6/bilibili-helper)**\n\n### 三、使用腾讯云函数\n\n* **请参考[腾讯云函数部署](docs/scf.md)**\n\n### 四、使用 GitLab CI/CD\n\n* **请参考[GitLab CI/CD 部署](docs/gitlab.md)**\n\n### 五、使用青龙管理面板\n\n* **青龙一键拉取命令 `ql raw https://raw.githubusercontent.com/OreosLab/bili/main/bilibili_helper.sh`**\n* **[青龙管理面板部署](docs/qinglong.md)**\n\n## 自定义功能配置\n\n注意：通常配置文件需要和 jar 包放置在同一目录，如果不在同一目录，请在执行命令后指定配置文件路径。**cookie 信息属于敏感信息，请不要提供给他人，谨防账号泄露或被盗。**\n\n**配置文件示例：**\n\n```json\n{\n  \"biliVerify\": {\n    \"biliCookies\": \"你的bilibili cookies\"\n  },\n  \"taskConfig\": {\n    \"skipDailyTask\": false,\n    \"matchGame\": false,\n    \"showHandModel\": false,\n    \"predictNumberOfCoins\": 1,\n    \"minimumNumberOfCoins\": 100,\n    \"taskIntervalTime\": 20,\n    \"numberOfCoins\": 5,\n    \"coinAddPriority\": 1,\n    \"reserveCoins\": 10,\n    \"selectLike\": 0,\n    \"monthEndAutoCharge\": true,\n    \"giveGift\": true,\n    \"silver2Coin\": true,\n    \"upLive\": \"0\",\n    \"chargeForLove\": \"14602398\",\n    \"chargeDay\": 25,\n    \"devicePlatform\": \"ios\",\n    \"userAgent\": \"你的浏览器UA\"\n  },\n  \"pushConfig\": {\n    \"SC_KEY\": \"\",\n    \"SCT_KEY\": \"\",\n    \"TG_BOT_TOKEN\": \"\",\n    \"TG_USER_ID\": \"\",\n    \"TG_USE_CUSTOM_URL\": false,\n    \"DING_TALK_URL\": \"\",\n    \"DING_TALK_SECRET\": \"\",\n    \"PUSH_PLUS_TOKEN\": \"\",\n    \"WE_COM_GROUP_TOKEN\": \"\",\n    \"WE_COM_APP_CORPID\": \"\",\n    \"WE_COM_APP_CORP_SECRET\": \"\",\n    \"WE_COM_APP_AGENT_ID\": 0,\n    \"WE_COM_APP_TO_USER\": \"\",\n    \"WE_COM_APP_MEDIA_ID\": \"\",\n    \"PROXY_HTTP_HOST\": \"\",\n    \"PROXY_SOCKET_HOST\": \"\",\n    \"PROXY_PORT\": 0\n  }\n}\n```\n\n~~**如果不知道自己的浏览器 UA 之类数据，以及看不懂每个值的含义，可以采用[配置生成网页](https://utils.misec.top/)生成自己的配置（暂未支持 v2.0.x 版本）**~~\n\n### 配置文件参数\n\n**biliVerify**\n\n| Key(字段)   | Value(值) | 说明                                       |\n| ----------- | --------- | ------------------------------------------ |\n| biliCookies | str       | bilibili 的 cookie，获取方式请查看使用说明 |\n\n**taskConfig**\n\n| Key(字段)            | Value(值)             | 说明                                                                               |\n| -------------------- | --------------------- | ---------------------------------------------------------------------------------- |\n| matchGame            | [false, true]         | 是否开启赛事预测。                                                                 |\n| showHandModel        | [false, true]         | `true` ：压赔率高的， `false` ：压赔率低的。                                       |\n| predictNumberOfCoins | [1, 10]               | 单次预测的硬币数量，默认为 `1` 。                                                  |\n| minimumNumberOfCoins | [1, 无穷大]           | 预留的硬币数，低于此数量不执行赛事预测。                                           |\n| taskIntervalTime     | [1, 无穷大]           | 任务之间的执行间隔，默认 `10` 秒，云函数用户不建议调整的太长，注意免费时长。       |\n| numberOfCoins        | [0, 5]                | 每日投币数量，默认 `5` ，为 `0` 时则不投币。                                       |\n| reserveCoins         | [0, 4000]             | 预留的硬币数，当硬币余额小于这个值时，不会进行投币任务，默认值为 `50` 。           |\n| selectLike           | [0, 1]                | 投币时是否点赞，默认 `0` ， `0` ：否 `1` ：是。                                    |\n| monthEndAutoCharge   | [false, true]         | 年度大会员月底是否用 B 币券自动充电，默认 `true` 。                                |\n| chargeDay            | [1, 28]               | 充电日期，默认为每月 `28` 号。                                                     |\n| chargeForLove        | [充电对象的 uid]      | 给指定 up 主充电，可填写充电对象的 UID，默认给作者充电。                           |\n| giveGift             | [false, true]         | 直播送出即将过期的礼物，默认开启，如需关闭请改为 `false` 。                        |\n| upLive               | [0, 送礼 up 主的 uid] | 直播送出即将过期的礼物，可填写指定 up 主的 UID ，为 `0` 时则随随机选取一个 up 主。 |\n| silver2Coin          | [false, true]         | 银瓜子兑换硬币，默认开启，如需关闭请改为 `false` 。                                |\n| devicePlatform       | [ios, android]        | 手机端漫画签到时的平台，建议选择你设备的平台 ，默认 `ios` 。                       |\n| coinAddPriority      | [0, 1]                | `0` ：优先给热榜视频投币， `1` ：优先给关注的 up 投币。                            |\n| userAgent            | 浏览器 UA             | 你的浏览器的 UA。                                                                  |\n| skipDailyTask        | [false, true]         | 是否跳过每日任务，默认 `true` ，如果关闭跳过每日任务，请改为 `false` 。            |\n\n* **默认配置文件的充电选项配置的是给开发者充电，给自己充电或者给其他 up 主充电，请改为对应的 uid**\n* ~~**userAgent 建议使用你自己真实常用浏览器 UA，如果不知道自己的 UA 请到[配置生成页面查看你的 UA](https://utils.misec.top/)**~~\n\n**pushConfig**\n\n| 字段类型        | Key(字段)              | Value(值)     | 说明                                                                                    |\n| --------------- | ---------------------- | ------------- | --------------------------------------------------------------------------------------- |\n| server 酱       | SC_KEY                 | str           | Server 酱老版本 key，SCU 开头的                                                         |\n| server 酱 turbo | SCT_KEY                | str           | Server 酱 Turbo 版本 key，SCT 开头的                                                    |\n| Telegram        | TG_USE_CUSTOM_URL      | [false, true] | 是否开启 TGbot API 反代                                                                 |\n| Telegram        | TG_BOT_TOKEN           | str           | TG 推送 bot_token，若开启反代，需填写完整反代 url `https://api.mytelegram.org/botTOKEN` |\n| Telegram        | TG_USER_ID             | str           | TG 推送的用户/群组/频道 ID                                                              |\n| PUSH PLUS       | PUSH_PLUS_TOKEN        | str           | push plus++ 推送的 `token`                                                              |\n| 钉钉            | DING_TALK_URL          | str           | 钉钉推送的完整 URL，e.g. `https://oapi.dingtalk.com/robot/send?access_token=xxx`        |\n| 钉钉            | DING_TALK_SECRET       | str           | 钉钉推送的密钥                                                                          |\n| 正向推送代理    | PROXY_HTTP_HOST        | str           | 推送使用 HTTP 正向代理，e.g. `127.0.0.1`                                                |\n| 正向推送代理    | PROXY_SOCKET_HOST      | str           | 推送使用 SOCKS(V4/V5)正向代理，e.g. `127.0.0.1`                                         |\n| 正向推送代理    | PROXY_PORT             | int           | 推送正向代理的端口，默认 0 不代理                                                       |\n| 企业微信群消息  | WE_COM_TOKEN           | str           | 企业微信，群消息非应用消息                                                              |\n| 企业微信应用    | WE_COM_APP_CORPID      | str           | 企业 id 获取方式参考：[获取][4]                                                         |\n| 企业微信应用    | WE_COM_APP_CORP_SECRET | str           | 应用的凭证密钥                                                                          |\n| 企业微信应用    | WE_COM_APP_AGENT_ID    | int           | 企业应用的 id，整型                                                                     |\n| 企业微信应用    | WE_COM_APP_TO_USER     | str           | 指定接收消息的成员，成员 ID 列表 默认为@all                                             |\n| 企业微信应用    | WE_COM_APP_MEDIA_ID    | str           | 缩略图的 media_id，可以通过素材[管理接口][5]获得。（为空发送**文本消息**）              |\n\n[4]: https://work.weixin.qq.com/wework_admin/frame#profile\n\n[5]: https://work.weixin.qq.com/wework_admin/frame#material/image\n\n* **tips: `PROXY_HTTP_HOST` 和 `PROXY_SOCKET_HOST` 仅需填写一个。**\n* **tips: 钉钉推送密钥可不填，不填仅用关键词验证。**\n* **获取 `media_id` 的方式请参考 `docs/images/media_id.png`**\n\n## 免责声明\n\n1. 本项目最初是我自己学习之余练手给自己写的小工具，自己学习之余上传到 GitHub，100% 源码公开，各位使用者请勿滥用。\n2. 本项目不会增加，也不存在类似于自动转发抽奖，秒杀，下载版权受限视频等侵犯 UP 主 / B 站权益的功能，本项目在使用过程中不会记录上传任何用户的敏感数据。\n3. **请妥善保管自己的账号和密码以及类似 Cookie 等敏感信息，不要把自己的敏感信息提供给他人，谨防账号泄露或被盗，这是很危险的行为。**（**网络安全教育普及任重而道远**）\n4. 本工具源码仅在 [JunzhouLiu/BILIBILI-HELPER-PRE](https://github.com/JunzhouLiu/BILIBILI-HELPER-PRE) 开源。\n5. 任何单位或个人因下载使用本开源项目代码而产生的任何意外、疏忽、合约毁坏、诽谤、版权或知识产权侵犯及其造成的损失（包括但不限于直接、间接、附带或衍生的损失等），项目维护者不承担任何法律责任。\n6. 本项目采用 [MIT License](https://github.com/OreosLab/bili/blob/main/LICENSE) 若违反本免责声明条款或违反法律法规所造成的法律责任(包括但不限于民事赔偿和刑事责任），由使用者自行承担。\n7. 使用本项目视为明确并同意本声明条款列举的全部内容，对使用本项目可能存在的风险和相关后果将完全由使用者自行承担，项目维护者不承担任何法律责任。\n\n## API 参考列表\n\n* [SocialSisterYi/bilibili-API-collect](https://github.com/SocialSisterYi/bilibili-API-collect)\n* [happy888888/BiliExp](https://github.com/happy888888/BiliExp)\n\n## 致谢\n\n感谢 JetBrains 对本项目的支持。\n\n[![JetBrains](docs/images/jetbrains.svg)](https://www.jetbrains.com/?from=BILIBILI-HELPER-PRE)\n\n## 讨论群\n\nqq 群二维码\n\n![qq群二维码](docs/images/qqgroup.png)\n\n[也可点击此处一键加群](https://qm.qq.com/cgi-bin/qm/qr?k=m_M1Fydi3MvrVAEM0Sp6hDfZF4N2SpXU\u0026jump_from=webapi)\n\n## License\n\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FJunzhouLiu%2FBILIBILI-HELPER-PRE.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2FJunzhouLiu%2FBILIBILI-HELPER-PRE?ref=badge_large)\n\n## Stargazers over time\n\n[![Stargazers over time](https://starchart.cc/OreosLab/bili.svg)](https://starchart.cc/OreosLab/bili)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foreoslab%2Fbili","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foreoslab%2Fbili","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foreoslab%2Fbili/lists"}