TL;DR — the complete bot in 15
What this page covers
- Screening Kalshi and Polymarket for high-volume, high-edge opportunities
- Running AI-powered analysis on promising markets (async trigger/poll/retrieve pattern)
- Generating trading signals with Kelly criterion position sizing
- Executing paper trades via shadow trading to validate your strategy
- Tracking portfolio performance (win rate, P&L, open positions)
- Extending the bot with scheduling, webhooks, arbitrage, and portfolio-aware signals
Prerequisites
Step-by-step tutorial
1
Set up the client
Create an authenticated client that you will reuse for every call. Set a generous timeout because analysis calls run a multi-stage research pipeline that takes 30-90 seconds.
2
Screen markets for opportunities
The screening endpoint scores markets across a platform and returns the top candidates ranked by a composite of volume, price movement, and edge potential. Use it to find markets worth analyzing.Each result includes:
Filter by category to focus on a specific domain:
Python
3
Get AI analysis on promising markets
Analysis runs a multi-stage research pipeline that takes 30-90 seconds. The pattern is: trigger, poll, retrieve.
4
Generate a trading signal
A signal wraps analysis into an actionable recommendation with Kelly criterion position sizing. Use
?wait=true for a synchronous response instead of the trigger/poll pattern.Signal fields
5
Execute the trade (paper trading)
Rekko provides intelligence — execution happens on the platform. Start with shadow trading (paper trades) to validate your strategy before risking real capital.Shadow trades track the market price at entry, simulate fills, and resolve automatically when the market settles. They cost nothing and use the same tracking infrastructure as live trades.
When you are ready for live execution
Rekko does not execute live trades on your behalf. Use the execution guidance endpoint to get platform-specific order parameters, then place the order using your platform’s API:Python
6
Track performance
Monitor your shadow portfolio to see how the strategy performs over time before committing real capital.Use the performance endpoint for historical metrics:
Python
Complete script
Here is the full bot as a single copy-paste-ready Python script. It screens markets, analyzes the top candidate, generates a signal, and places a shadow trade.Python
Going further
Schedule the bot on a cron
Run the script every hour to continuously screen for new opportunities:Portfolio-aware signals
When you have multiple open positions, standard signals do not account for correlation. The portfolio signal endpoint considers your existing holdings and adjusts sizing to avoid concentration:Python
Cross-platform arbitrage
Find price discrepancies between Kalshi and Polymarket on the same event:Python
Use Rekko from your AI coding assistant
Install the Rekko MCP server to query markets, run analyses, and generate signals directly from your editor:How the pieces fit together
A single screen-analyze-signal-trade cycle costs approximately 0.10 screen + 0.10 retrieve + 0.30.
What’s next
Prediction market API comparison
Compare Rekko with Kalshi, Polymarket, and other market data APIs.
Cross-platform arbitrage
Find and exploit price gaps between Kalshi and Polymarket.
Kelly criterion sizing
Deep dive on the math behind position sizing.
API reference
Full endpoint documentation with interactive playground.
MCP integration
Use Rekko from your AI coding assistant.