Skip to main content

Set Fields for Multiple Users on the Same ConversationID

Brief Description

  • Allows multiple users to selectively set fields for the same conversation.

Request Method

  • post

Request URL

  • {API_ADDRESS}/conversation/set_conversations
Header NameExample ValueOptionalTypeDescription
operationID1646445464564RequiredstringUsed for global trace tracking. It is recommended to use a timestamp, unique for each request
tokeneyJhbxxxx3XsRequiredstringAdmin token

Request Parameters Example

{
"userIDs": [
"6965946400"
],
"conversation": {
"conversationID": "si_4365007572_6965946400",
"conversationType": 1,
"userID": "4365007572",
"groupID": "",
"recvMsgOpt": 0,
"attachedInfo": "attached",
"isPinned": false,
"isPrivateChat": true,
"ex": "",
"burnDuration": 30
}
}
Field NameOptionalTypeDescription
userIDsRequiredarrayList of user IDs for whom conversation fields are to be set
conversationRequiredobjectConversation object
conversation.conversationIDRequiredstringConversationID
conversation.conversationTypeRequiredintConversation type: 1 for single chat, 3 for group chat
conversation.userIDOptionalstringRequired for single chat
conversation.groupIDOptionalstringRequired for group chat
conversation.recvMsgOptOptionalintMute status for the conversation
conversation.attachedInfoOptionalstringAttached information for the conversation, reserved field
conversation.isPinnedOptionalbooleanWhether the conversation is pinned
conversation.isPrivateChatOptionalbooleanEnables self-destruct mode for messages
conversation.exOptionalstringExtended field for the conversation
conversation.burnDurationOptionalintSelf-destruct time for messages in seconds

Success Response Example

{
"errCode": 0,
"errMsg": "",
"errDlt": "",
"data": null
}

Success Response Parameters Description

Parameter NameTypeDescription
errCodeintError code, 0 indicates success
errMsgstringBrief error message, empty if none
errDlterrDltDetailed error information, empty if none
dataobjectGeneral data object, see structure below

Failure Response Example

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

Failure Response Parameters Description

Parameter NameTypeDescription
errCodeintError code, refer to global error code documentation
errMsgstringBrief error message
errDlterrDltDetailed error information