Decentralized boxing-only prediction market built on Stellar Soroban.
| Layer | Technology |
|---|---|
| Smart Contracts | Rust / Soroban (Stellar) |
| Backend | Node.js / TypeScript |
| Frontend | Next.js 14 / TypeScript / Tailwind CSS |
| Database | PostgreSQL 15 |
| Cache | Redis 7 |
| Wallet | Freighter / Albedo |
contracts/ Soroban smart contracts (MarketFactory, Market, Treasury)
backend/ Indexer + REST API
frontend/ Next.js web app
docs/ Architecture and API documentation
# 1. Clone the repository
git clone https://github.com/your-org/bankerchanger.git && cd bankerchanger
# 2. Set up environment files
cp backend/.env.example backend/.env
cp indexer/.env.example indexer/.env
cp frontend/.env.example frontend/.env
# Edit .env files with your configuration
# 3. Start all services with one command
docker compose up
# The full stack is now running:
# - PostgreSQL: localhost:5432
# - Redis: localhost:6379
# - Indexer: localhost:3002
# - Backend API: localhost:3001
# - Frontend: localhost:3000If you prefer to run services locally without Docker:
# 1. Start only infrastructure services
docker compose up postgres redis
# 2. Backend (in separate terminal)
cd backend && npm install && npm run dev
# 3. Indexer (in separate terminal)
cd indexer && npm install && npm run dev
# 4. Frontend (in separate terminal)
cd frontend && npm install && npm run devRequires Rust and the Stellar CLI.
cd contracts
# Build optimized WASM for all contracts
cargo build --workspace
# or: stellar contract build
# Deploy to Testnet
export ADMIN_SECRET_KEY=S... # your Stellar secret key
export ORACLE_ADDRESSES=G...,G... # optional: comma-separated oracle addresses
export DEFAULT_FEE_BPS=200 # optional: platform fee (default 200 = 2%)
./scripts/deploy.sh testnetDeployed addresses are saved to contracts/deployments.json:
{
"network": "testnet",
"deployedAt": "2025-01-01T00:00:00Z",
"contracts": {
"treasury": { "address": "C..." },
"marketFactory": { "address": "C...", "defaultFeeBps": 200 },
"market": { "wasmHash": "abc123..." }
},
"admin": "G..."
}Deployment order: shared (build only) → treasury → market_factory → market (wasm upload).
- Getting Started Guide — Complete setup guide with Docker
- Contributing Guidelines
- Architecture Overview — System diagram, data flows, sequence diagrams
- API Rate Limits — Rate limit values, headers, client best practices
- Observability Guide — Prometheus metric names, alerting, logging
- Operational Runbook — Incident response procedures for production
MIT