Skip to main content

基于权限节点/权限组/特殊权限的Nonebot权限管理插件。

Project description

plugin-liteperm

基于权限节点+特殊权限+权限组的依赖权限管理插件!

本项目灵感来自于LuckPerms

NoneBot Plugin LitePerms 文档

📖 指令文档

通用命令结构

/lp [对象类型] [操作类型] [操作] [目标] [值]

用户权限管理 (lp user)

/lp user [用户ID] [操作类型] [操作] [目标节点/组] [值]

操作类型

  1. permission - 直接权限管理

    • set [节点] [true/false]:设置权限节点状态
    • del [节点]:删除权限节点
    • check [节点]:检查权限节点
    • list:列出所有权限
  2. parent - 继承组管理

    • add [组名]:添加继承组
    • del [组名]:移除继承组
    • set [组名]:覆盖为指定组的权限
  3. perm_group - 权限组管理

    • add [组名]:添加权限组
    • del [组名]:移除权限组

示例

/lp user 123456 permission set lp.admin true
/lp user 123456 parent add admin_group

群组权限管理 (lp group)

/lp group [群号] [操作类型] [操作] [目标节点/组] [值]

(参数格式与用户权限管理相同)


权限组管理 (lp perm_group)

/lp perm_group [组名] [操作类型] [操作] [目标节点/组] [值]

新增操作类型

  • to - 组操作
    • create:创建新权限组
    • remove:删除权限组

示例

/lp perm_group admin to create
/lp perm_group admin permission set system.* true

命令权限管理 (lp command)

/lp command [命令名] [操作类型] [操作] [权限节点] [值]

操作类型

  • set_permission:设置命令权限节点
  • command del:删除命令权限配置

示例

/lp command ping set_permission lp.user.ping true

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_liteperm-0.0.1.dev1.tar.gz (23.7 kB view details)

Uploaded Source

Built Distribution

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

nonebot_plugin_liteperm-0.0.1.dev1-py3-none-any.whl (30.6 kB view details)

Uploaded Python 3

File details

Details for the file nonebot_plugin_liteperm-0.0.1.dev1.tar.gz.

File metadata

File hashes

Hashes for nonebot_plugin_liteperm-0.0.1.dev1.tar.gz
Algorithm Hash digest
SHA256 ee68cfc8e4a5e74499234dbb89dce5908d65ee7c89cc82a635150280dfa9acda
MD5 3414c1366a502230b715f9cdcf44e22e
BLAKE2b-256 b68d5d785eabb88195238541fba0d763403ad2f313cbfbfd5a5ecb71aa6d9c54

See more details on using hashes here.

File details

Details for the file nonebot_plugin_liteperm-0.0.1.dev1-py3-none-any.whl.

File metadata

File hashes

Hashes for nonebot_plugin_liteperm-0.0.1.dev1-py3-none-any.whl
Algorithm Hash digest
SHA256 3a0ef419020d72f20d825587e1b342f9ff6734f1fc3f0be5d5ef54e1236343fd
MD5 9f5b93a335a0f40cf32625e19e6fbcd2
BLAKE2b-256 56e24c2eccc2e85b214cc969259fa3e3e36a7b19304b2a8e2ac3486c3e2e9f7e

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