Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/Karlatemp/mirai-websocket-api

Mirai WebSocket API (console) plugin
https://github.com/Karlatemp/mirai-websocket-api

mirai mirai-console mirai-plugin mirai-websocket-api

Last synced: about 2 months ago
JSON representation

Mirai WebSocket API (console) plugin

Awesome Lists containing this project

README

        


logo

title

----

[![Gitter](https://badges.gitter.im/mamoe/mirai.svg)](https://gitter.im/mamoe/mirai?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
[![Actions Status](https://github.com/mamoe/mirai-api-http/workflows/Gradle%20CI/badge.svg)](https://github.com/mamoe/mirai-api-http/actions)

Mirai 是一个在全平台下运行,提供 QQ Android 和 TIM PC 协议支持的高效率机器人框架

这个项目的名字来源于

京都动画作品《境界的彼方》栗山未来(Kuriyama Mirai)


CRYPTON初音未来为代表的创作与活动(Magical Mirai)


图标以及形象由画师DazeCake绘制

# mirai-websocket-api
Mirai WebSocket API (console) plugin

Mirai-WebSocket-Api 插件 提供WebSocket API供所有语言使用mirai

## 开始使用
0. 请首先运行[Mirai-console](https://github.com/mamoe/mirai-console)相关客户端生成plugins文件夹
1. 将`mirai-websocket-api`生成的`jar包文件`放入`plugins`文件夹中
2. 编辑`config/MiraiWSApi/config.yml`配置文件 (没有则自行创建)
3. 再次启动[Mirai-console](https://github.com/mamoe/mirai-console)相关客户端
4. 记录日志中出现的 `user` 和 `passwd`

#### config.yml模板

```yaml
## 该配置为全局配置,对所有Session有效

# 可选,默认值为0.0.0.0
host: '0.0.0.0'

# 可选,默认值为7247
port: 7247

# 可选, 鉴权系统使用的用户名
user: root

# 必须, 默认密码为 ROOT, 必须修改
passwd: ROOT

# 是否在广播信息时使用 pettyPrint
pettyPrint: false

replyCache:
maximumSize: 2000
expireTime: 2
expireTimeUnit: HOURS

messageSourceCache:
maximumSize: 2000
expireTime: 2
expireTimeUnit: HOURS

receiptCache:
maximumSize: 2000
expireTime: 2
expireTimeUnit: HOURS

```

## 更新日志
[点我查看](CHANGELOG.md)

## 文档

* **[API文档参考](docs/API.md)**
* [数据结构参考](docs/Model.md)
* [示例使用](src/test/kotlin/ShitListing.kt)
* [Proto](proto/proto.proto)