Bitcoin-secured remittance infrastructure for Africa — A low-fee cross-border payment network built on Stacks that enables people to send value across African corridors with ~1% fees and near-instant settlement.
Compare: Western Union / MoneyGram charge 7–10%. BitExpress charges ~1%.
| Country | Currency | Mobile Money | Payout Rail |
|---|---|---|---|
| 🇬🇭 Ghana | GHS | MTN MoMo, Vodafone Cash, AirtelTigo | Paystack ✅ |
| 🇰🇪 Kenya | KES | M-Pesa | Paystack ✅ |
| 🇹🇬 Togo | XOF | TMoney, Flooz | CinetPay ✅ |
| 🇸🇳 Senegal | XOF | Orange Money, Free Money, Wave | CinetPay ✅ |
| 🇳🇬 Nigeria | NGN | — | Coming soon |
| 🇹🇿 Tanzania | TZS | — | Coming soon |
| 🇺🇬 Uganda | UGX | — | Coming soon |
User A (Ghana)
│ send sBTC on Stacks (real Bitcoin, 1:1 peg)
│
▼
Stacks Smart Contract (Clarity) ← escrows sBTC with claim secret
│
▼
Receiver Wallet
│
▼
Off-ramp partner (Paystack / CinetPay)
│
▼
Mobile Money / Bank
BitExpress/
├── contracts/
│ └── remittance.clar # Clarity smart contract
├── frontend/ # Next.js 16 + TypeScript + TailwindCSS
│ ├── src/
│ │ ├── app/
│ │ │ ├── page.tsx # Landing page
│ │ │ ├── send/page.tsx # Send money page
│ │ │ ├── receive/page.tsx # Claim/receive page
│ │ │ └── dashboard/page.tsx# Dashboard
│ │ ├── components/
│ │ │ └── Navbar.tsx
│ │ ├── lib/
│ │ │ └── api.ts # API client
│ │ └��─ types/
│ │ └── index.ts
│ └── .env.example
└── backend/ # Node.js + Express API
├── src/
│ ├── index.ts # Express app
│ ├── config.ts # Configuration
│ ├── db.ts # Firestore / in-memory database adapter
│ ├── routes/
│ │ ├── send.ts # POST /api/send
│ │ ├── claim.ts # POST /api/claim
│ │ ├── transaction.ts # GET /api/transaction/:id
│ │ ├── exchangeRate.ts # GET /api/exchange-rate
│ │ ├── auth.ts # Wallet auth challenge/verify
│ │ └── webhooks.ts # Paystack & CinetPay webhook reconciliation
│ └── services/
│ ├── fxService.ts # FX rate conversion (live CoinGecko + er-api)
│ ├── payoutService.ts # Paystack / CinetPay mobile-money off-ramp
│ ├── stacksVerificationService.ts # On-chain sBTC escrow event verification
│ └── notificationService.ts # SMS/email alerts
└── .env.example
- Node.js 18+
- npm
cd backend
npm install
cp .env.example .env
npm run dev
# API runs on http://localhost:4000cd frontend
npm install
cp .env.example .env.local
npm run dev
# App runs on http://localhost:3000| Method | Endpoint | Description |
|---|---|---|
GET |
/health |
Health check |
POST |
/api/send |
Initiate a transfer |
POST |
/api/claim |
Claim a pending transfer |
GET |
/api/transaction/:id |
Get transfer by ID |
GET |
/api/transaction/wallet/:address |
Get wallet history |
POST |
/api/transaction/:id/refund |
Refund expired transfer |
GET |
/api/exchange-rate |
All exchange rates |
GET |
/api/exchange-rate/:country |
Rate for specific country |
POST |
/api/exchange-rate/convert |
Convert between currencies |
GET |
/api/exchange-rate/estimate/:usd |
Estimate local amounts |
Note: All mutating endpoints require an
Authorization: Bearer <token>header (obtained from wallet auth) and anIdempotency-KeyUUID header. The/api/sendexample below is illustrative — use the frontend for a working demo.
# 1. Get an auth challenge
curl -X POST http://localhost:4000/api/auth/challenge \
-H "Content-Type: application/json" \
-d '{"walletAddress":"ST..."}'
# 2. After signing, exchange the signature for a Firebase token
# (see /api/auth/verify — returns customToken for Firebase sign-in)
# 3. Exchange rates (unauthenticated)
curl http://localhost:4000/api/exchange-rateThe contracts/remittance.clar contract implements:
send-remittance— Lock sBTC in escrow with claim secret hashclaim-remittance— Receiver claims with secret, funds releasedrefund-remittance— Sender refunds after 24h timeoutget-transfer-status— Read transfer stateget-reputation— Read user reputation score
- Platform fee: 1% (configurable via
FEE-BASIS-POINTS) - Transfer limits: 1,000 satoshis minimum, 200,000,000 satoshis (~2 BTC) maximum
- Timeout: 144 blocks (~24 hours)
Follow these steps to run a complete send→claim flow:
- Two Stacks wallets loaded with testnet sBTC (Leather or Xverse)
- Both backend and frontend running locally
- Open Stacks explorer contract-call UI for your deployed
sbtc-token-v2contract. - Call
faucetonce from each wallet. - This mints test sBTC to the caller and makes balances visible as
<deployer>.sbtc-token-v2::sbtcin Hiro balance endpoints.
- Open
http://localhost:3000/send - Connect Sender wallet
- Fill in: Recipient Country → Nigeria, Recipient Name, Recipient Wallet (second wallet address)
- Set Amount (e.g. $20), select Crypto Wallet payout method
- Click Send Money → wallet popup opens → confirm the
send-remittancecontract call - After broadcast: copy the Claim Secret shown in the sidebar (copy button) and share it securely with the receiver
- Also note the Transfer ID shown in the result
- Open
http://localhost:3000/receive(or follow link from sender) - Connect Receiver wallet
- Enter the Transfer ID and click Load Transfer
- Paste the Claim Secret shared by the sender
- Click Claim Funds → wallet popup opens → confirm the
claim-remittancecontract call - Once the tx confirms, the backend verifies the on-chain event and processes the payout
- Explorer links are shown for both the send and claim transactions
- Open
http://localhost:3000/track - Enter the Transfer ID → see status "Claimed" with explorer links for send, claim, and (if applicable) refund transactions
- On
http://localhost:3000/dashboardwith the sender wallet connected - Pending transfers older than 24h show a Refund button
- Click Refund → confirm
refund-remittancecontract call → sBTC returned to sender
cd backend
npm test
# API and verification tests across health, exchange rates, send, claim, refund, and transaction flows- Smart contract escrow — funds only released on valid claim
- Rate limiting (100 req/15min per IP)
- Helmet security headers
- Transfer size limits
- 24-hour refund timeout
- On-chain reputation tracking
| Revenue Stream | Rate |
|---|---|
| Transaction fee | 0.5–1% |
| FX spread | 0.2–0.5% |
| Merchant API | Subscription |
- Core smart contract (Clarity)
- REST API backend
- Next.js frontend
- FX rate service (live CoinGecko + er-api)
- Live Stacks wallet integration (Leather/Xverse)
- On-chain sBTC escrow send/claim/refund verification
- Live Paystack mobile-money payouts (Ghana, Kenya)
- Live CinetPay mobile-money payouts (Togo, Senegal)
- Signed webhook reconciliation (Paystack HMAC-SHA512, CinetPay HMAC-SHA256)
- Firestore persistence
- SMS notification service
- Nigeria / Tanzania / Uganda payout rails
- Liquidity pools
- SMS transfer (send to phone number)
Built on Stacks with Clarity smart contracts and sBTC settlement — secured by Bitcoin