Create the client once, then use it for deposit, balance, restore, and withdrawal. Keep the proving files and every chain adapter pointed at the runtime returned by the SDK.

Create the client

The starter reads CommitmentInserted from the runtime pool. The three adapters supplied by your app read the remaining chain state:
  • resolveMembership returns the selected note’s accepted Merkle root and path.
  • isNullifierSpent checks whether that note has already exited.
  • runtimeFeeReadClient reads the pool’s fee state before and after proving.
Deposit and spent-state reads return their source identity with the value. The SDK stops on a chain, pool, or runtime mismatch. Use @nullark/sdk/node for local proving files. Browser integrations keep Node-only imports in trusted tooling and load the main @nullark/sdk entry in the client bundle.

Compatibility

These are the environments exercised by the package-pinned starter. Proving time changes with hardware and browser conditions. Show progress while the proof runs.
The starter’s deterministic Merkle and proof callbacks are test fixtures. Runtime code uses verified proving files and live adapters.