Skip to main content

Overview

Server-side message recall has no time limit. Your application server can use this API to recall a message at any time on behalf of any user. The recall command is synchronized automatically across clients and can include additional data.

Request

Authentication: Add authentication headers to the request. See Authentication.

Method POST

Rate limit 100 requests/second

Endpoint https://API domain/apigateway/hismsgs/recall

Content-Type application/json

Request Parameters

ParameterData TypeRequiredDescription
from_idstringNoFor a private chat, the ID of one participant. Maximum length: 32 characters.
target_idstringYesFor a private chat, the ID of the other participant; for a group chat, the group ID. Maximum length: 32 characters.
channel_typeintYesConversation type. 1: private chat; 2: group chat.
msg_idstringYesID of the message to recall. Maximum length: 20 characters.
msg_timeintYesTimestamp of the message to recall.
extsmapNoAdditional data for custom client-side display. Keys can contain up to 50 characters; values can contain up to 1,000 characters.

Request Example

POST /apigateway/hismsgs/recall HTTP/1.1
appkey: appkey
signature: 2e639ae3600a4sdff61fb88b76f485b
nonce: nonce
timestamp: 1672568121910
Content-Type: application/json

{
"from_id":"xxx",
"target_id":"xxx",
"channel_type":1,
"msg_id":"xxxx",
"msg_time":1569345643212,
"exts":{
"k1":"v1"
}
}

Response Example

{
"code":0,
"msg":"sucess"
}