Let bot look!!!
Project description
📖 介绍
此插件可以发送在 sleepy-project/sleepy 目前的状态信息,可以显示用户的设备是否在使用中,正在听的歌曲 (支持情况以 sleepy 项目为准),支持多设备状态列表
💿 安装
以下提到的方法 任选其一即可
[推荐] 使用 nb-cli 安装
在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装nb plugin install nonebot-plugin-areusleepy
使用包管理器安装
在 nonebot2 项目的插件目录下, 打开命令行, 根据你使用的包管理器, 输入相应的安装命令pip
pip install nonebot-plugin-areusleepy
pdm
pdm add nonebot-nonebot-plugin-areusleepy
poetry
poetry add nonebot-plugin-areusleepy
conda
conda install nonebot-plugin-areusleepy
uv
uv add nonebot-plugin-areusleepy
打开 nonebot2 项目根目录下的 pyproject.toml 文件, 在 [tool.nonebot] 部分的 plugins 项里追加写入
[tool.nonebot]
plugins = [
# ...
"nonebot_plugin_areusleepy"
]
⚙️ 配置
env 配置示例,变量后面为默认配置:
# 基本配置
sleepy_command="aresleepy" # 触发命令
sleepy_prompt_loading=true # 是否在发送消息前显示 "正在获取, 请稍候"
sleepy_show_details=false # 是否显示详细信息 (状态的 id, 设备的 id, 最后更新时间的时区)
# Sleepy 服务配置
sleepy_url="https://status.0d000721.xin" # Sleepy 服务地址, 必须以 http:// 或 https:// 开头, 不以 / 结尾
sleepy_timeout=5.0 # 请求超时 (秒)
sleepy_retries=3 # 重试次数
# sleepy 定时任务配置
sleepy_scheduler_enabled: bool = False # 是否启用定时任务
sleepy_scheduler_cron: str = '0 9,21 * * *' # Cron 表达式,默认每天 9:00 和 21:00
sleepy_scheduler_groups: List[str] = [] # 推送的群组列表,默认为空,开启定时任务后必须配置此项
🎉 使用
用法:
/sleepy- 查询配置中网站的在线状态/sleepy [url]- 查询其他网站的在线状态- 如:
/sleepy https://sleepy.wyf9.top - 注意:
url必须以http://或https://开头
- 如:
效果图
📞 联系
Sleepy 项目
QQ 群组: 点此加群 Discord: 点此加入服务器 更多联系方式
人较多, 请注明来意
本项目
TG群组:点此加入 QQ群:1049319982 作者邮箱:congyu@sbhfy.cn
大概率没人
💡 鸣谢
本项目基于 sleepy-project/sleepy: Are you sleeping?
感谢 Sleepy 开发者 wyf9 重构插件
📝 更新日志
0.1.0
重构插件
0.1.2
添加了定时任务
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nonebot_plugin_areusleepy-0.1.2.tar.gz.
File metadata
- Download URL: nonebot_plugin_areusleepy-0.1.2.tar.gz
- Upload date:
- Size: 6.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: pdm/2.24.2 CPython/3.13.3 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe1d4b55b08c6e32f88357d0e551f607a941d9648d60d13f649db5abdab37a82
|
|
| MD5 |
08c7dfdb05344c57b9b4de80c25f2c2d
|
|
| BLAKE2b-256 |
f318da15115fcc7ea17c8fce442f1d4de68d2eab4c2677b6c41da264c78e3bc0
|
File details
Details for the file nonebot_plugin_areusleepy-0.1.2-py3-none-any.whl.
File metadata
- Download URL: nonebot_plugin_areusleepy-0.1.2-py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: pdm/2.24.2 CPython/3.13.3 Windows/11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
79125ec1e7ce959c10d9927474fa484c5e165146657ed05acc0ee510a1e85473
|
|
| MD5 |
4f92432aa8cdfed73665fbc9bc07a1c7
|
|
| BLAKE2b-256 |
97782fa8005a2dc9a6af0a1f0cfe2d5cf2c0fbb7044af2a4ebd46c2a33de547c
|