Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
470 changes: 470 additions & 0 deletions docs/restapi/apis/conversationManagement/getOwnerConversation.mdx

Large diffs are not rendered by default.

98 changes: 98 additions & 0 deletions docs/restapi/apis/conversationManagement/setConversations.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
---
sidebar_position: 7
title: 多个用户对同一会话设置字段
hide_title: true
---

<center>

## 多个用户对同一会话设置字段

</center>

### 简要描述
- 多个用户对同一会话可选择性的设置字段。
### 请求方式
- `post`
### 请求URL
- `http://x.x.x.x:10002/conversation/set_conversations`


### Header
|header名|示例值|选填|类型|说明|
|:---- |:------- |:--- |---|------ |
|operationID|1646445464564|必填|string|operationID用于全局链路追踪|
|token|eyJhbxxxx3Xs|必填|string|管理员token|


### 请求参数示例


```json
{
"userIDs": [
"6965946400"
],
"conversation": {
"conversationID": "si_4365007572_6965946400",
"conversationType": 1,
"userID": "4365007572",
"groupID": "",
"recvMsgOpt": 0,
"isPinned": false,
"isPrivateChat": true,
"ex": "",
"burnDuration": 30
}
}
```
|字段名|选填|类型|说明|
|:---- |:------- |:--- |---|
|userIDs|必填|array|要设置会话字段的用户ID列表|
|conversation|必填|object|会话对象|
|conversation.conversationID|必填|string|会话ID|
|conversation.conversationType|必填|int|会话类型,单聊为1,群聊为3|
|conversation.userID|选填|string|会话类型为单聊时必填|
|conversation.groupID|选填|string|会话类型为群聊时必填|
|conversation.recvMsgOpt|选填|int|会话免打扰状态|
|conversation.isPinned|选填|boolean|会话是否置顶|
|conversation.isPrivateChat|选填|boolean|是否开启阅后即焚|
|conversation.ex|选填|string|会话扩展字段|
|conversation.burnDuration|选填|string|设置会话阅后即焚时间,单位秒|
### 成功返回示例


```json
{
"errCode": 0,
"errMsg": "",
"errDlt": ""
}
```
### 成功返回示例的参数说明


|参数名|类型|说明|
|:---- |:------- |:--- |
|errCode|int|错误码,0表示成功|
|errMsg|string|错误简要信息,无错误时为空|
|errDlt|errDlt|错误详细信息,无错误时为空|
|data|object|通用数据对象,具体结构见下方|
### 失败返回示例


```json
{
"errCode": 1004,
"errMsg": "RecordNotFoundError",
"errDlt": ": [1004]RecordNotFoundError"
}
```
### 失败返回示例的参数说明


|参数名|类型|说明|
|:---- |:------- |:--- |
|errCode|int|错误码,具体查看全局错误码文档|
|errMsg|string|错误简要信息|
|errDlt|errDlt|错误详细信息|
2 changes: 1 addition & 1 deletion docs/restapi/apis/friendsManagement/getSentApplication.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 9
sidebar_position: 13
title: 获取发起的好友申请
hide_title: true
---
Expand Down
2 changes: 1 addition & 1 deletion docs/restapi/apis/friendsManagement/importFriend.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 7
sidebar_position: 11
title: 导入好友
hide_title: true
---
Expand Down
2 changes: 1 addition & 1 deletion docs/restapi/apis/friendsManagement/processApplication.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 8
sidebar_position: 12
title: 处理好友申请
hide_title: true
---
Expand Down
2 changes: 1 addition & 1 deletion docs/restapi/apis/friendsManagement/sendApplication.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 6
sidebar_position: 10
title: 发起好友申请
hide_title: true
---
Expand Down
2 changes: 1 addition & 1 deletion docs/restapi/apis/friendsManagement/updateFriendRemark.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 5
sidebar_position: 9
title: 修改好友备注
hide_title: true
---
Expand Down
112 changes: 68 additions & 44 deletions docs/restapi/commonFields.mdx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
---
sidebar_position: 8
title: get_owner_conversation
hide_title: true
---

<center>

## Get Paginated Conversation List for the Current User

</center>

### Brief Description
- Retrieve the paginated list of conversations for the current user.

### Request Method
- `post`

### Request URL
- `http://x.x.x.x:10002/conversation/get_owner_conversation`

### Header
| Header Name | Example Value | Required | Type | Description |
|:---- |:------- |:--- |---|------ |
| operationID | 1646445464564 | Required | string | The operationID is used for global tracing. |
| token | eyJhbxxxx3Xs | Required | string | Admin token |

### Request Parameter Example

```json
{
"userID": "1008432211",
"pagination": {
"pageNumber": 1,
"showNumber": 20
}
}
```

| Field Name | Required | Type | Description |
|:---- |:------- |:--- |---|
| userID | Required | string | Current user ID. |
| pagination | Required | object | Pagination parameters structure. |
| pagination.pageNumber | Required | string | Current page number, starting from 1. |
| pagination.showNumber | Required | string | Number of records per page. |

### Successful Response Example

```json
{
"errCode": 0,
"errMsg": "",
"errDlt": "",
"data": {
"total": 38,
"conversations": [
{
"ownerUserID": "1008432211",
"conversationID": "sg_1012900607",
"recvMsgOpt": 0,
"conversationType": 3,
"userID": "",
"groupID": "1012900607",
"isPinned": false,
"attachedInfo": "",
"isPrivateChat": false,
"groupAtType": 0,
"ex": "",
"burnDuration": 0,
"minSeq": 0,
"maxSeq": 184,
"msgDestructTime": 0,
"latestMsgDestructTime": -62135596800000,
"isMsgDestruct": false
},
{
"ownerUserID": "1008432211",
"conversationID": "sg_1084800774",
"recvMsgOpt": 0,
"conversationType": 3,
"userID": "",
"groupID": "1084800774",
"isPinned": false,
"attachedInfo": "",
"isPrivateChat": false,
"groupAtType": 0,
"ex": "",
"burnDuration": 30,
"minSeq": 0,
"maxSeq": 0,
"msgDestructTime": 604800,
"latestMsgDestructTime": 1695265099982,
"isMsgDestruct": false
}
]
}
}
```

### Successful Response Parameters Description

| Parameter Name | Type | Description |
|:---- |:------- |:--- |
| errCode | int | Error code, 0 indicates success. |
| errMsg | string | Brief error message, empty if there is no error. |
| errDlt | string | Detailed error message, empty if there is no error. |
| data | object | Common data object, see below for the specific structure. |
| total | string | Total number of conversations. |
| conversations | array | List of [conversations](/restapi/commonFields#conversationinfo). |

### Failed Response Example

```json
{
"errCode": 1004,
"errMsg": "RecordNotFoundError",
"errDlt": ": [1004]RecordNotFoundError"
}
```

### Failed Response Parameters Description

| Parameter Name | Type | Description |
|:---- |:------- |:--- |
| errCode | int | Error code, refer to the global error code documentation for details. |
| errMsg | string | Brief error message. |
| errDlt | string | Detailed error message. |
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
---
sidebar_position: 7
title: set_conversations
hide_title: true
---

<center>

## Set Fields for Multiple Users in the Same Conversation

</center>

### Brief Description
- Allows multiple users to selectively set fields for the same conversation.

### Request Method
- `post`

### Request URL
- `http://x.x.x.x:10002/conversation/set_conversations`

### Header
| Header Name | Example Value | Required | Type | Description |
|:---- |:------- |:--- |---|------ |
| operationID | 1646445464564 | Required | string | The operationID is used for global tracing. |
| token | eyJhbxxxx3Xs | Required | string | Admin token |

### Request Parameter Example

```json
{
"userIDs": [
"6965946400"
],
"conversation": {
"conversationID": "si_4365007572_6965946400",
"conversationType": 1,
"userID": "4365007572",
"groupID": "",
"recvMsgOpt": 0,
"isPinned": false,
"isPrivateChat": true,
"ex": "",
"burnDuration": 30
}
}
```

| Field Name | Required | Type | Description |
|:---- |:------- |:--- |---|
| userIDs | Required | array | List of user IDs for whom the conversation fields will be set. |
| conversation | Required | object | Conversation object. |
| conversation.conversationID | Required | string | Conversation ID. |
| conversation.conversationType | Required | int | Conversation type, 1 for single chat, 3 for group chat. |
| conversation.userID | Optional | string | Required if the conversation type is single chat. |
| conversation.groupID | Optional | string | Required if the conversation type is group chat. |
| conversation.recvMsgOpt | Optional | int | Conversation do-not-disturb status. |
| conversation.isPinned | Optional | boolean | Whether the conversation is pinned. |
| conversation.isPrivateChat | Optional | boolean | Whether the private chat (self-destructing messages) feature is enabled. |
| conversation.ex | Optional | string | Conversation extension field. |
| conversation.burnDuration | Optional | string | Set the self-destruct timer for the conversation, in seconds. |

### Successful Response Example

```json
{
"errCode": 0,
"errMsg": "",
"errDlt": ""
}
```

### Successful Response Parameters Description

| Parameter Name | Type | Description |
|:---- |:------- |:--- |
| errCode | int | Error code, 0 indicates success. |
| errMsg | string | Brief error message, empty if there is no error. |
| errDlt | string | Detailed error message, empty if there is no error. |
| data | object | Common data object, see below for the specific structure. |

### Failed Response Example

```json
{
"errCode": 1004,
"errMsg": "RecordNotFoundError",
"errDlt": ": [1004]RecordNotFoundError"
}
```

### Failed Response Parameters Description

| Parameter Name | Type | Description |
|:---- |:------- |:--- |
| errCode | int | Error code, refer to the global error code documentation for details. |
| errMsg | string | Brief error message. |
| errDlt | string | Detailed error message. |
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 9
sidebar_position: 13
title: get_self_friend_apply_list
hide_title: true
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 7
sidebar_position: 11
title: import_friend
hide_title: true
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 8
sidebar_position: 12
title: add_friend_response
hide_title: true
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 6
sidebar_position: 10
title: add_friend
hide_title: true
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
sidebar_position: 5
sidebar_position: 9
title: set_friend_remark
hide_title: true
---
Expand Down
Loading