1.2.0 • Published 4 years ago
cqbot v1.2.0
CQBot
介绍
基于 cqhttp 客户端的 nodejs 开发框架。
安装
npm install cqbot
使用
const server = require('http').createServer()
const { CQBot } = require('cqbot')
const cqbot = new CQBot()
cqbot.start(server)
server.listen(3000)
修改 CQ 客户端部分配置:
"ws_reverse_servers": [
{
"enabled": true,
"reverse_url": "",
"reverse_api_url": "ws://localhost:3000/api",
"reverse_event_url": "ws://localhost:3000/event",
"reverse_reconnect_interval": 3000
}
]
具体请阅读文档