StableSetu is a non-custodial USDC invoicing and collections platform on Solana. It lets merchants create invoices, assign payer wallets, share payment links, and reconcile payments with audit trails. Recipients get a payables view for assigned invoices and can complete on-chain payments from wallet-first flows.
This repository was bootstrapped from the official Turborepo create-turbo community example:
pnpm dlx create-turbo@latest --example with-dockerThat starter gives us a documented Turborepo layout with a separate frontend and backend:
apps/web: Next.js frontendapps/api: Express backendpackages/ui: shared React UI packagepackages/logger: shared loggerpackages/eslint-config: shared ESLint presetspackages/typescript-config: shared TypeScript configspackages/jest-presets: shared Jest presets
pnpm install
pnpm dev
pnpm build
pnpm lint
pnpm testCreate a root .env:
DATABASE_URL="postgresql://..."
DATABASE_URL_UNPOOLED="postgresql://..."
PORT=3001
NEXT_PUBLIC_API_BASE_URL="http://localhost:3001"- Open
/auth, connect Phantom wallet, and sign message. - Create invoice at
/invoices/newas merchant and assign payer wallet/user. - Open hosted payment link
/invoice/:slug. - Login as assigned payer and verify invoice appears in
/payables. - Pay in USDC on selected network (devnet/mainnet from settings).
- Verify auto-redirect to
/receipt/:slug. - Download receipt PDF, print/share link, and show tx on Solscan.
- Open
/invoices, export CSV, and show audit metadata timestamps.
- Wallet-first authentication and workspace management
- Customer directory and invoice composer
- Public invoice links with on-chain USDC payment verification
- Merchant invoice management with status filters and deletion controls
- Recipient payables inbox for assigned invoices
- Receipts, activity timeline, and CSV exports
- If port
3001is already occupied, API dev watcher stays alive and logs that it is reusing the existing process. - Use
/settingsto manage workspace profile and network preferences.
See SPEC.md for product scope, architecture, and execution details.