WhatsApp-first payments powered by the Stellar network.
SendAm is a financial access MVP that lets people create a Stellar wallet, check their XLM balance, and send XLM using simple WhatsApp messages. The goal is to make blockchain payments feel as familiar as sending a chat message, especially for users who may not be comfortable with browser wallets, seed phrases, or exchange-style interfaces.
- Web app: https://send-am-web.vercel.app/
- API: https://send-am-api.vercel.app/
- Repository: https://github.com/Gozirimdev/SendAm
Current status: MVP running on Stellar Testnet. This repository is not yet configured for real-money production use.
Many people already understand WhatsApp, but crypto wallets still feel technical, intimidating, and risky. SendAm bridges that gap by turning WhatsApp into a simple payment interface while using Stellar for fast, low-cost settlement.
The product is designed for users who need:
- A familiar way to interact with digital money.
- Low-cost cross-border value transfer.
- Wallet creation without installing a separate crypto app.
- A lightweight payment experience that works well on mobile.
- An admin dashboard for monitoring users, wallets, and transactions.
Stellar is a strong fit for SendAm because the product needs fast settlement, low fees, simple account primitives, and a network designed for payments. In the MVP, Stellar Testnet is used to:
- Generate Stellar keypairs for new users.
- Fund test wallets through Friendbot.
- Read native XLM balances through Horizon.
- Submit XLM payment transactions.
- Store transaction hashes for auditability and admin review.
The current implementation focuses on native XLM transfers first. The architecture can later support Stellar assets, anchors, fiat on/off ramps, and compliance-aware payment flows.
SendAm has three main surfaces:
-
WhatsApp bot experience Users send natural commands to the bot, such as:
create wallet fund balance save ada GABC... contacts send 5 xlm ada send 5 xlm GABC... yes no help -
REST API The backend exposes wallet and transaction endpoints so the product can be tested without WhatsApp.
-
Web admin dashboard Admins can view platform stats, users, wallets, and transaction records.
- Create a Stellar Testnet wallet from a WhatsApp command.
- Automatically fund new test wallets using Stellar Friendbot, with a
fundcommand to retry if funding fails. - Check XLM balance by sending
balance. - Send XLM to another Stellar public address.
- See an upfront balance check and confirm transfers before funds are submitted to Stellar.
- Save contacts with aliases for repeat payments.
- Receive Stellar Expert receipt links after successful transfers.
- Receive simple WhatsApp replies for successful and failed actions.
- View total users.
- View total wallets.
- View transaction counts.
- View successful and failed transactions.
- Browse user, wallet, and transaction tables.
- REST endpoints for wallet creation, balance checks, and XLM transfers.
- MongoDB persistence for users, wallets, and transactions.
- Encrypted storage for Stellar secret keys.
- Separate backend and frontend apps in one monorepo.
WhatsApp User
|
v
WhatsApp Business API
|
v
Express Webhook API
|
+--> Command Parser
+--> MongoDB: users, wallets, transactions
+--> Stellar Horizon: balances and payments
|
v
WhatsApp Response Message
Admin / Tester
|
v
Vite React Apps (landing + admin)
|
v
Express REST API
SendAm/
apps/
api/ Express backend for WhatsApp, Stellar, MongoDB, and admin APIs
landing/ Vite + React marketing/landing site
admin/ Vite + React admin dashboard
packages/
shared/ Shared UI (Loader) and utilities (api client, formatDate)
package.json Root workspace scripts
- Node.js
- Express
- MongoDB with Mongoose
- Stellar SDK
- WhatsApp Business Cloud API
- Axios
- Helmet, CORS, Morgan, and rate limiting
- Vite + React (two apps: landing and admin)
- React Router
- Tailwind CSS
- Axios
- Lucide React icons
- Stellar Testnet
- Horizon API
- Native XLM payments
- Friendbot funding for test accounts
- User sends
create walleton WhatsApp. - SendAm creates or finds the user by phone number.
- Backend generates a Stellar keypair.
- Secret key is encrypted before storage.
- Public key is stored on the wallet record.
- Testnet wallet is funded with Friendbot (retried on failure; the wallet is marked funded on success).
- User receives their public key by WhatsApp. If funding failed, the user can reply
fundto retry.
- User sends
balance. - Backend finds the user's wallet.
- Backend loads the account from Stellar Horizon.
- User receives current native XLM balance.
- User sends a command like
send 5 xlm GABC...orsend 5 xlm ada. - Backend parses amount and destination, or resolves a saved contact alias.
- Backend checks the sender's balance and rejects the transfer up front if it is insufficient.
- Backend sends a confirmation prompt to the user (expires after 10 minutes).
- User replies
YESto approve orNOto cancel. - Backend enforces per-user transfer guardrails, then decrypts the user's stored Stellar secret key.
- Backend builds, signs, and submits a Stellar payment transaction.
- Transaction result and Stellar Expert receipt link are saved in MongoDB.
- User receives success or failure feedback on WhatsApp.
Base path:
/api/wallet
Endpoints:
POST /api/wallet/create
GET /api/wallet/:phone/balance
POST /api/wallet/send
Base path:
/api/admin
Endpoints:
GET /api/admin/stats
GET /api/admin/users
GET /api/admin/wallets
GET /api/admin/transactions
Base path:
/webhook
Endpoints:
GET /webhook
POST /webhook
Create an .env file inside apps/api using apps/api/.env.example as a guide.
PORT=3002
NODE_ENV=development
MONGODB_URI=mongodb://localhost:27017/sendam
CORS_ORIGINS=http://localhost:3000,http://localhost:3001
ENCRYPTION_KEY=your_64_character_hex_key
ADMIN_PASSWORD=your_admin_password
JWT_SECRET=your_64_character_hex_secret
WHATSAPP_TOKEN=your_whatsapp_token_here
WHATSAPP_PHONE_NUMBER_ID=your_phone_id_here
WHATSAPP_VERIFY_TOKEN=your_verify_token
WHATSAPP_APP_SECRET=your_meta_app_secret
MAX_SEND_AMOUNT=1000
DAILY_SEND_LIMIT=5000
MAX_SENDS_PER_DAY=50
STELLAR_NETWORK=testnet
STELLAR_HORIZON_URL=https://horizon-testnet.stellar.org
ENABLE_WALLET_REST_API=falseThe REST wallet API (
/api/wallet/*) is unauthenticated and is disabled in production unlessENABLE_WALLET_REST_API=true. Outside production it defaults to enabled for local testing. WhatsApp is the real, signature-verified surface.
For the admin app (apps/admin/.env), configure:
VITE_API_BASE_URL=http://localhost:3002/apiFor the landing app (apps/landing/.env), configure:
VITE_ADMIN_URL=http://localhost:3001For production, set VITE_ADMIN_URL to the admin dashboard subdomain, for
example https://admin.your-domain.com.
- Node.js 18 or newer
- npm
- MongoDB running locally or a MongoDB connection URI
- WhatsApp Business Cloud API credentials for webhook testing
From the repository root:
npm installnpm run dev:apiThe API runs on:
http://localhost:3002
npm run dev:landing
npm run dev:adminThe landing app runs on http://localhost:3000 and the admin app on
http://localhost:3001.
npm run devThis starts the API, landing, and admin apps together.
The backend ships with a unit test suite on the built-in Node test runner (no extra dependencies), covering the command parser, wallet-secret encryption, admin auth, transfer guardrails, recipient resolution, and request validators:
npm test # from the repo root
npm run test --workspace=apps/api # equivalentlyThe three apps deploy differently because of how they run:
Static Vite builds — deploy to any static host (Vercel, Netlify, Cloudflare Pages). Build command npm run build --workspace=apps/landing (or apps/admin), output in apps/<app>/dist. Set the VITE_* variables (see Environment Variables) at build time.
The API is a long-running Express server (app.listen in src/server.js), so deploy it to a persistent Node host — Render, Railway, Fly.io, or a VM — not Vercel/Lambda serverless functions as written. Two things rely on a persistent process:
- The Mongo connection is opened once at startup. A serverless model would open one per invocation and exhaust the connection pool.
- The WhatsApp webhook acknowledges Meta immediately and processes the message asynchronously; a serverless function may freeze after the response and never finish the work.
Running on serverless would require a cached/reused Mongo connection and fully synchronous webhook processing. That refactor is not done — use a persistent host.
Backend deployment checklist:
- Provision managed MongoDB (e.g. MongoDB Atlas) and set
MONGODB_URI. - Set every required
apps/apivariable — the server fails fast at startup withoutENCRYPTION_KEY,JWT_SECRET, andADMIN_PASSWORD, and rejects unsigned webhooks in production withoutWHATSAPP_APP_SECRET. - Set
NODE_ENV=productionand aCORS_ORIGINSallowlist covering the deployed admin/landing URLs. - Point the host's health check at
GET /health(returns 503 if the database link is down). - Configure the WhatsApp Business webhook URL to
https://<api-host>/webhookwith a matchingWHATSAPP_VERIFY_TOKEN. - Keep
ENCRYPTION_KEYbacked up securely — losing it makes every stored wallet secret unrecoverable.
Landing app (apps/landing):
/ Landing page
Admin app (apps/admin):
/login Admin login screen
/ Dashboard overview
/users User table
/wallets Wallet table
/transactions Transaction table
This project is still an MVP. Some hardening is already in place:
- Real backend admin authentication (HMAC-signed session tokens); the API refuses to start without
ADMIN_PASSWORDandJWT_SECRET. - Admin API routes protected server-side by the
requireAdminmiddleware. - No fallback encryption key — a missing/invalid
ENCRYPTION_KEYfails loudly at startup. - Wallet secrets encrypted with authenticated AES-256-GCM (tamper-detecting).
- Stellar public keys, amounts, and phone numbers validated on every surface.
- WhatsApp webhook POSTs verified against the
X-Hub-Signature-256header (fail-closed in production). - Inbound message idempotency to prevent duplicate transfers from webhook retries.
- Per-user transfer guardrails: per-transaction cap plus rolling 24h amount and count limits, with an upfront balance check before confirmation.
- CORS restricted to a configured origin allowlist in production.
- Mongo-backed rate limiting (shared across instances): per-IP on the REST API and per-sender on the WhatsApp webhook.
- The unauthenticated REST wallet API is disabled in production by default (
ENABLE_WALLET_REST_API); WhatsApp is the signature-verified product surface.
Still required before a real-money launch:
- Move from Stellar Testnet to mainnet with a vetted deployment.
- Add secure, managed secret/key management (KMS/HSM) instead of a single static env key; support key rotation.
- Add audit logs for sensitive actions and monitoring/alerting.
- Add per-user authentication to the REST wallet API, or keep it disabled in production.
- Expand the automated test suite from the current unit tests (parser, crypto, admin auth) to webhook and transaction integration flows.
- Replace the single shared admin password with real admin accounts and roles.
- Complete legal, compliance, KYC, AML, and custody review where required.
- Uses Stellar Testnet only.
- Supports native XLM transfers only.
- WhatsApp command parser is intentionally simple.
- Single shared admin password (no per-admin accounts or roles yet).
- No customer web signup is required yet because WhatsApp phone number is the MVP identity.
- No production compliance workflow is included yet.
Real admin authentication.(done)Stronger validation for wallet and payment requests.(done)Webhook signature verification and transfer guardrails.(done)- Better WhatsApp command handling, confirmation prompts, and error messages.
Automated tests for the parser, crypto, and admin auth.(done) — extend to webhook and transaction integration flows.- Deployment configuration for backend, frontend, database, and environment variables.
- Support custom Stellar assets.
- Expand contact aliases into richer recipient management.
- Add richer transaction receipts with Stellar explorer links.
- Add QR-code public key sharing.
- Add low-balance warnings and safer confirmation flows.
- Explore anchor integrations for fiat on/off ramps.
- Compliance review.
- Monitoring and alerting.
- Admin roles and permissions.
- Recovery and support workflows.
Rate limits per user and per phone number.(done — per-IP REST and per-sender WhatsApp limits)- Secure key-management strategy.
SendAm demonstrates a practical Stellar use case: making blockchain payments accessible through a communication channel people already use every day. The MVP combines WhatsApp, Stellar Testnet, MongoDB, and a Vite + React admin dashboard to show the foundation for a chat-based payment product.
The project is intentionally scoped: it proves wallet creation, balance checks, saved recipients, confirmation-based XLM transfers, and auditable Stellar receipts first. With stronger authentication, validation, compliance work, and production deployment, SendAm can evolve from a Testnet MVP into a broader payments product for mobile-first users.
SendAm is open source and released under the MIT License. See LICENSE for details.
Contributions are welcome. See CONTRIBUTING.md for setup instructions, contribution areas, pull request guidelines, and security notes.