From fe3ea7cae01ee326384a824f95326d573552cba5 Mon Sep 17 00:00:00 2001 From: Florian Duros Date: Wed, 6 Nov 2024 17:58:38 +0100 Subject: [PATCH] Complete restoreKeyBackup* methods documentation --- src/crypto-api/index.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/crypto-api/index.ts b/src/crypto-api/index.ts index b624eeaaec8..d62daba23ea 100644 --- a/src/crypto-api/index.ts +++ b/src/crypto-api/index.ts @@ -555,15 +555,18 @@ export interface CryptoApi { deleteKeyBackupVersion(version: string): Promise; /** - * Download the last key backup from the homeserver (endpoint GET /room_keys/keys/). + * Download and restore the last key backup from the homeserver (endpoint GET /room_keys/keys/). * The key backup is decrypted and imported by using the decryption key stored locally. The decryption key should be stored locally by using {@link CryptoApi#storeSessionBackupPrivateKey}. * + * Warning: the full key backup may be quite large, so this operation may take several hours to complete. + * Use of {@link KeyBackupRestoreOpts.progressCallback} is recommended. * @param opts */ restoreKeyBackup(opts?: KeyBackupRestoreOpts): Promise; /** * Restores a key backup using a passphrase. + * The decoded key (derivated from the passphrase) is store locally by calling {@link CryptoApi#storeSessionBackupPrivateKey}. * @param passphrase - The passphrase to use to restore the key backup. * @param opts *