What you will build
A short script that:- Creates a Stellar privacy client with in-memory state.
- Seeds the minimum fixture data prepare expects.
- Calls
deposit, checks the prepare result, and runsexecutewith progress logging.
Prerequisites
- Node.js 20.10 or later
- Packages:
@arcanetech/privacy-sdk-stellar,@arcanetech/privacy-sdk-state-memory
Step 1 — In-memory state adapter
The SDK keeps domain data — private records, pool snapshot, registry cache, wallet keys — that prepare reads to decide whether an operation is valid. If notes, pool root, or wallet secrets are missing or stale, prepare returnsrejected with insufficient_state instead of opening the wallet.
An in-memory adapter stores this data in process memory. It is ideal for tutorials and unit tests; it does not survive reloads.
Step 2 — Wallet stub
The Stellar preset signs through a wallet adapter. Replace this stub with your wallet SDK in production.Step 3 — Create the client
Load bundled runtime assets, configure Soroban network contracts, and create the client once.Step 4 — Seed minimal fixture state
The block below is tutorial fixture data — in production, assets and wallet secrets come from your backend and wallet flows. See Data sources.Step 5 — Prepare and execute
Next steps
State integration
Move from in-memory to Redux for production React.
Data sources
Replace fixtures with live backend and chain sync.
Setup
Full Stellar application shell with persistence.
Deposit how-to
Complete deposit reference with disclosure tiles.