npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

koishi-plugin-maibot

v1.7.33

Published

舞萌DX游戏高级操作插件 for Koishi - 支持用户绑定、B50更新、账号状态提醒、1.5倍票获取等功能

Readme

koishi-plugin-maibot

舞萌DX游戏高级操作插件 for Koishi

功能特性

  • ✅ 用户绑定(通过 SGWCMAID 二维码)
  • ✅ 用户解绑
  • ✅ 状态查询(实时获取账号信息,自动更新用户名和Rating)
  • ✅ 水鱼Token绑定/解绑
  • ✅ B50上传到水鱼(支持实时任务状态播报)
  • ✅ 落雪代码绑定/解绑
  • ✅ B50上传到落雪(支持实时任务状态播报)
  • ✅ B50任务状态查询(水鱼/落雪)
  • ✅ 收藏品管理(发收藏品/清收藏品,支持交互式选择类别)
  • ✅ 功能票管理(发票/清票)
  • ✅ 账号状态提醒(自动检测登录状态变化并群内通知)
  • ✅ 用户ID隐藏显示(防止盗号)
  • ✅ 完整的 API 调用封装
  • ✅ 数据库存储(SQLite/MySQL/PostgreSQL)

安装

npm install koishi-plugin-maibot

配置

koishi.yml 中配置:

plugins:
  maibot:
    apiBaseURL: http://localhost:5566  # 你的API服务地址
    apiTimeout: 30000  # 可选,默认30秒
    machineInfo:  # 必填,机台信息
      clientId: 你的客户端ID
      regionId: 你的区域ID
      placeId: 你的场所ID
      placeName: 你的场所名称
      regionName: 你的区域名称
    turnstileToken: 你的Turnstile Token  # 必填
    alertMessages:  # 可选,账号状态提醒消息配置
      loginMessage: '{playerid}{at} 你的账号已上线。'  # 上线消息(支持占位符:{playerid} 玩家名,{at} @用户)
      logoutMessage: '{playerid}{at} 你的账号已下线。'  # 下线消息

注意machineInfoturnstileToken 为必填配置,需要在配置文件中填写。

使用

绑定账号

/mai绑定 SGWCMAIDxxxxxxxxxxxxx

查询状态(自动更新用户名和Rating)

/mai状态

解绑账号

/mai解绑

绑定水鱼Token

/mai绑定水鱼 <token>

解绑水鱼Token

/mai解绑水鱼

上传B50到水鱼

/mai上传B50

查询B50任务状态(水鱼)

/mai查询B50

绑定落雪代码

/mai绑定落雪 <lxns_code>

解绑落雪代码

/mai解绑落雪

上传B50到落雪

/mai上传落雪b50          # 使用绑定的代码
/mai上传落雪b50 <code>   # 使用临时代码

查询落雪B50任务状态

/mai查询落雪B50

发收藏品

/mai发收藏品

交互式选择收藏品类别和ID(支持头像框、称号、头像、乐曲、解锁Master等12种类型)

清收藏品

/mai清收藏品

交互式选择收藏品类别和ID进行清空

发票(2-6倍)

/mai发票 [倍数]          # 默认2倍

清票

/mai清票

账号状态提醒

/maialert [on|off]              # 开关自己的播报功能
/maialert set <userId> [on|off] # 管理员设置他人的播报状态(需要auth等级3以上)

功能说明:

  • 默认关闭,需要用户主动开启
  • 每1分钟自动检查一次登录状态
  • 当账号从离线变为在线时,会在群内发送上线提醒
  • 当账号从在线变为离线时,会在群内发送下线提醒
  • 仅在状态变化时发送,避免刷屏
  • 支持自定义消息格式(在配置文件中设置)

API 要求

本插件需要配合 anti15-api 使用。

API 服务需要提供以下接口:

  • POST /api/qr2userid/<qr_text> - 二维码转用户ID
  • GET /api/preview?mai_uid=<encrypted_uid> - 用户状态预览

更多 API 文档请参考 API README。

许可证

MIT