use bilibili uid join in group
Project description
nonebot_plugin_BiliRequest
已实现功能
- 以B站UID审核入群(粉丝)
使用方法
点击DOWNLOAD ZIP
- 打开机器人目录下的 'pyproject.toml',一般是在第17行
17| plugin_dirs = ["XXX/XXX"] <- XXX为插件的路径
##| ^^^^^^^^^^^
-
将下载的文件放入 XXX/XXX目录下
-
重新加载插件
说明依赖
10| import json,time, requests
11| from nonebot import on_request, logger
12| from nonebot.adapters.onebot.v11 import Bot, GroupRequestEvent
注意事项
20| if event.group_id == <群号>: <- 直接替换成要使用的群号
##| ^^^^^^^
21| raw = json.loads(event.json())
22| gid = str(event.group_id)
23| uid = str(event.user_id)
24| flag = raw['flag']
34| if '<主播UID>' in response: <- 直接替换成主播UID
##| ^^^^^^^^^^
35| logger.info(f"同意{uid}加入群 {gid},验证消息为 “{comment}”")
36| await bot.set_group_add_request(
37| flag=flag,
38| sub_type=sub_type,
39| approve=True,
40| reason=' ',
41| )
未来计划
- Tips:如果在不咕的情况下
- 实现单插件分群管理
- 实现切换审核模式(粉丝/持有粉丝牌/等)
反馈问题
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for nonebot_plugin_BiliRequest-0.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7ce080ebee285da95042134e22276fe1f5fcefeb6f270cc4e24d2fe89d33e15 |
|
MD5 | 4f7ebfa222748078e8fbc8f12feb293a |
|
BLAKE2b-256 | 651a3527dc813b3e64655327bb6d02b5fe66a728e9a5b34cd0bcef9619d09926 |
Close
Hashes for nonebot_plugin_BiliRequest-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb15b4266d2511ac9277056fa52a97fb230b934e8c960bfbd0a7d524161cd7f5 |
|
MD5 | ca7e76f91578495b164e95b7aeb2ed0e |
|
BLAKE2b-256 | 5c304ac572e18cd6088e7813779614ec10d9b2e0ae5372ae3027f996c1057b49 |