Skip to main content

Manage notes

Your shielded balance is a set of notes that your client reconstructs from on-chain events and holds in local state, rather than an account the chain keeps for you. The utilities in this group keep that local state current: they pull new notes in, move note material between devices, and cross-check the chain before you spend.

How the pieces fit

These utilities do three jobs:

  • Discovery keeps your local set in sync with the chain. It scans the pool's Note events, trial-decrypts them with your viewing key, and reconciles every change since the last sync: deposits that got attested, transfers that arrived, requests that were paid, notes spent from another device. Run it after a transaction lands and before displaying balances.
  • Import and export handle notes that discovery can't see. A note received out-of-band is never published on-chain, so the sender hands you its material directly, often inside a payment receipt, and you import it to claim it. The imported note joins your local set as PENDING until the next sync confirms it. Export is the same hand-off outward, packaging a note's material for another of your devices. Treat exported material as sensitive: its noteSecret reveals the note to anyone who sees it, even though spending it still needs your keys.
  • Listing and verifying are the read-side checks. Listing filters your local set by status, asset, or deposit label. Verifying spent status asks the chain directly whether a note's nullifier has been used, which matters because local state can lag after a failed flow and a spend built on a stale input reverts.

In this group