# ---- Polymarket endpoints ---- POLYMARKET_SERIES_SLUG=btc-up-or-down-15m POLYMARKET_SERIES_ID=10192 POLYMARKET_GAMMA_URL=https://gamma-api.polymarket.com # After the 2026-04-28 V2 cutover, https://clob.polymarket.com serves V2. # Before cutover, set this to https://clob-v2.polymarket.com to test V2. CLOB_HOST=https://clob.polymarket.com POLYMARKET_WS_MARKET_URL=wss://ws-subscriptions-clob.polymarket.com/ws/market # ---- Live-trading credentials (leave blank for paper-only) ---- PRIVATE_KEY= FUNDER_ADDRESS= CLOB_API_KEY= CLOB_SECRET= CLOB_PASSPHRASE= SIGNATURE_TYPE=2 CHAIN_ID=137 POLYGON_RPC_URL=https://polygon-mainnet.g.alchemy.com/v2/YOUR_KEY # Optional V2 builder code: 0x-prefixed 32-byte hex from your Builder Profile. BUILDER_CODE= # ---- Trading config ---- TRADING_MODE=paper # paper | live TRADING_ENABLED_ON_BOOT=false STAKE_PCT=0.08 MIN_STAKE_USD=25 MAX_STAKE_USD=250 STARTING_BALANCE=1000 STOP_LOSS_PCT=0.30 # tightened after MAE-simulation review (see plan) # Trailing take-profit disabled 2026-04-27 — see src/engine/exit.rs. # TAKE_PROFIT_ACTIVATION_PCT=0.10 # TAKE_PROFIT_GIVEBACK_PCT=0.90 # Cheap-side strategy retired 2026-04-28 — see src/engine/entry.rs. # CHEAP_SIDE_MIN=0.15 # CHEAP_SIDE_MAX=0.45 TIME_LEFT_MIN_MINUTES=4.5 TRADING_HOURS_START_PST=6 TRADING_HOURS_END_PST=17 ALLOW_WEEKENDS=false MAX_ENTRY_SPREAD=0.04 COOLDOWN_AFTER_EXIT_SEC=900 # 15 min cooldown after any exit before re-entering WARMUP_SECS=90 # seconds after boot before first trade allowed # ---- Kelly sizing (quarter-Kelly for binary markets) ---- KELLY_ENABLED=false # true = Kelly sizing; false = flat STAKE_PCT ESTIMATED_PROB=0.50 # bot's believed true win probability KELLY_FRACTION=0.25 # fractional multiplier (0.25 = quarter-Kelly) KELLY_MAX_PCT=0.08 # hard cap as fraction of bankroll LIMIT_EDGE_CAPTURE=0.40 # fraction of edge captured in limit price # ---- Persistence ---- SUPABASE_URL= SUPABASE_SERVICE_ROLE_KEY= PAPER_LEDGER_PATH=./live_trading/paper_ledger.json # ---- HTTP server ---- HTTP_PORT=3000 CONTROL_TOKEN= # ---- Logging ---- RUST_LOG=info,polymarket_btc_5m=debug