Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
Mirai
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
Mirai
Commits
49959219
Commit
49959219
authored
Feb 08, 2020
by
ryoii
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
http-api update readme_cn.md
parent
cf82401e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
116 additions
and
10 deletions
+116
-10
mirai-api-http/README_CH.md
mirai-api-http/README_CH.md
+116
-10
No files found.
mirai-api-http/README_CH.md
View file @
49959219
...
@@ -300,13 +300,13 @@ fun main() {
...
@@ -300,13 +300,13 @@ fun main() {
```
json5
```
json5
{
{
"type": "Face",
"type": "Face",
"faceI
D
": 123
"faceI
d
": 123
}
}
```
```
| 名字 | 类型 | 说明 |
| 名字 | 类型 | 说明 |
| ------ | ---- | ---------- |
| ------ | ---- | ---------- |
| faceI
D
| Int | QQ表情编号 |
| faceI
d
| Int | QQ表情编号 |
#### Plain
#### Plain
...
@@ -453,7 +453,7 @@ fun main() {
...
@@ -453,7 +453,7 @@ fun main() {
### 群全体禁言
### 群全体禁言
使用此方法令指定群进行全体禁言
使用此方法令指定群进行全体禁言
(需要有相关限权)
```
```
[POST] /muteAll
[POST] /muteAll
...
@@ -487,7 +487,7 @@ fun main() {
...
@@ -487,7 +487,7 @@ fun main() {
### 群解除全体禁言
### 群解除全体禁言
使用此方法令指定群解除全体禁言
使用此方法令指定群解除全体禁言
(需要有相关限权)
```
```
[POST] /unmuteAll
[POST] /unmuteAll
...
@@ -505,7 +505,7 @@ fun main() {
...
@@ -505,7 +505,7 @@ fun main() {
### 群禁言群成员
### 群禁言群成员
使用此方法指定群禁言指定群员
使用此方法指定群禁言指定群员
(需要有相关限权)
```
```
[POST] /mute
[POST] /mute
...
@@ -517,7 +517,7 @@ fun main() {
...
@@ -517,7 +517,7 @@ fun main() {
{
{
"sessionKey": "YourSessionKey",
"sessionKey": "YourSessionKey",
"target": 123456789,
"target": 123456789,
"member": 987654321,
"member
Id
": 987654321,
"time": 1800
"time": 1800
}
}
```
```
...
@@ -526,7 +526,7 @@ fun main() {
...
@@ -526,7 +526,7 @@ fun main() {
| ---------- | ----- | ------ | ---------------- | ------------------------------------- |
| ---------- | ----- | ------ | ---------------- | ------------------------------------- |
| sessionKey | false | String | "YourSessionKey" | 你的session key |
| sessionKey | false | String | "YourSessionKey" | 你的session key |
| target | false | Long | 123456789 | 指定群的群号 |
| target | false | Long | 123456789 | 指定群的群号 |
| member
| false | Long | 987654321 | 指定群员QQ号 |
| member
Id
| false | Long | 987654321 | 指定群员QQ号 |
| time | true | Int | 1800 | 禁言时长,单位为秒,最多30天,默认为0 |
| time | true | Int | 1800 | 禁言时长,单位为秒,最多30天,默认为0 |
#### 响应: 返回统一状态码
#### 响应: 返回统一状态码
...
@@ -542,7 +542,7 @@ fun main() {
...
@@ -542,7 +542,7 @@ fun main() {
### 群解除群成员禁言
### 群解除群成员禁言
使用此方法令指定群解除全体禁言
使用此方法令指定群解除全体禁言
(需要有相关限权)
```
```
[POST] /unmute
[POST] /unmute
...
@@ -554,7 +554,7 @@ fun main() {
...
@@ -554,7 +554,7 @@ fun main() {
{
{
"sessionKey": "YourSessionKey",
"sessionKey": "YourSessionKey",
"target": 123456789,
"target": 123456789,
"member": 987654321
"member
Id
": 987654321
}
}
```
```
...
@@ -564,9 +564,48 @@ fun main() {
...
@@ -564,9 +564,48 @@ fun main() {
### 移除群成员
使用此方法移除指定群成员(需要有相关限权)
```
[POST] /kick
```
#### 请求:
```
json5
{
"sessionKey": "YourSessionKey",
"target": 123456789,
"memberId": 987654321,
"msg": "您已被移出群聊"
}
```
| 名字 | 可选 | 类型 | 举例 | 说明 |
| ---------- | ----- | ------ | ---------------- | --------------- |
| sessionKey | false | String | "YourSessionKey" | 你的session key |
| target | false | Long | 123456789 | 指定群的群号 |
| memberId | false | Long | 987654321 | 指定群员QQ号 |
| msg | true | String | "" | 信息 |
#### 响应
#### 响应: 返回统一状态码
```
json5
{
"code": 0,
"msg": "success"
}
```
### 群设置
### 群设置
使用此方法修改群设置(需要
又
相关限权)
使用此方法修改群设置(需要
有
相关限权)
```
```
[POST] /groupConfig
[POST] /groupConfig
...
@@ -638,3 +677,70 @@ fun main() {
...
@@ -638,3 +677,70 @@ fun main() {
"anonymousChat": true
"anonymousChat": true
}
}
```
```
### 修改群员资料
使用此方法修改群员资料(需要有相关限权)
```
[POST] /memberInfo
```
#### 请求:
```
json5
{
"sessionKey": "YourSessionKey",
"target": 123456789,
"memberId": 987654321,
"info": {
"name": "群名片",
"specialTitle": "群头衔"
}
}
```
| 名字 | 可选 | 类型 | 举例 | 说明 |
| ----------------- | ----- | ------- | ---------------- | -------------------- |
| sessionKey | false | String | "YourSessionKey" | 你的session key |
| target | false | Long | 123456789 | 指定群的群号 |
| memberId | false | Long | 987654321 | 群员QQ号 |
| info | false | Object | {} | 群员资料 |
| name | true | String | "Name" | 群名片,即群昵称 |
| specialTitle | true | String | "Title" | 群头衔 |
#### 响应: 返回统一状态码
```
json5
{
"code": 0,
"msg": "success"
}
```
### 获取群员资料
使用此方法获取群员资料
```
[Get] /groupConfig?sessionKey=YourSessionKey&target=123456789
```
#### 请求:
| 名字 | 可选 | 类型 | 举例 | 说明 |
| ----------------- | ----- | ------- | ---------------- | -------------------- |
| sessionKey | false | String | YourSessionKey | 你的session key |
| target | false | Long | 123456789 | 指定群的群号 |
| memberId | false | Long | 987654321 | 群员QQ号 |
#### 响应
```
json5
{
"name": "群名片",
"announcement": "群头衔"
}
```
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment