How stellar-mint gets built: in spectrum order, in runnable pieces, shipped as cumulative
class branches. Every class ends with a green npm run reproduce:class-N on testnet.
- The spine the classes map to: control-spectrum.md.
- The account/authority model and op modules: architecture.md.
- The issue order and why it matters: bootstrap-and-issue.md.
| Phase | Builds | Branch | Tag | Status |
|---|---|---|---|---|
| 0 | Scaffolding (service layer, asset.config.ts, bootstrap) |
— | — | ✅ |
| 1 | Class 1 — trustline + issue ops, issue.ts, reproduce:class-1 |
class-1-emissao-trustlines |
v0.1-consentimento |
✅ |
| 2 | Class 2 — flags + clawback ops, config flags, reproduce:class-2 | class-2-controle-stablecoin |
v0.2-controle |
✅ |
| 3 | Class 3 — amm + swap ops, reproduce:class-3 | class-3-liquidez-amm |
v0.3-mercado |
✅ |
| 4 | Frontend (holder-facing dApp) | main |
— | ✅ |
Status legend: ⬜ todo · 🔵 in progress · ✅ done. The Status column is the single source of truth — update it in the same commit that lands the phase.
- Flags before distribution (D11).
scripts/issue.tsalways sets issuer control flags before any payment. This is what makes clawback work and is the Class-2 lesson made operational. - Testnet only (D2). The
assertTestnetguard stays; no mainnet code path is ever added. - The reproduce check is the demo (D9/D13). A class is not done until its
reproduce:class-Nruns end-to-end on a clean checkout, asserting both the successes and the expected failures. - Irreversible ops are opt-in and loud.
lockIssueronly runs when the config asks; it is documented as one-way everywhere it appears.
Service layer (src/lib/*), declarative asset.config.ts, scripts/bootstrap.ts, the npm-script gate
(typecheck + lint), and CI. npm run bootstrap verified against testnet (three funded accounts +
artifacts written).
src/operations/{trustline,issue}.ts, scripts/issue.ts, scripts/reproduce/class-1.ts. Reproduce:
distribute cBRL through a trustline; force and assert op_no_trust on the no-trustline path. Ships as
class-1-emissao-trustlines / v0.1-consentimento.
src/operations/{flags,clawback}.ts, the flags/lockIssuer config path in issue.ts,
scripts/reproduce/class-2.ts. Reproduce: authorize → freeze → clawback → lock, asserting each. Ships as
class-2-controle-stablecoin / v0.2-controle.
src/operations/{amm,swap}.ts, scripts/reproduce/class-3.ts. Reproduce: seed a cBRL/USDx pool,
strict-send swap (assert the price moved), withdraw. Ships as class-3-liquidez-amm / v0.3-mercado.
Vite/React/TS/Tailwind, reusing the album's wallet.ts / friendbot.ts / store.tsx patterns; pages
for trustline (C1) and pool/swap (C3). Lands on main. Builds green (tsc --noEmit && vite build) and
boots; full wallet flow is a manual browser step.
A class is done only when (decisions.md D13):
npm run typecheckandnpm run lintare green.npm run reproduce:class-Nruns end-to-end on a clean checkout via one documented command.- The relevant
/docsanddecisions.mdare updated (including this Status column).