Skip to main content

deleteMessage

Feature Introduction

Description

Delete a message from both local and server.

Note

Related Callback: onConversationChanged If the deleted message is the latest one, the most recent message in the conversation will change.

Function Prototype


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

Input Parameters

Parameter NameData TypeMandatoryDescription
conversationIDNSStringYesConversation ID
clientMsgIDNSStringYesMessage ID

Return Result

NameTypeDescription
onSuccessOIMSuccessCallbackSuccessful Return
onFailureOIMFailureCallbackFailure Return

Code Example


[OIMManager.manager deleteMessage:@""
clientMsgID:@""
onSuccess:^(NSString * _Nullable data) {

} onFailure:^(NSInteger code, NSString * _Nullable msg) {

}];