Welcome to Beat Flow
Beat Flow is a zero-liability Stripe Connect marketplace for beat sales. Built on Cloudflare's edge infrastructure, it provides a fast, secure, and scalable platform for beat makers to sell their music.
✅ Production Ready - All backend infrastructure is deployed and ready. Just configure Stripe Connect and you're live!
Quick Overview
🚀 Deploy in 5 Minutes
Enable Stripe Connect, set two secrets, and deploy. Full guide in Getting Started.
Start Now🛡️ Zero Liability
Stripe handles payments, KYC, tax compliance, and fraud. You just facilitate connections.
Learn More💰 Earn Platform Fees
Take 10% (configurable) of every sale. Sellers keep 90% minus Stripe's ~3% fee.
See BreakdownWhat's Included
- Cloudflare Workers API - 10 endpoints for beats, checkout, downloads, sellers
- D1 Database - Schema for sellers, beats, transactions (already migrated)
- R2 Storage - Beat files (preview + full quality + stems)
- Stripe Connect - Express accounts for sellers (zero liability)
- React Frontend - Dark theme with preview players and checkout flow
- Download Authentication - Token-based file delivery after payment
Technology Stack
| Component | Technology | Purpose |
|---|---|---|
| Frontend | React + TypeScript + Vite | Beat catalog, player, checkout UI |
| API | Cloudflare Workers | Edge functions for all endpoints |
| Database | Cloudflare D1 (SQLite) | Sellers, beats, transactions |
| Storage | Cloudflare R2 (S3-compatible) | Beat files (audio + stems) |
| Payments | Stripe Connect | Checkout + seller payouts |
| Sessions | Cloudflare KV | Session tokens, rate limiting |
Architecture Highlights
Degraded Preview Strategy
Beat files are stored in two formats:
- Preview - 64kbps MP3 (public, embedded in catalog)
- Full Quality - WAV/lossless (token-gated, after purchase)
- Stems - ZIP of individual tracks (premium/exclusive licenses only)
Payment Flow
- Buyer clicks "Buy" → Worker creates Stripe Checkout session
- Stripe charges buyer, transfers 90% to seller's Connect account
- Webhook fires → Worker marks transaction as paid, generates download token
- Buyer gets download links (time-limited R2 signed URLs)
💡 Zero Liability - You never see credit cards, bank accounts, or tax IDs. Stripe Connect shields you from all financial regulation.
Next Steps
- Follow the 5-minute setup guide
- Enable Stripe Connect
- Deploy to production
- Complete production checklist
⚠️ Before Going Live - Make sure to complete the production checklist, including switching Stripe to live mode and configuring your custom domain.