Open-source template to build a tokenization stack with Stellar/Soroban, Trustless Work (escrows), participation tokens, token sales, ROI vaults, and Next.js apps for issuers and investors.
Inspired by the Tokenized Micro Credit Pool concept.
| App | Description |
|---|---|
apps/backoffice-tokenization |
Issuer console: escrows, tokenization, milestones, disputes |
apps/investor-tokenization |
Investor portal: buy tokens, holdings, claim ROI |
apps/smart-contracts |
Soroban contracts: escrow, Token Factory, Token Sale, Vault |
- Escrow — Multi-release, milestones, approvals, disputes, and fund release (Trustless Work + Soroban).
- Tokenization — Token deploy → primary sale → funds to escrow → milestones → returns to vault → investors claim ROI by balance.
- Frontends — Backoffice (manage), Investor (invest & claim).
- Escrow — Multi-release, roles, disputes, approvals.
- Token Factory — Mint/burn participation tokens.
- Token Sale — Sell tokens for USDC and route to escrow.
- Vault — Returns and ROI claim by token holdings.
Includes tests and JSON snapshots.
From the repo root (all apps):
npm install
npm run devOr a single app:
cd apps/<backoffice-tokenization|investor-tokenization|evidence-service>
npm install
npm run devEach app has a .env.example. Copy it to .env or .env.local in that app’s directory and fill in the values. Never commit .env or .env.local (they are gitignored).
| Variable | Description | Required |
|---|---|---|
SOURCE_SECRET |
Stellar secret key of the account that deploys contracts and signs transactions (issuer/backoffice). Used by deploy API routes. | Yes (for deploy) |
NEXT_PUBLIC_API_URL |
Base URL of the backoffice API when called from another origin. If unset, relative /api is used. |
No |
NEXT_PUBLIC_API_KEY |
Trustless Work API key for Wallet Kit / Blocks. | Yes (for Trustless Work) |
| Variable | Description | Required |
|---|---|---|
SOURCE_SECRET |
Stellar secret key for server-side deploy/signing (if using deploy from this app). | Only if using deploy |
NEXT_PUBLIC_SOROBAN_RPC_URL |
Soroban RPC endpoint (e.g. https://soroban-testnet.stellar.org). |
Yes |
NEXT_PUBLIC_STELLAR_NETWORK_PASSPHRASE |
Network passphrase (e.g. Test Net: Test SDF Network ; September 2015). |
Yes |
NEXT_PUBLIC_DEFAULT_USDC_ADDRESS |
Contract ID of USDC on the chosen network (for token sale / payments). | Yes |
NEXT_PUBLIC_API_URL |
Base URL of the investor app API when called from another origin. | No |
NEXT_PUBLIC_API_KEY |
Trustless Work API key. | Yes (for Trustless Work) |
NEXT_PUBLIC_*variables are exposed to the browser; use them only for non-secret config (RPC URL, network, contract IDs).- Keep secrets (e.g.
SOURCE_SECRET) only in server-side env; they are read in API routes (e.g.route.ts), not in client code.
- Next.js (App Router), Tailwind, ShadCN
- Trustless Work: Wallet Kit, Blocks (escrow UI), API
- Soroban for contract calls
- Fork the repository.
- Clone your fork locally.
- Pick an issue from the project board and coordinate with your group lead (assignee or maintainer).
- Create a branch, implement the change, and run tests.
- Open a Pull Request from your branch to the
developbranch of the upstream repo. - In the PR description, link the issue (e.g.
Closes #123orFixes #123) so it is tracked and closed when the PR is merged.
We recommend discussing scope with your group lead before starting work to avoid duplicate effort.
For teams experimenting with tokenization, hackathons, RWA, or integrating Trustless Work. Fork, modify, and build your product.
License: MIT.