Skip to main content

revokeMessage

Description

info

Revoke a message. Supports revoking messages sent by yourself, or administrators and group owners revoking group members' messages.

Note

After revocation, the original message will become a revocation notification message with message type 2101, and it remains in its original position.
Related Callbacks:
onNewRecvMessageRevoked
onConversationChanged
If the revoked message is the latest message, the latest message of the conversation will change.

Function Prototype


- (void)revokeMessage:(NSString *)conversationID
clientMsgID:(NSString *)clientMsgID
onSuccess:(OIMSuccessCallback)onSuccess
onFailure:(OIMFailureCallback)onFailure;

Input Parameters

Parameter NameParameter TypeRequiredDescription
conversationIDNSStringYesConversation ID
clientMsgIDNSStringYesMessage ID

Return Result

NameTypeDescription
onSuccessOIMSuccessCallbackSuccess return
onFailureOIMFailureCallbackFailure return

Code Example


[OIMManager.manager revokeMessage:@""
clientMsgID:@""
onSuccess:^(NSString * _Nullable data) {
} onFailure:^(NSInteger code, NSString * _Nullable msg) {
}];