Effortless, private invoicing for freelancers and small businesses
Invoisio is a modern, privacy‑first invoice platform. It pairs AI‑assisted invoice creation with seamless crypto payments on Base (EVM). A minimal PaymentRouter smart contract forwards funds to merchants and emits events your backend listens to for reliable, off‑chain reconciliation.
- AI‑assisted invoice creation with clean, responsive UI
- Wallet‑based authentication; no passwords
- Crypto payments on Base: ETH and USDC via a PaymentRouter
- Real‑time backend reconciliation by watching on‑chain events
- Privacy‑first mindset; collect only what’s necessary
./
├── webapp/ # Next.js 14 app (frontend UI)
├── backend/ # NestJS API (auth, invoices, payment matching)
├── contracts/ # Solidity sources (PaymentRouter)
└── hardhat/ # Hardhat project (compile/deploy/ABI)
- Node.js 18+
- pnpm or npm
- An EVM wallet (MetaMask, Coinbase Wallet)
- Base Sepolia test ETH for deployment/testing
- Configure Hardhat environment (
hardhat/.env):PRIVATE_KEY=0xYOUR_DEPLOYER_PRIVATE_KEY RPC_URL=https://sepolia.base.org RPC_URL_MAINNET=https://mainnet.base.org
- Install and compile:
cd hardhat npm install npx hardhat compile - Deploy to Base Sepolia:
npx hardhat run scripts/deploy.js --network baseSepolia # Note the printed PaymentRouter address
The router emits:
event PaymentReceived(
bytes32 indexed invoiceId,
address indexed payer,
address indexed token, // address(0) for ETH; ERC20 address for tokens
address merchant,
uint256 amount
);
Create backend/.env and set:
# Base network
EVM_RPC_URL=https://sepolia.base.org
EVM_CHAIN_ID=84532 # 8453 for Base mainnet
# Payments
EVM_ROUTER_ADDRESS=0x... # from Hardhat deploy
EVM_USDC_ADDRESS=0x... # optional: Base Sepolia USDC address
EVM_MERCHANT_ADDRESS=0x... # optional default merchant (if not per‑invoice)
# Database, auth, etc.
DATABASE_URL=postgresql://...
JWT_SECRET=...Then:
cd backend
npm install
npx prisma generate
npx prisma migrate dev
npm run start:devThe EvmWatcherService listens for:
- Router
PaymentReceivedevents (ETH and USDC) - ERC20
Transferevents (USDC) - Direct ETH transfers in new blocks (matches by merchant address)
cd webapp
npm install
npm run dev
# open http://localhost:3000The frontend uses WalletConnectModal and use-evm-wallet to connect a wallet. When paying:
- ETH: call
router.payETH(merchant, invoiceId)withvalueset in the transaction - USDC:
approve(router, amount)thenrouter.payERC20(usdc, merchant, amount, invoiceId)
- Wallet signature flow; no passwords
- Users own their identity via their wallet
- Minimal data collection to preserve privacy
- Frontend:
npm run dev— start Next.js dev servernpm run build— production buildnpm run start— run built app
- Backend:
npm run start:dev— run NestJS in watch modenpm run test/npm run test:e2e— tests
- Contracts/Hardhat:
npx hardhat compile— compile contractsnpx hardhat run scripts/deploy.js --network baseSepolia— deploy router
- Next.js 14, TypeScript, Tailwind CSS (neumorphic styling)
- Radix UI + shadcn/ui components
- NestJS + Prisma (PostgreSQL)
- Hardhat + Ethers (contracts and deploy)
- Full invoice CRUD and client portal
- Advanced AI invoice suggestions
- Multi‑currency improvements and fiat on‑ramps
- Analytics dashboard and reporting
- PDF export and email delivery
- Fork the repo
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit:
git commit -m "feat: add amazing feature" - Push:
git push origin feature/amazing-feature - Open a PR
MIT — see LICENSE.
- https://base.org/ — Base L2 by Coinbase
- https://nextjs.org/ — React framework
- https://tailwindcss.com/ — utility‑first styling
- https://www.radix-ui.com/ — accessible primitives
- https://hardhat.org/ — Ethereum development environment
Built with ❤️ for freelancers on Base