Skip to main content
By the end you have three things:
  • A follow list of S and A wallets, ranked by how easy each one is to copy.
  • A poll that prints every new large trade from a wallet on that list, with the Polymarket token id your own order client needs.
  • The fill-by-fill history behind any one of those positions.
You need a Pro API key. See Authentication. The API reads Polymarket and places no orders, so the decision and the order stay in your own code.

1. Build the follow list

Leaderboard returns ranked wallets, highest score first. It lists S, A, and B wallets only, and it has no min_grade parameter, so drop the B wallets in your own code. To page, send the response’s next_cursor back as cursor. If the ranking is rebuilt while you page, or you change category or strategy, the API answers 400 with error.reason cursor_expired. Throw away the rows you collected and request the first page again: continuing from the old cursor would skip wallets.

2. Score each wallet on how easy it is to copy

Batch traders reads 1 to 25 wallets in one request. Send expand: ["quant_metrics"] to get copy_score on each one. Check data_quality before you act on a grade. fresh means the group is tracked and has a clock, not that the clock is recent enough for you: compare as_of with your own limit. unknown means this read cannot date the group. Treat it as not current, never as recent. The official SDKs apply this rule in one call: assessDataQuality in TypeScript, assess_data_quality in Python, AssessDataQuality in Go. A copy_score of null means the wallet has too little history to score. It never means the wallet scored badly, so do not read it as a low score. The code below sorts those wallets to the bottom.

3. Watch for new trades

Whale trades lists recent large trades, newest first. It has no wallet parameter, so compare each row’s trader.address against your follow list in code. To read one wallet’s past trades instead, Whale trades history takes a trader parameter.
To hear about a trade within seconds of 0xinsider storing it, subscribe a webhook to whale_trades_inserted and run the same address match. Alert bot builds that.

4. Read the entry and exit history

Position timeline returns every stored fill for one wallet in one market, newest first. The condition_id parameter is required: take it from market.condition_id on the trade you matched in step 3.
Each event carries running_amount, the wallet’s share balance after that fill, and running_avg_price, the buy-weighted average price it paid. A sell does not change the average. Both include fills from earlier pages, so you do not have to add them up yourself. 0xinsider stores a timeline only for the wallets it syncs most closely. For any other wallet the route answers 404 with error.reason trader_not_tracked. Do not retry that wallet: the answer will not change.

What this does not do

  • Signal before the fill. Every trade in the feed already executed on Polymarket. traded_at is when the fill happened, and price is what that wallet paid, not a quote for you.
  • Place, cancel, or read an order. No endpoint on this API does. Route your order through your own Polymarket client.
  • Filter the live feed by wallet. Match addresses in your own code, as step 3 does.
  • Show a small fill from a wallet you follow. The feed carries large trades only, so anything too small to be recorded as a whale trade never appears in it.
  • Serve a timeline for a wallet 0xinsider does not sync closely.
Backtest a trader checks a wallet’s profit and loss curve before you follow it. Quant metrics defines copy_score and smart_score.