Closed YuziO2 closed 1 year ago
group
字段传一个 number
试试。
group
字段传一个number
试试。
问题依然存在
group
对应的 qq 群存在,换到其他 qq 群问题仍然存在friend:
问题仍然存在
- 确定
group
对应的 qq 群存在,换到其他 qq 群问题仍然存在- 换到
friend:
问题仍然存在
确定,都试过了
我这里无法复现,看看还有没有什么补充信息?
Mirai-Console 2.14.0 mirai-api-http 2.9.1 mirai-js 2.8.11
index.js:
const { Bot, Message } = require('mirai-js');
const bot = new Bot();
async function main() {
// 连接到一个 mirai-api-http 服务
await bot.open({
baseUrl: 'http://127.0.0.1:9292',
verifyKey: 'kkkk',
// 要绑定的 qq,须确保该用户已在 mirai-console 登录
qq: 1111,
});
await bot.sendMessage({
// 好友 qq 号
group: 101111,
// Message 实例,表示一条消息
message: new Message().addText('hello world!')
});
}
main()
启动命令:node ./index.js
安装方式: npm i mirai-js
报错是在sendMessage那一行发生的
我去,我重启了一下服务器,发现好了,我大意了啊
代码:
报错如下:
mirai和http-api都是最新的