btc-updown-5m-1790572800 for the BTC 5-minute round that starts at that unix second. Three routes cover a study of them:
/v1/marketslists the rounds, each with its token ids, its outcome and its window.- Market
/tradersgives every wallet’s result in a round. /v1/fillswithinclude=wallet,txgives every fill, with its wallet, for up to 100 rounds per request.
1. List the Rounds
Filter by slug prefix and end date. Each market’sresolution.winningOutcome is 0 (Up) or 1 (Down) once the round has resolved on chain. round carries the window and, for rounds Codex recorded, the opening (strike) and closing (close) reference prices; for older rounds those prices are null.
Python
2. Every Wallet’s Result in a Round
/traders folds each wallet’s fills, splits, merges and redemptions into one row. Once the round has resolved, totalPnl is its settled PnL, fees included. Walk every wallet with offset:
Python
3. Fills with Wallets, 100 Rounds at a Time
Rows are[market, ts, block, logIndex, outcome, side, shares, usd, exchange, isTaker, fee, wallet, tx]: market is the round’s place in your list, and shares and usd are micro-units. A window spans at most 7 days, so start it a little before the first round opens for trading.
Python