cqhttp_bot
TypeScript icon, indicating that this package has built-in type declarations

0.1.6 • Public • Published

cqhttp-bot

使用正向 websocket 的 cqhttp bot

使用

// echo bot
import {QBot} from 'https://cdn.jsdelivr.net/gh/coolrc136/cqhttp-bot@main/deno_dist/mod.ts'

const bot = new QBot("ws://111.111.111.111:6700?access_token=123456")

bot.onmessage(msg=> {
    bot.send(JSON.stringify(
        msg.quick_reply(msg.message)
        )
    )
})
bot.run()

更多用法请参考 demo.ts

Readme

Keywords

Package Sidebar

Install

npm i cqhttp_bot

Weekly Downloads

1

Version

0.1.6

License

GPLv3

Unpacked Size

56.3 kB

Total Files

25

Last publish

Collaborators

  • coolrc