cleanRemoteHistoryMessages

public abstract void cleanRemoteHistoryMessages(ConversationType conversationType, String targetId, long recordTime, RongIMClient.OperationCallback callback)

Clears historical messages stored on the server.

Clears server-side historical messages before the specified timestamp for a specific conversation based on the conversation type and target conversation ID. After successful clearance, only historical messages after this timestamp can be retrieved from the server. Note: The historical message cloud storage feature must be enabled first!

Parameters

conversationType

The type of the conversation.

targetId

The ID of the conversation.

recordTime

The timestamp for clearing messages. 0 <= recordTime <= the sentTime of the last message in the current conversation. 0 clears all messages; other values clear messages less than or equal to recordTime.

callback

The callback for clearing messages.