Skip to main content

A Satori backend powered by lagrange-python

Project description

NekoBox

基于 lagrange-pythonSatori协议 实现,使用 satori-python

如何启动

使用稳定版(推荐)

# 安装环境
python -m pip install nekobox

# 可选依赖,用于支持非silk格式audio发送
python -m pip install pysilk-mod

# 跟随步骤生成配置文件后,使用手Q扫码即可登录
nekobox run

使用开发版

# 安装环境
git clone https://github.com/wyapx/nekobox
cd nekobox

python -m pip install .

# 可选依赖,用于支持非silk格式audio发送
python -m pip install pysilk-mod

# 跟随步骤生成配置文件后,使用手Q扫码即可登录
nekobox run

使用 PDM:

# 安装环境
git clone https://github.com/wyapx/nekobox
cd nekobox

pdm install

# 可选依赖,用于支持非silk格式audio发送
pdm sync --group audio

# 跟随步骤生成配置文件后,使用手Q扫码即可登录
pdm run nekobox run

CLI 工具

$ nekobox
usage: nekobox [-h] {run,gen,clear,default} ...

NekoBox/lagrange-python-satori Server 工具

options:
  -h, --help            show this help message and exit
  -v, --version         show program's version number and exit

commands:
  {run,gen,list,show,clear,delete,default}
    run                 启动服务器
    gen                 生成或更新配置文件
    list                列出所有账号
    show                显示账号配置
    clear               清除数据
    delete              删除账号配置
    default             设置默认账号

生成或更新配置文件

使用 nekobox gen 生成或更新配置文件。

当未传入 uin 参数或 uin? 时,若配置文件已存在则会出现交互式选择:

$ nekobox gen
正在更新配置文件...
 - 987654
 - 123456
请选择一个账号 (987654):

启动服务器

使用 nekobox run 启动服务器。

  • 若未传入 uin 参数,会使用默认账号(可由 nekobox default 指定)。
  • uin?,会出现交互式选择。
$ nekobox run ?
- 987654
- 123456
请选择一个账号 (987654):
  • 可以使用 --debug 参数强制日志启用调试等级。

特性支持情况

  1. 消息类型

    • Text
    • At, AtAll
    • Image
    • Quote
    • Audio
  2. 主动操作

    • message-create
    • message-delete 部分支持:群聊
    • message-get 部分支持:群聊
    • guild-member-kick
    • guild-member-mute
    • guild-member-get
    • guild-member-list
    • guild-list
    • channel-list
    • login-get
    • user-channel-create 用于向 user 发起私聊 (前提是好友)
    • guild-member-approve
    • friend-list
    • reaction-create
    • reaction-delete
    • reaction-clear
  3. 事件

    • message-created
    • message-deleted 部分支持:群聊
    • guild-member-added
    • guild-member-removed
    • guild-updated 群名更改
    • guild-member-request
    • reaction-added
    • reaction-deleted

由于大多数事件和操作没有标准参考,特性的新增可能需要一些时间.

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

nekobox-0.1.3.tar.gz (32.2 kB view details)

Uploaded Source

Built Distribution

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

nekobox-0.1.3-py3-none-any.whl (35.9 kB view details)

Uploaded Python 3

File details

Details for the file nekobox-0.1.3.tar.gz.

File metadata

  • Download URL: nekobox-0.1.3.tar.gz
  • Upload date:
  • Size: 32.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: pdm/2.19.2 CPython/3.12.3 Linux/6.8.0-1015-azure

File hashes

Hashes for nekobox-0.1.3.tar.gz
Algorithm Hash digest
SHA256 a057e66fbd821669da5bf24f01606eb32c1651aa54509a280384f0ae6d41f506
MD5 184ecc292cf7d9989d6237e21eb60180
BLAKE2b-256 e4c43b2aa2e346b78138461bc06545309b3ffc5a24eb39beb96a5f47b39374b5

See more details on using hashes here.

File details

Details for the file nekobox-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: nekobox-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 35.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: pdm/2.19.2 CPython/3.12.3 Linux/6.8.0-1015-azure

File hashes

Hashes for nekobox-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 2ed89d1712e190566f34e74694a1bce8942c9640e0fbbb571e0fea611aca08e4
MD5 f253f8c13a24920445a67b8b4e96bdbd
BLAKE2b-256 4a84b05b0903e1180184c6f1ea8d8f0d861c350656db023c7012d4e6510b1c2c

See more details on using hashes here.

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