Skip to main content
← Back to the current changelog Newer: April 30, 2026 · April 27 trades →

2026-04-27 — Positions: complete Polymarket parity, deterministic resolved-market mark, six new fields, real cursor pagination

/v2/onchain/positions now matches Polymarket’s data-api to the cent on every shared position. Verified across six wallets, 627 total shared positions, 100.00% sub-penny match on unrealized_pnl. What’s new on each position row:
  • initial_value — cost basis in USD of currently held shares. Use this when you need the basis number that matches Polymarket cashPnl.
  • redeemabletrue when the market has resolved and the user can call redeem to claim payout / accept loss. Filter on this with market_status to detect resolved-but-not-yet-redeemed positions.
  • outcome_index — numeric index of this row’s outcome (0 or 1 for binary markets). Stable across the API regardless of UI label.
  • won / winning_outcome_index — present on resolved-win / resolved-loss rows. Explicit booleans / ints so consumers don’t have to parse outcome label strings.
  • opposite_asset — token ID of the binary counterpart outcome on the same market.
What’s fixed on the math:
  • current_price is deterministic on resolved markets. Reads settlement values directly from the CTF contract on Polygon. Returns exactly 1.0 for the winning outcome and 0.0 for the loser, the moment the market settles on chain.
  • market_status never lies. Was previously stuck on "live" for fresh resolutions when our metadata was behind. Now uses the chain timestamp as the authoritative resolution signal: "live", "resolved-win", "resolved-loss", "resolved-unknown", or "closed".
  • unrealized_pnl is byte-identical to Polymarket cashPnl for any position covered by both sources.
/v2/onchain/trades cursor pagination now reports truthful has_more. Previously has_more: false was returned even when more rows existed beyond the requested limit. Walk pages by passing pagination.pagination_key back as ?pagination_key=….
Time filters on /v2/onchain/trades use start_time and end_time (unix seconds), not from / to. Documented and verified.