diff options
author | Florian Dold <florian@dold.me> | 2021-01-08 13:30:29 +0100 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2021-01-08 13:30:29 +0100 |
commit | 8921a5e8f2f47c113eeeaa1bf14937c5b6cfb0ac (patch) | |
tree | 956d493e976b9316b23332cab6e3057933db2a3a /packages/taler-wallet-core/src/types/walletTypes.ts | |
parent | 324f44ae6954ef7a75a67838a7f0cbf2a6dc6d76 (diff) | |
download | wallet-core-8921a5e8f2f47c113eeeaa1bf14937c5b6cfb0ac.tar.gz wallet-core-8921a5e8f2f47c113eeeaa1bf14937c5b6cfb0ac.tar.bz2 wallet-core-8921a5e8f2f47c113eeeaa1bf14937c5b6cfb0ac.zip |
implement import of backup recovery document
Diffstat (limited to 'packages/taler-wallet-core/src/types/walletTypes.ts')
-rw-r--r-- | packages/taler-wallet-core/src/types/walletTypes.ts | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/packages/taler-wallet-core/src/types/walletTypes.ts b/packages/taler-wallet-core/src/types/walletTypes.ts index 1b962e1c4..235ea11f1 100644 --- a/packages/taler-wallet-core/src/types/walletTypes.ts +++ b/packages/taler-wallet-core/src/types/walletTypes.ts @@ -56,6 +56,7 @@ import { ContractTerms, } from "./talerTypes"; import { OrderShortInfo, codecForOrderShortInfo } from "./transactionsTypes"; +import { BackupRecovery } from "../operations/backup"; /** * Response for the create reserve request to the wallet. @@ -896,6 +897,29 @@ export interface MakeSyncSignatureRequest { newHash: string; } +/** + * Strategy for loading recovery information. + */ +export enum RecoveryMergeStrategy { + /** + * Keep the local wallet root key, import and take over providers. + */ + Ours = "ours", + + /** + * Migrate to the wallet root key from the recovery information. + */ + Theirs = "theirs", +} + +/** + * Load recovery information into the wallet. + */ +export interface RecoveryLoadRequest { + recovery: BackupRecovery; + strategy?: RecoveryMergeStrategy; +} + export const codecForWithdrawTestBalance = (): Codec< WithdrawTestBalanceRequest > => |