No-code trading automation for Polymarket. Build strategies visually, backtest on real data, export to TypeScript.
PolyFlow lets you build Polymarket trading bots without writing code. Drag blocks, connect logic, test with real market data, then export production-ready TypeScript.
No API keys needed to start. Just clone and run.
git clone https://github.com/juapperez/polyflow.git
cd polyflow
npm install
npm run devOpen http://localhost:5173 → Start building.
- Drag blocks - Triggers, conditions, actions, risk controls
- Connect logic - Build your strategy visually
- Test live - Run against real Polymarket markets (no auth needed)
- Export code - Get TypeScript you can run locally
- ✅ Visual strategy builder (no code)
- ✅ Real-time Polymarket CLOB data
- ✅ Backtest on historical data
- ✅ Export to TypeScript
- ✅ Run locally (your keys, your machine)
- ✅ Multi-language (EN, PT-BR)
// Auto-generated from visual builder
export class CustomStrategy extends Strategy {
async analyze(market: Market): Promise<Signal> {
// Price trigger
if (market.prices[0] < 0.3) return { action: 'HOLD', size: 0, confidence: 0 };
// Momentum check
const momentum = market.prices[0] - 0.5;
if (momentum <= 0) return { action: 'HOLD', size: 0, confidence: 0 };
// Risk management
const confidence = this.calculateConfidence(market);
// Execute
return {
action: 'BUY',
size: Math.min(500, 1000 * confidence),
confidence
};
}
}For traders: Build strategies without learning to code
For developers: Prototype fast, export clean TypeScript
For everyone: Test risk-free with demo markets
┌─────────────────┐
│ Visual Builder │ ← Drag & drop interface
└────────┬────────┘
│
▼
┌─────────────────┐
│ Strategy Logic │ ← Your trading rules
└────────┬────────┘
│
▼
┌─────────────────┐
│ Polymarket API │ ← Real market data (no auth for reads)
└────────┬────────┘
│
▼
┌─────────────────┐
│ Local Execution│ ← Runs on your machine
└─────────────────┘
polyflow/
├── frontend/ # React app (visual builder)
├── src/
│ ├── core/ # Trading engine
│ ├── strategies/ # Strategy implementations
│ └── examples/ # Demo scripts
└── demo/ # Standalone HTML demo
# Install
npm install
# Dev server
npm run dev
# Build
npm run build
# Test
npm test
# Run backtest
npm run backtestNot needed for testing. Polymarket CLOB API is public for reading market data.
Only needed for live trading. Add to .env:
POLYMARKET_API_KEY=your_key
POLYMARKET_SECRET=your_secret- Runs 100% locally
- No data collection
- No telemetry
- Your keys never leave your machine
PRs welcome. See CONTRIBUTING.md.
MIT - see LICENSE
Built with: React • TypeScript • Vite • Polymarket CLOB API
Made by traders, for traders.