Skip to main content
NoneBotPluginLogo

NoneBotPluginText

nonebot-plugin-bili-dynamic

✨ B站动态/直播推送插件,支持图片渲染 ✨

license pypi python

📖 介绍

B站动态/直播推送插件,基于 Colter23 bilibili-dynamic-mirai-plugin v3 风格渲染图片。

  • 支持动态检测推送(文字/图文/视频/专栏/直播)
  • 支持直播开播提醒
  • 使用 Skia 引擎渲染卡片图片
  • 支持 HSB 渐变背景、半透明卡片、阴影效果

💿 安装

使用 nb-cli 安装 在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装
nb plugin install nonebot-plugin-bili-dynamic
使用包管理器安装 在 nonebot2 项目的插件目录下, 打开命令行, 根据你使用的包管理器, 输入相应的安装命令
pip
pip install nonebot-plugin-bili-dynamic
pdm
pdm add nonebot-plugin-bili-dynamic
poetry
poetry add nonebot-plugin-bili-dynamic

打开 nonebot2 项目根目录下的 pyproject.toml 文件, 在 [tool.nonebot] 部分追加写入

plugins = ["nonebot_plugin_bili_dynamic"]

⚙️ 配置

在 nonebot2 项目的.env文件中添加下表中的必填配置

配置项 必填 默认值 说明
bili_account__sessdata 否 空 B站 SESSDATA Cookie
bili_account__bili_jct 否 空 B站 bili_jct Cookie
push__max_age_hours 否 24 动态推送最大时效(小时),超过的仅记录不推送,0为不限制
live_report__enable 否 true 每日直播时长播报开关
live_report__time 否 18:00 每日时长播报时间(可用命令覆盖)
live_report__start_date 否 空 时长统计起始日期 YYYY-MM-DD,空为不限制(可用命令覆盖)

注意:嵌套配置项需使用双下划线 __ 连接,如 push__max_age_hours=48。

🎉 使用

指令表

指令 权限 需要@ 范围 说明
/bi add 群员 否 群/私聊 订阅UP主
/bi del 群员 否 群/私聊 取消订阅
/bi list 群员 否 群/私聊 查看订阅列表
/bi live 群员 否 群/私聊 查询直播状态
/bi new [n] 群员 否 群/私聊 查看最新n条动态
/bi login 群员 否 群/私聊 B站扫码登录
/bi color 群员 否 群/私聊 设置主题色
/bi livetime [UID] 群员 否 群/私聊 直播时长统计(今日+累计,可指定UID)
/bi livetime time HH:MM 管理员 否 群/私聊 设置每日时长播报时间
/bi livetime from <日期> 管理员 否 群/私聊 设置统计起始日期,如 2026-09-01 或 9-1

时长统计说明:插件自动记录每次开播/下播,每天到点(默认 18:00)向各群/私聊播报其订阅主播的时长统计卡片; 只能统计插件运行期间检测到的直播,功能上线前的历史直播无法补录。

📸 效果图

(TODO: 添加渲染效果图)

Metadata

Release files for nonebot-plugin-bili-dynamic 0.2.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nonebot-plugin-bili-dynamic 0.2.8
File Size Uploaded Provenance Actions
nonebot_plugin_bili_dynamic-0.2.8.tar.gz 52.9 kB Without provenance Details for nonebot_plugin_bili_dynamic-0.2.8.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nonebot-plugin-bili-dynamic 0.2.8
File Interpreter ABI Platform Actions
nonebot_plugin_bili_dynamic-0.2.8-py3-none-any.whl Python 3 none any Details for nonebot_plugin_bili_dynamic-0.2.8-py3-none-any.whl

Total release size: 105.9 kB

Release files / nonebot_plugin_bili_dynamic-0.2.8.tar.gz

Download URL nonebot_plugin_bili_dynamic-0.2.8.tar.gz
Size 52.9 kB
Tags Source
SHA-256 checksum
How to use checksums
965c0cf6b4788bf88d8ab58c952ab523ad43c21bcf53e065b51c7e62515efb93
BLAKE2b-256 checksum
How to use checksums
50ee9685ed49ab01832d27840e6f97e8d76bcbf09b24074317712f8ca7e2c246
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.9

Release files / nonebot_plugin_bili_dynamic-0.2.8-py3-none-any.whl

Download URL nonebot_plugin_bili_dynamic-0.2.8-py3-none-any.whl
Size 53.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
14b4c75e51a7d2e001aaea0b4f14aee21ef56d7a86e90fe0791efd92d7f44b29
BLAKE2b-256 checksum
How to use checksums
7896ab3aef3fe8b5c2eb63051227706e224a858c20c6bb17171276b92b5ab104
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.9

Security for nonebot-plugin-bili-dynamic 0.2.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page