Archive/Unarchive

Archive/Unarchive Settings#

Archive Chats Permanent status can set by enabling/disabling the option.

Mirrorfly.enableDisableArchivedSettings(enable: ENABLE,flyCallBack: (_){});
ArgumentTypeDescription
ENABLEbooltrue to archive the recent chat false to unarchive the recent chat
flyCallbackFlyResponsecallback to observe the action status

Archive Settings Status#

Get Archive Settings Status to keep the archived chats permanent.

bool? isArchivedSettingsEnabled = await Mirrorfly.isArchivedSettingsEnabled();
info

The archived settings status will be returned either true or false

Archive/Unarchive a recent chat conversation#

Archiving a chat conversation makes the chat not appear in recent chat list, mostly used on chats which are inactive for a long time. Unarchiving a archived recent chat conversation makes the chat conversation appear in recent chat list again.

Mirrorfly.setChatArchived(jid: JID, isArchived: ARCHIVE, flyCallBack: (_) { });
ArgumentTypeDescription
JIDStringjid of the user/group to Archive/UnArchive
ARCHIVEbooltrue to archive the recent chat false to unarchive the recent chat
flyCallbackFlyResponsecallback to observe the action status

Archive Chat Status#

Get Archive Chat Status to check the archived chat.

bool? isChatUnArchived = await Mirrorfly.isChatUnArchived();
info

The archived chat status will be returned either true or false

Get List of archived recent chat conversation#

An archived chat won't be listed in recent chat list. To get the list of archived chats call the below method.

Mirrorfly.getArchivedChatList(flyCallBack: (FlyResponse response) {
if (response.isSuccess && response.hasData) {
var result = recentChatFromJson(response.data);
} else {
//Getting users blocked me list failed print throwable to find the exception details.
}
});
ArgumentTypeDescription
flyCallbackFlyResponsecallback to observe the action status