Browse Platform API
Platform APIEnterprise

Set a conversation unread count

Copy

Set a target unread count for a user in selected conversations. This operation is intended for data migration or state correction; it is distinct from setting an exact read Seq.

HTTP request

POST {API_ADDRESS}/msg/reset_conversation_unread

Request example

curl --request POST "${API_ADDRESS}/msg/reset_conversation_unread" --header "Content-Type: application/json" --header "operationID: ${OPERATION_ID}" --header "token: ${TOKEN}" --data-raw '{"userID":"user_001","conversationIDs":["si_user_001_user_002"],"num":3}'

Request body

ParameterRequiredTypeDescription
userIDYesstringUser whose unread state is changed.
conversationIDsYesstring[]Conversations to update.
numYesintTarget unread count.

Response

The common response has errCode: 0 when the target state was applied.

Errors

See Error codes.

Permissions and limits