Files
Auto_Bangumi/examples/plugins/webhook-on-event
Estrella Pan a1adf237b8 feat(4.0-P7): 新增 5 个示例插件,逐个运行契约与行为测试
- webhook-on-event、custom-rss-site、template-rename、nfo-writer、ntfy-notifier
- scripts/test_example_plugins.sh 对每个示例运行 ab-plugin validate 与自带测试
- 宿主侧测试把全部示例载入 PluginManager,断言 Provider 与钩子已登记
- NotifierContract 发现 ntfy 示例的中文标题请求头缺陷,已改用 bytes 请求头
2026-10-08 14:50:59 +02:00
..

事件 Webhook(示例插件)

把选中的事件以 JSON POST 到一个 URL。演示:

  • @subscribe("*") 订阅全部事件,按配置过滤
  • config_model(WebUI 自动生成表单)与 secret_field(密码框、读取时掩码)
  • 用 ab_sdk.testing.create_plugin 在不启动 AutoBangumi 的情况下测试

安装

cp -r examples/plugins/webhook-on-event config/plugins/local/

在「设置 → 插件」中开启「允许未签名插件」,启用并填写地址。

测试

cd examples/plugins/webhook-on-event && uv run pytest