From 3aa7d0fb1cd48fc16c3e873204abb7543b70019e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E6=B1=A0?= <98259561+whitechi73@users.noreply.github.com> Date: Fri, 10 Nov 2023 20:24:53 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=A3=E7=B5=90=E8=BB=A2=E9=80=81=E3=81=AE?= =?UTF-8?q?=E3=82=B5=E3=83=9D=E3=83=BC=E3=83=88=EF=BC=88=E5=8E=BB=E5=8B=A2?= =?UTF-8?q?=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/api/message.md | 109 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) diff --git a/docs/api/message.md b/docs/api/message.md index 156bb58..456360f 100644 --- a/docs/api/message.md +++ b/docs/api/message.md @@ -267,3 +267,112 @@ icon: comment "echo": "" } ``` + +## 发送群聊合并转发 + +发送群聊合并转发。 + +### API 端点 + +`/send_group_forward_msg` + +### 参数 + +| 字段 | 类型 | 必须 | 说明 | +| ---------- | ----- | ---- | ------- | +| group_id | int64 | 是 | 发送到的目标群号 | +| message | foward message[] | 合并转发消息集 | + +### 响应 + +该接口将返回处理结果,其中 `data` 字段无数据。 + +### 示例 + +直接引用消息的合并转发,id为`消息id`: + +```json +[ + { + "type": "node", + "data": { + "id": "123" + } + }, + { + "type": "node", + "data": { + "id": "456" + } + } +] +``` + +自定义消息合并转发: + +```json +[ + { + "type": "node", + "data": { + "name": "消息发送者A", + "content": [ + { + "type": "text", + "data": { + "text": "测试消息1" + } + } + ] + } + }, + { + "type": "node", + "data": { + "name": "消息发送者B", + "content": "[CQ:image,file=xxxxx]测试消息2" + } + } +] +``` + +引用自定义混合合并转发: + +```json +[ + { + "type": "node", + "data": { + "name": "自定义发送者", + "content": "我是自定义消息", + } + }, + { + "type": "node", + "data": { + "id": "123" + } + } +] +``` + +> 由于QQ限制,该接口不提供合并转发后的消息ID以及合并转发ID。 + +## 发送私聊合并转发 + +发送私聊合并转发。 + +### API 端点 + +`/send_private_forward_msg` + +### 参数 + +| 字段 | 类型 | 必须 | 说明 | +| ---------- | ----- | ---- | ------- | +| user_id | int64 | 是 | 发送到的目标QQ | +| message | foward message[] | 合并转发消息集 | + +### 响应 + +该接口将返回处理结果,其中 `data` 字段无数据。 \ No newline at end of file