Your first onboarding
A complete, zero-touch receive on testnet. We’ll onboard an account into EURCV using the default mechanism — a claimable balance — so the user needs no XLM and no prior trustline.
The shape of the flow
- DetectRead the holder's state to confirm the trustline is missing or unauthorized.
- BuildOne call returns the unsigned transaction for the right mechanism.
- 3SignThe user signs once in their wallet; the sponsor co-signs the reserve.
- 4SettleSubmit, then verify the balance is usable.
1. Detect
Ask whether the account can already receive the asset. If it has an authorized trustline, you’re done — no onboarding needed.
2. Build the transaction
One call assembles the operations for the chosen mechanism — the change-trust, the claim, and the begin/end sponsoring sandwich — and returns an unsigned plan.
3. Sign once
The user signs the envelope in their wallet. The sponsor’s signature for the reserve is collected by the SDK, and — for a regulated asset — the approval server adds the issuer authorization. The user sees a single prompt.
4. Settle and verify
Submit the signed transaction, then confirm the balance landed and is usable.
pnpm --filter @trustline-onboarder/demo start.