Archive/Unarchive Chat

Archive/Unarchive Chat#

To Archive the single and group chat use below method.

await SDK.updateArchiveChat(`TO_JID`, `IS_ARCHIVED`);

Method Params#

StatusDescriptionTypeRequired
TO_JIDJID of the To User/GroupJID Stringtrue
IS_ARCHIVEDtrue for archive the chat, false for removingBooleantrue

Get All Archived Chat#

Retrieves all archived chats.

await SDK.getAllArchivedChats();

User Settings#

Handles User Settings for Archived Chats.

Get User Settings#

await SDK.getUserSettings();

Response Format:#

data: {
archive: 1 // Number 1 - Permanent / - 0 - Temporary
}

Update User Settings#

await SDK.updateUserSettings(`IS_PERMANENT_ACHIVE_ENABLED`);

Request Params#

StatusDescriptionTypeRequired
IS_PERMANENT_ACHIVE_ENABLEDtrue - Permanent, false - TemporaryBooleantrue