Table of Contents

Interface IWalletRecoveryService

Namespace
NArk.Core.Recovery
Assembly
NArk.Core.dll

Wallet-type-agnostic recovery entry point. Given a wallet id, rebuilds local state from on-chain / indexer sources: contracts (incl. legacy script variants under deprecated server signers), the HD derivation index, funds (VTXOs), and any in-flight Arkade transactions.

Dispatches by wallet type: HD wallets get a gap-limit index scan; SingleKey wallets — whose contract set is fixed by their one key — re-derive that contract. Both then finalize pending transactions and sync funds.

public interface IWalletRecoveryService

Methods

RecoverAsync(string, RecoveryOptions?, CancellationToken)

Recover everything reconstructable for walletId.

Task<WalletRecoveryReport> RecoverAsync(string walletId, RecoveryOptions? options = null, CancellationToken cancellationToken = default)

Parameters

walletId string

The wallet to recover (must already exist in storage).

options RecoveryOptions

HD scan tuning (gap limit, max index). Ignored for SingleKey.

cancellationToken CancellationToken

Cancellation token.

Returns

Task<WalletRecoveryReport>