Skip to main content

NoneBot plugin for pushing ani-rss/emby webhooks to QQ

Reason this release was yanked:

请使用0.2.4以上版本

Project description

NoneBotPluginLogo

nonebot-plugin-AniPusher

✨ NoneBot AniPusher插件 ✨
NoneBot AniPusher插件 是将特定Webhooks消息推送至QQ的插件
目前支持配置来自ani-rss和emby的webhooks消息

license pypi python

📖 介绍

AniPusher插件 是将特定Webhook消息推送至QQ的插件

目前支持AniRSS和Emby推送

show

💿 安装

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

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

plugins = ["nonebot_plugin_AniPusher"]

⚙️ ani-rss配置[ani-rss项目地址]

该配置方法基于ani-rss v2.0.13 更新后新的通知配置功能

ani-rss → 设置 → 通知 → 添加通知
↓按如下配置↓
ani-rss-config

通知类型为Webhook
Method为POST
URL为Nonebot2的IP地址和端口下的路径/webhook
例如http://Nonebot_IP:8080/webhook

↓Body请复制下方Json填入↓

{
  "ani": "${action}",
  "action": "${action}",
  "title": "${title}",
  "jpTitle": "${jpTitle}",
  "score": "${score}",
  "themoviedbName": "${themoviedbName}",
  "tmdbid": "${tmdbid}",
  "tmdbUrl": "${tmdburl}",
  "bgmUrl": "${bgmUrl}",
  "season": "${season}",
  "episode": "${episode}",
  "subgroup": "${subgroup}",
  "progress": "${currentEpisodeNumber}/${totalEpisodeNumber}",
  "premiere": "${year}-${month}-${date}",
  "text": "${text}",
  "downloadPath": "${downloadPath}",
  "episodeTitle": "${episodeTitle}",
  "bgmEpisodeTitle": "${bgmEpisodeTitle}",
  "bgmJpEpisodeTitle": "${bgmJpEpisodeTitle}",
  "image": "${image}"
}

[!TIP] 如果未来AniRSS更新通知配置发生变化,需更改Body结构时,请保留键"ani": "${action}",程序判断数据来源依赖此键!
其余键值对可根据ani-rss的使用文档中通知下的通知模板对应的键结构进行更改

⚙️ Emby配置

首先请确保你已在Emby服务器上安装了Webhooks插件(该插件目前已自动集成,应该不用再手动装了)

Emby → 设置 → 通知 → 添加通知 -> Webhooks
↓按如下配置↓
embv-config

网址为Nonebot2的IP地址和端口下的路径/webhook
例如http://Nonebot_IP:8080/webhook
请求内容类型为application/json
Event目前只支持媒体库-新媒体已添加
其他选项根据自身需求更改

⚙️ 插件配置

配置项位于 nonebot2 项目根目录下的 .env 文件内
运行时如果没有检查到配置项,插件将自动在.env 文件内创建配置项,前往按照说明填入即可。
所有配置项均为非必选项,但建议填写。配置项缺失会导致对应功能被关闭。

[!IMPORTANT] 缺少Emby_Host或Emby_ApiKey时,插件将无法验证视觉图有效性,不会下载或更新封面图片。
缺少Tmdb_ApiKey时,插件将无法验证TMDB ID,导致数据无法存入数据库,无法订阅对应内容。
缺少Tmdb_Proxy时,插件将仅尝试直连TMDB API,如失败则无法验证TMDB ID,导致数据无法存入数据库,无法订阅对应内容。

配置项 必填 默认值 说明
anipush__emby_host Emby的服务器地址(请勿填写中转地址)
anipush__emby_apikey Emby服务器-高级-API密钥中生成的密钥
anipush__tmdb_apikey TMDB用户的ApiKey
anipush__tmdb_proxy TMDB代理,如不填写则不使用代理

🎉 使用

指令表

指令 权限 需要@ 范围 说明
注册Emby推送 ALL 私聊/群聊 群聊:发送指令后即将群组添加到Emby更新消息推送列表中,有新消息时将消息推送到群内
私聊:发送指令后即将用户添加到Emby更新消息推送列表中
注册AniRSS推送 ALL 私聊/群聊 群聊:发送指令后即将群组添加到AniRSS更新消息推送列表中,有新消息时将消息推送到群内
私聊:发送指令后即将用户添加到AniRSS更新消息推送列表中
取消Emby推送 ALL 私聊/群聊 群聊:发送指令后关闭群组更新消息推送,不再接收推送
私聊:发送指令后关闭用户更新消息推送,不再接收推送
取消AniRSS推送 ALL 私聊/群聊 群聊:发送指令后关闭群组更新消息推送,不再接收推送
私聊:发送指令后关闭用户更新消息推送,不再接收推送

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nonebot_plugin_anipusher-0.1.5.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nonebot_plugin_anipusher-0.1.5-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file nonebot_plugin_anipusher-0.1.5.tar.gz.

File metadata

  • Download URL: nonebot_plugin_anipusher-0.1.5.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nonebot_plugin_anipusher-0.1.5.tar.gz
Algorithm Hash digest
SHA256 b300028ab97dac1946916b3345c2a34bb722eead08febef6de50091a8adf7ec0
MD5 fee6880910b9b90718516c139d46b52d
BLAKE2b-256 6aa7b94566fe4e5b82646c0db25f931e9f36f973779be02f68767c80d99949a9

See more details on using hashes here.

Provenance

The following attestation bundles were made for nonebot_plugin_anipusher-0.1.5.tar.gz:

Publisher: pypi-publish.yml on AriadusTT/nonebot-plugin-anipusher

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file nonebot_plugin_anipusher-0.1.5-py3-none-any.whl.

File metadata

File hashes

Hashes for nonebot_plugin_anipusher-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 338995d9d0caf3763a23e26656cf3941a5860ff3cdddd96d8e39571c6cc7f50a
MD5 14836f1da0e26c1c1b3a84ed52f682c8
BLAKE2b-256 1d591a251aee8012ba6965966205686fc248876b560d796ccc80944603ea4d11

See more details on using hashes here.

Provenance

The following attestation bundles were made for nonebot_plugin_anipusher-0.1.5-py3-none-any.whl:

Publisher: pypi-publish.yml on AriadusTT/nonebot-plugin-anipusher

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page