Documentation
StreamPay docs
StreamPay is a payment-streaming dashboard on the Stellar network: pay collaborators, vendors and grant recipients in a continuous flow instead of lump sums. This page is a quick tour; the full documentation lives in the repository's docs/ folder.
Core concepts
- Stream - a payment from a sender to a recipient that accrues at a fixed rate (for example 120 XLM / month).
- Escrow - funds are locked in a Soroban contract; the recipient can withdraw what has vested.
- Settlement - periodic on-chain settlement keeps the contract state and the dashboard in sync.
Stream lifecycle
draft → active ⇄ paused → ended → withdrawn. A stream can also be cancelled. Only valid transitions are accepted by the API (see docs/STATE_MACHINE.md).
Demo mode
The live demo runs without a database or a wallet backend. The API serves deterministic seeded data (Ada Creative Studio, Kemi Onboarding Support, Yusuf QA Partnership) and the UI falls back to the same fixtures if a request fails, so every screen renders. Browse the streams, open a stream for its timeline and receipt, or walk through stream creation.
HTTP API
| Method | Path | Description |
|---|---|---|
GET | /api/healthz | Liveness probe |
GET | /api/readyz | Readiness probe (config, Horizon, KMS) |
GET | /api/streams | List streams (cursor-paginated, seeded demo data when no database is configured) |
POST | /api/streams | Create a stream (authenticated) |
GET | /api/streams/:id | Stream detail |
POST | /api/streams/:id/{start,pause,stop,settle,withdraw} | Lifecycle actions |
GET | /api/activity | Activity feed |
GET/POST | /api/auth/wallet | Wallet challenge and signature verification, returns a JWT |
GET | /api/webhooks/health | Webhook delivery health |
GET | /api/metrics | Prometheus metrics (token protected) |
The full contract is in openapi.json in the repository.
Configuration
| Variable | Purpose |
|---|---|
STELLAR_NETWORK | testnet or mainnet (required) |
JWT_SECRET | At least 32 characters; signs session tokens (required) |
ALLOWED_ORIGINS | Comma-separated CORS allow-list (required) |
DATABASE_URL | Optional Postgres URL; seeded in-memory data otherwise |
See .env.example for every option.
Deploying
npm install
npm run build
npm startOn Vercel, import the repo, set the three required variables above and deploy. No other setup is needed.