Skip to content

@armada/sdk / index / reconstructReceiveHistory

Function: reconstructReceiveHistory()

reconstructReceiveHistory(ownedTxos, spentNullifiers, nullifyingKey, resolveToken): HistoryEntry[]

Defined in: src/sync/history.ts:116

Reconstruct RECEIVE history (H1): shields the wallet deposited + transfers it received. Owned transact-origin notes created in a tx where the wallet ALSO spent an input are its own change, not incoming transfers, so they are excluded here — the corresponding send entry is produced by the spend-side reconstruction (H2). Requires the nullifying key to detect the wallet's own spends; a view-only wallet has it (derived from the viewing key), so this works for view-only too.

Parameters

ownedTxos

readonly TXO[]

spentNullifiers

readonly SpentNullifier[]

nullifyingKey

bigint

resolveToken

TokenAddressResolver

Returns

HistoryEntry[]