Simple. Fast. Direct-to-wallet.
A production crypto swap application powered by the Agent Broko ($BROKO) ecosystem and non-custodial routing infrastructure.
- Core Exchange Pairs: Instant, non-custodial swaps for major crypto pairs with 1-click direction flipping.
- Fixed-Rate Guarantee Engine: Live quote calculation with fixed-rate locks and integrated commission.
- No Account / Non-Custodial: Users never need an account, custody wallets, or KYC credentials.
- Enterprise-Grade Security:
- Zero private secrets or internal shift IDs exposed to client bundles or public URLs.
- Public swap IDs formatted as secure random identifiers (e.g.,
ABS-8F4K2M). - Network-aware cryptographic address validation (Bitcoin Legacy, P2SH, Native SegWit Bech32, Taproot Bech32m, Ethereum ERC-20, Tron TRC-20, Solana).
- Rate limiting & double-click submission idempotency.
- Adaptive Polling & Live Progress:
- Live 15-minute countdown expiration timer with refresh protection.
- Adaptive status polling (0-2m: 5s, 2-10m: 10s, 10m+: 20s) with clean unmount and termination on finalized states.
- Payment QR code generation supporting Bitcoin URI protocols.
- Direct links to blockchain explorers upon on-chain transaction detection.
- Dual Engine (Mock & Production): Full-fidelity mock simulator (
SIDESHIFT_MOCK_MODE=true) for offline development and automated testing alongside real production integration (SIDESHIFT_MOCK_MODE=false). - Admin Dashboard: Protected metric overview displaying total swaps, completed/pending/failed counts, transaction volumes, and estimated commission revenue.
- Confirmed BROKO Airdrop: Complete any swap before December 31, 2026 to qualify destination wallets for the community airdrop snapshot.
- Framework: Next.js (App Router, TypeScript)
- Styling: Tailwind CSS with dark fintech glassmorphism theme
- Components & Icons: Radix UI primitives, Lucide React,
qrcode.react - Database & ORM: PostgreSQL with Prisma ORM
- Validation: Zod
- Testing: Vitest
git clone https://github.com/sajidhossain8272/agent-broko-swap.git
cd agent-broko-swap
npm installCopy .env.example to .env:
cp .env.example .envnpx prisma generate
npx prisma db pushnpm run dev- Server-Side Credentials:
SIDESHIFT_SECRET,SIDESHIFT_AFFILIATE_ID, and database passwords never leave the server. - Shift ID Obfuscation: The internal SideShift Shift ID is never exposed to the client; all client references use
ABS-XXXXXX. - Idempotency: Duplicate shift submissions within a 30-second window for the same quote and addresses return cached results rather than triggering duplicate shifts.
- Header Protection: Standard security headers configured in
next.config.mjs(X-Frame-Options: DENY,X-Content-Type-Options: nosniff, strict referrer policy).