Skip to main content
Event: trader_pnl_exits
Endpoint: wss://api.struct.to/ws/alerts
Cost: 0.025 credits per event
Fires once each time a tracked trader closes a position, emitting a single exit marker with the realized result. Each marker is designed to be overlaid on a PnL chart so you can see exactly where a trader entered and left a market.

Filters

FilterTypeRequiredDescription
tradersstring[]NoSpecific trader wallet addresses (max 500)
condition_idsstring[]NoRestrict to specific markets (max 500)
event_slugsstring[]NoRestrict to specific events (max 500)

Exit reasons

Each marker carries a reason describing how the position closed:
ReasonMeaning
resolved_winHeld to market resolution and won by verdict
resolved_lossHeld to market resolution and lost by verdict
sold_winClosed before resolution with a positive realized PnL
sold_lossClosed before resolution with a negative realized PnL

Subscribe

{
  "op": "subscribe",
  "event": "trader_pnl_exits",
  "traders": ["0x37BA57e2942A57F05B5E4BCFD4d027845cFC40ec"]
}

Response

{
  "event": "trader_pnl_exits",
  "timestamp": 1775913505260,
  "data": {
    "trader": "0x37BA57e2942A57F05B5E4BCFD4d027845cFC40ec",
    "position_id": "21742633143463906290569050155826241533067272736897614950488156847949938836455",
    "condition_id": "0x4fec624c0ff2bfae89956cebd6fbc9c58f995f824382dc587dc5a32a4b15940b",
    "event_slug": "2026-us-midterm-elections",
    "market_slug": "will-candidate-x-win",
    "title": "Will Candidate X win?",
    "question": "Will Candidate X win the 2026 election?",
    "image_url": "https://polymarket-upload.s3.us-east-2.amazonaws.com/example.png",
    "outcome": "Yes",
    "outcome_index": 0,
    "pnl_usd": 1700.00,
    "pnl_pct": 56.67,
    "cost_basis_usd": 3000.00,
    "reason": "resolved_win",
    "block": 68554321,
    "ts": 1713052800
  }
}
Last modified on June 13, 2026