@0xinsider/mcp 3.6.2 → 3.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/README.md +44 -17
  2. package/dist/constants.d.ts +1 -1
  3. package/dist/constants.js +1 -1
  4. package/dist/product-cli/index.d.ts.map +1 -1
  5. package/dist/product-cli/index.js +162 -26
  6. package/dist/product-cli/index.js.map +1 -1
  7. package/dist/product-cli/operations.d.ts +24 -0
  8. package/dist/product-cli/operations.d.ts.map +1 -0
  9. package/dist/product-cli/operations.js +222 -0
  10. package/dist/product-cli/operations.js.map +1 -0
  11. package/dist/prompts/index.js +2 -2
  12. package/dist/sdk/client.d.ts +67 -155
  13. package/dist/sdk/client.d.ts.map +1 -1
  14. package/dist/sdk/client.js +75 -150
  15. package/dist/sdk/client.js.map +1 -1
  16. package/dist/sdk/errors.d.ts +6 -5
  17. package/dist/sdk/errors.d.ts.map +1 -1
  18. package/dist/sdk/errors.js +13 -5
  19. package/dist/sdk/errors.js.map +1 -1
  20. package/dist/sdk/index.d.ts +3 -25
  21. package/dist/sdk/index.d.ts.map +1 -1
  22. package/dist/sdk/index.js +2 -1
  23. package/dist/sdk/index.js.map +1 -1
  24. package/dist/sdk/pagination.d.ts +3 -3
  25. package/dist/sdk/pagination.js +2 -2
  26. package/dist/sdk/schema.d.ts +372 -191
  27. package/dist/sdk/schema.d.ts.map +1 -1
  28. package/dist/sdk/webhooks.d.ts +8 -60
  29. package/dist/sdk/webhooks.d.ts.map +1 -1
  30. package/dist/sdk/webhooks.js.map +1 -1
  31. package/dist/tools/explore-markets.js +2 -2
  32. package/dist/tools/explore-markets.js.map +1 -1
  33. package/dist/tools/get-insider-radar.js +1 -1
  34. package/dist/tools/get-insider-radar.js.map +1 -1
  35. package/dist/tools/get-leaderboard.d.ts.map +1 -1
  36. package/dist/tools/get-leaderboard.js +5 -14
  37. package/dist/tools/get-leaderboard.js.map +1 -1
  38. package/dist/tools/get-market-flow.js +1 -1
  39. package/dist/tools/get-trader-pnl.js +3 -3
  40. package/dist/tools/get-trader-pnl.js.map +1 -1
  41. package/dist/tools/get-trader.js +3 -3
  42. package/dist/tools/get-trending-wallets.js +1 -1
  43. package/dist/tools/get-whale-trades.js +3 -3
  44. package/dist/tools/get-whale-trades.js.map +1 -1
  45. package/dist/tools/pick-of-the-day.js +2 -2
  46. package/dist/tools/read-parity.js +14 -14
  47. package/dist/tools/read-parity.js.map +1 -1
  48. package/dist/tools/trader-reads.js +1 -1
  49. package/package.json +5 -5
@@ -3,7 +3,8 @@ export type AccountIdentity = {
3
3
  data: {
4
4
  user_id: number;
5
5
  credential_id: number;
6
- credential_kind: "api_key" | "oauth_grant";
6
+ /** The kind of credential that made the request: api_key is a full-access developer key, oauth_grant an OAuth access token, integration_key a named integration key with fixed scopes created on https://0xinsider.com/developers. Before integration_key was added, these keys reported oauth_grant. */
7
+ credential_kind: "api_key" | "oauth_grant" | "integration_key";
7
8
  /** The credential is currently valid; revoked, expired or unknown credentials are rejected. */
8
9
  credential_status: "active";
9
10
  entitlement: {
@@ -11,7 +12,7 @@ export type AccountIdentity = {
11
12
  /** When paid data access is lapsed, the caller should renew the subscription; otherwise null. */
12
13
  recovery_action: "renew_subscription" | null;
13
14
  };
14
- /** Approved OAuth scopes; null for full developer-key access. */
15
+ /** The scopes an OAuth grant or integration key carries; null for full developer-key access. */
15
16
  scopes: string[] | null;
16
17
  };
17
18
  meta: ResponseMeta;
@@ -76,8 +77,8 @@ export type ApiError = {
76
77
  /** The recommended next request instant (RFC3339), always in the future. Present on every retryable error: `pick_not_released`, `rate_limited`, `rate_limit_unavailable`, and `read_model_warming`. Omitted otherwise. The absolute twin of `Retry-After`; prefer the header for the sleep duration. For `pick_not_released`, the earliest of the next scheduled release, the next automatic selector attempt, the operating-window start, or about 60 seconds. See that response. */
77
78
  retry_at?: string;
78
79
  freshness?: FreshnessFailure;
79
- /** ADDITIVE (#7209). The specific, actionable cause behind `code`, when there is one more specific than the code itself. `code` keeps its published values, so existing clients are unaffected; new clients branch on `reason`. Omitted when the code already says everything we know. pick_not_released: no Pick of the Day is published for the current product day; schedule one request against retry_at instead of polling. unknown_endpoint: the PATH is not a route on this API -- read GET /api/v1, do not retry. trader_not_tracked: the wallet is real and the URL is right, but the trader is not on the warm sync tier (the wallets we sync most often) -- stop asking for this wallet. market_out_of_scope (404 not_found, #27303): the market or event is real and the URL is right, but 0xinsider serves sports and esports markets only -- stop asking for this market; neither a retry nor another URL for it can succeed. cursor_expired: pagination went stale mid-walk -- re-request the first page and continue. read_model_warming: the requested endpoint cannot serve its read model yet; exact causes are endpoint-specific and can include a cold or contended refresh or a dependency that prevented refresh. database_unavailable: the API's database or its connection pool is temporarily unreachable (a connection-class failure, not a query fault); code stays rate_limit_unavailable, nothing is rate-limited, retry after Retry-After / retry_at. idempotency_in_progress: retain the exact Idempotency-Key and request body, then retry shortly. webhook_delivery_in_progress: retry the URL or signing-secret configuration change after the destination's active request completes. request_accounting_unavailable: accounting capacity is unavailable before the handler executes; retry after Retry-After / retry_at. sandbox_api_key: the credential is a sandbox key (oxi_sk_test_) from POST /api/v1/agents/register, which only the sandbox server accepts -- call the sandbox base URL with it, or get a live key or OAuth access token; do not retry it here. api_key_in_query: the key was sent as a ?token= query parameter, which no route reads because URLs land in logs and history; the key itself was not checked -- resend it as Authorization: Bearer. subscription_inactive: the key is valid but the account's Pro subscription has lapsed (402 subscription_required); permanent until a person reactivates at https://0xinsider.com/billing, which the message names -- stop retrying on a schedule and surface the link. The key owner is emailed once per lapse. monthly_quota_exceeded: the account has used the requests its plan includes for the UTC calendar month (429 rate_limited); retry_at and Retry-After name the first of next month, the only retry that can succeed, and the message names https://0xinsider.com/developers, where pay as you go for requests over the quota is turned on. The X-Monthly-Quota-Limit, X-Monthly-Quota-Remaining and X-Monthly-Quota-Reset headers on every authenticated response say how close the account is. invalid_query, invalid_path, invalid_body (400 bad_request, #16146): a query parameter, a path segment or the JSON body did not parse or does not fit the route's schema, so no handler ran; param names the field when the parser named one (a query key, a path segment, a JSON path such as traders[0], or body); fix the request, never retry it as sent. unsupported_media_type (415 bad_request, param content-type): send the body with Content-Type: application/json. payload_too_large (413 bad_request, param body): the body is over 1048576 bytes. method_not_allowed (405 bad_request): the path is a route but not with this method; the Allow header names the methods it serves. ip_rate_limited (429 rate_limited, #16380): the per-address budget every caller behind one IP shares, counted before authentication, is spent; not the key's own window, and the RateLimit-* headers describe that bucket. ip_throttled (429 rate_limited): the address is in a cooldown after sustained over-limit traffic; Retry-After is minutes to days, and a request before it does not shorten the cooldown. max_plan_required (403 forbidden, #23085): the key is valid and its account is on Pro, but the route is part of Max (GET /api/v1/edge-hunter); every Pro route keeps working with the same key, so do not disable it. The message names https://0xinsider.com/pricing, where the account upgrades; a retry never clears it. endpoint_retired (410): this legacy sports endpoint no longer serves data. Migrate to GET /api/v1/edge-hunter; retrying the retired path cannot succeed. */
80
- reason?: "cursor_expired" | "unknown_endpoint" | "pick_not_released" | "trader_not_tracked" | "market_out_of_scope" | "read_model_warming" | "database_unavailable" | "request_accounting_unavailable" | "idempotency_in_progress" | "webhook_delivery_in_progress" | "webhook_secret_rotation_not_prepared" | "webhook_secret_rotation_overlap_active" | "sandbox_api_key" | "api_key_in_query" | "subscription_inactive" | "monthly_quota_exceeded" | "invalid_query" | "unknown_query_parameter" | "invalid_path" | "invalid_body" | "unsupported_media_type" | "payload_too_large" | "method_not_allowed" | "ip_rate_limited" | "ip_throttled" | "export_expired" | "freshness_ceiling_unsatisfied" | "max_plan_required" | "endpoint_retired";
80
+ /** ADDITIVE (#7209). The specific, actionable cause behind `code`, when there is one more specific than the code itself. `code` keeps its published values, so existing clients are unaffected; new clients branch on `reason`. Omitted when the code already says everything we know. pick_not_released: no Pick of the Day is published for the current product day; schedule one request against retry_at instead of polling. unknown_endpoint: the PATH is not a route on this API -- read GET /api/v1, do not retry. trader_not_tracked: the wallet is real and the URL is right, but the trader is not on the warm sync tier (the wallets we sync most often) -- stop asking for this wallet. market_out_of_scope (404 not_found, #27303): the market or event is real and the URL is right, but 0xinsider serves sports and esports markets only -- stop asking for this market; neither a retry nor another URL for it can succeed. cursor_expired: pagination went stale mid-walk -- re-request the first page and continue. read_model_warming: the requested endpoint cannot serve its read model yet; exact causes are endpoint-specific and can include a cold or contended refresh or a dependency that prevented refresh. database_unavailable: the API's database or its connection pool is temporarily unreachable (a connection-class failure, not a query fault); code stays rate_limit_unavailable, nothing is rate-limited, retry after Retry-After / retry_at. idempotency_in_progress: retain the exact Idempotency-Key and request body, then retry shortly. webhook_delivery_in_progress: retry the URL or signing-secret configuration change after the destination's active request completes. request_accounting_unavailable: accounting capacity is unavailable before the handler executes; retry after Retry-After / retry_at. sandbox_api_key: the credential is a sandbox key (oxi_sk_test_) from POST /api/v1/agents/register, which only the sandbox server accepts -- call the sandbox base URL with it, or get a live key or OAuth access token; do not retry it here. api_key_in_query: the key was sent as a ?token= query parameter, which no route reads because URLs land in logs and history; the key itself was not checked -- resend it as Authorization: Bearer. subscription_inactive: the key is valid but the account's Pro subscription has lapsed (402 subscription_required); permanent until a person reactivates at https://0xinsider.com/billing, which the message names -- stop retrying on a schedule and surface the link. The key owner is emailed once per lapse. monthly_quota_exceeded: the account has used the requests its plan includes for the UTC calendar month (429 rate_limited); retry_at and Retry-After name the first of next month, the only retry that can succeed, and the message names https://0xinsider.com/developers, where pay as you go for requests over the quota is turned on. The X-Monthly-Quota-Limit, X-Monthly-Quota-Remaining and X-Monthly-Quota-Reset headers on every authenticated response say how close the account is. invalid_query, invalid_path, invalid_body (400 bad_request, #16146): a query parameter, a path segment or the JSON body did not parse or does not fit the route's schema, so no handler ran; param names the field when the parser named one (a query key, a path segment, a JSON path such as traders[0], or body); fix the request, never retry it as sent. unsupported_media_type (415 bad_request, param content-type): send the body with Content-Type: application/json. payload_too_large (413 bad_request, param body): the body is over 1048576 bytes. method_not_allowed (405 bad_request): the path is a route but not with this method; the Allow header names the methods it serves. ip_rate_limited (429 rate_limited, #16380): the per-address budget every caller behind one IP shares, counted before authentication, is spent; not the key's own window, and the RateLimit-* headers describe that bucket. ip_throttled (429 rate_limited): the address is in a cooldown after sustained over-limit traffic; Retry-After is minutes to days, and a request before it does not shorten the cooldown. cold_read_limited (429 rate_limited, #28752): the account has used its share of cold reads on GET /api/v1/market/{condition_id}/holders, requests for a market whose roster is not cached, each of which walks Polymarket (6 a minute, in bursts of up to 400); not the per-minute window, so a cached market still answers, and the next cold read is admitted at Retry-After. max_plan_required (403 forbidden, #23085): the key is valid and its account is on Pro, but the route is part of Max (GET /api/v1/edge-hunter); every Pro route keeps working with the same key, so do not disable it. The message names https://0xinsider.com/pricing, where the account upgrades; a retry never clears it. endpoint_retired (410): this legacy sports endpoint no longer serves data. Migrate to GET /api/v1/edge-hunter; retrying the retired path cannot succeed. */
81
+ reason?: "cursor_expired" | "unknown_endpoint" | "pick_not_released" | "trader_not_tracked" | "market_out_of_scope" | "read_model_warming" | "database_unavailable" | "request_accounting_unavailable" | "idempotency_in_progress" | "webhook_delivery_in_progress" | "webhook_secret_rotation_not_prepared" | "webhook_secret_rotation_overlap_active" | "sandbox_api_key" | "api_key_in_query" | "subscription_inactive" | "monthly_quota_exceeded" | "invalid_query" | "unknown_query_parameter" | "invalid_path" | "invalid_body" | "unsupported_media_type" | "payload_too_large" | "method_not_allowed" | "ip_rate_limited" | "ip_throttled" | "cold_read_limited" | "export_expired" | "freshness_ceiling_unsatisfied" | "max_plan_required" | "endpoint_retired";
81
82
  };
82
83
  meta: ResponseMeta;
83
84
  };
@@ -90,8 +91,8 @@ export type ApiErrorBody = {
90
91
  /** The recommended next retry instant (RFC3339). Present on every retryable error (reason=pick_not_released, code=rate_limited including reason=monthly_quota_exceeded, code=rate_limit_unavailable, reason=read_model_warming) and omitted otherwise. Always in the future. For pick_not_released, the recommendation is advisory and can change before a pick becomes available. Schedule the next request from the returned value instead of inferring a release schedule or polling. Prefer Retry-After for the duration because it is immune to client clock skew. */
91
92
  retry_at?: string;
92
93
  freshness?: FreshnessFailure;
93
- /** ADDITIVE (#7209). The specific, actionable cause behind `code`, when there is one more specific than the code itself. `code` keeps its published values, so existing clients are unaffected; new clients branch on `reason`. Omitted when the code already says everything we know. pick_not_released: no Pick of the Day is published for the current product day; schedule one request against retry_at instead of polling. unknown_endpoint: the PATH is not a route on this API -- read GET /api/v1, do not retry. trader_not_tracked: the wallet is real and the URL is right, but the trader is not on the warm sync tier (the wallets we sync most often) -- stop asking for this wallet. market_out_of_scope (404 not_found, #27303): the market or event is real and the URL is right, but 0xinsider serves sports and esports markets only -- stop asking for this market; neither a retry nor another URL for it can succeed. cursor_expired: pagination went stale mid-walk -- re-request the first page and continue. read_model_warming: the requested endpoint cannot serve its read model yet; exact causes are endpoint-specific and can include a cold or contended refresh or a dependency that prevented refresh. database_unavailable: the API's database or its connection pool is temporarily unreachable (a connection-class failure, not a query fault); code stays rate_limit_unavailable, nothing is rate-limited, retry after Retry-After / retry_at. idempotency_in_progress: retain the exact Idempotency-Key and request body, then retry shortly. webhook_delivery_in_progress: retry the URL or signing-secret configuration change after the destination's active request completes. request_accounting_unavailable: accounting capacity is unavailable before the handler executes; retry after Retry-After / retry_at. sandbox_api_key: the credential is a sandbox key (oxi_sk_test_) from POST /api/v1/agents/register, which only the sandbox server accepts -- call the sandbox base URL with it, or get a live key or OAuth access token; do not retry it here. api_key_in_query: the key was sent as a ?token= query parameter, which no route reads because URLs land in logs and history; the key itself was not checked -- resend it as Authorization: Bearer. subscription_inactive: the key is valid but the account's Pro subscription has lapsed (402 subscription_required); permanent until a person reactivates at https://0xinsider.com/billing, which the message names -- stop retrying on a schedule and surface the link. The key owner is emailed once per lapse. monthly_quota_exceeded: the account has used the requests its plan includes for the UTC calendar month (429 rate_limited); retry_at and Retry-After name the first of next month, the only retry that can succeed, and the message names https://0xinsider.com/developers, where pay as you go for requests over the quota is turned on. The X-Monthly-Quota-Limit, X-Monthly-Quota-Remaining and X-Monthly-Quota-Reset headers on every authenticated response say how close the account is. invalid_query, invalid_path, invalid_body (400 bad_request, #16146): a query parameter, a path segment or the JSON body did not parse or does not fit the route's schema, so no handler ran; param names the field when the parser named one (a query key, a path segment, a JSON path such as traders[0], or body); fix the request, never retry it as sent. unsupported_media_type (415 bad_request, param content-type): send the body with Content-Type: application/json. payload_too_large (413 bad_request, param body): the body is over 1048576 bytes. method_not_allowed (405 bad_request): the path is a route but not with this method; the Allow header names the methods it serves. ip_rate_limited (429 rate_limited, #16380): the per-address budget every caller behind one IP shares, counted before authentication, is spent; not the key's own window, and the RateLimit-* headers describe that bucket. ip_throttled (429 rate_limited): the address is in a cooldown after sustained over-limit traffic; Retry-After is minutes to days, and a request before it does not shorten the cooldown. max_plan_required (403 forbidden, #23085): the key is valid and its account is on Pro, but the route is part of Max (GET /api/v1/edge-hunter); every Pro route keeps working with the same key, so do not disable it. The message names https://0xinsider.com/pricing, where the account upgrades; a retry never clears it. endpoint_retired (410): this legacy sports endpoint no longer serves data. Migrate to GET /api/v1/edge-hunter; retrying the retired path cannot succeed. */
94
- reason?: "cursor_expired" | "unknown_endpoint" | "pick_not_released" | "trader_not_tracked" | "market_out_of_scope" | "read_model_warming" | "database_unavailable" | "request_accounting_unavailable" | "idempotency_in_progress" | "webhook_delivery_in_progress" | "webhook_secret_rotation_not_prepared" | "webhook_secret_rotation_overlap_active" | "sandbox_api_key" | "api_key_in_query" | "subscription_inactive" | "monthly_quota_exceeded" | "invalid_query" | "unknown_query_parameter" | "invalid_path" | "invalid_body" | "unsupported_media_type" | "payload_too_large" | "method_not_allowed" | "ip_rate_limited" | "ip_throttled" | "export_expired" | "freshness_ceiling_unsatisfied" | "max_plan_required" | "endpoint_retired";
94
+ /** ADDITIVE (#7209). The specific, actionable cause behind `code`, when there is one more specific than the code itself. `code` keeps its published values, so existing clients are unaffected; new clients branch on `reason`. Omitted when the code already says everything we know. pick_not_released: no Pick of the Day is published for the current product day; schedule one request against retry_at instead of polling. unknown_endpoint: the PATH is not a route on this API -- read GET /api/v1, do not retry. trader_not_tracked: the wallet is real and the URL is right, but the trader is not on the warm sync tier (the wallets we sync most often) -- stop asking for this wallet. market_out_of_scope (404 not_found, #27303): the market or event is real and the URL is right, but 0xinsider serves sports and esports markets only -- stop asking for this market; neither a retry nor another URL for it can succeed. cursor_expired: pagination went stale mid-walk -- re-request the first page and continue. read_model_warming: the requested endpoint cannot serve its read model yet; exact causes are endpoint-specific and can include a cold or contended refresh or a dependency that prevented refresh. database_unavailable: the API's database or its connection pool is temporarily unreachable (a connection-class failure, not a query fault); code stays rate_limit_unavailable, nothing is rate-limited, retry after Retry-After / retry_at. idempotency_in_progress: retain the exact Idempotency-Key and request body, then retry shortly. webhook_delivery_in_progress: retry the URL or signing-secret configuration change after the destination's active request completes. request_accounting_unavailable: accounting capacity is unavailable before the handler executes; retry after Retry-After / retry_at. sandbox_api_key: the credential is a sandbox key (oxi_sk_test_) from POST /api/v1/agents/register, which only the sandbox server accepts -- call the sandbox base URL with it, or get a live key or OAuth access token; do not retry it here. api_key_in_query: the key was sent as a ?token= query parameter, which no route reads because URLs land in logs and history; the key itself was not checked -- resend it as Authorization: Bearer. subscription_inactive: the key is valid but the account's Pro subscription has lapsed (402 subscription_required); permanent until a person reactivates at https://0xinsider.com/billing, which the message names -- stop retrying on a schedule and surface the link. The key owner is emailed once per lapse. monthly_quota_exceeded: the account has used the requests its plan includes for the UTC calendar month (429 rate_limited); retry_at and Retry-After name the first of next month, the only retry that can succeed, and the message names https://0xinsider.com/developers, where pay as you go for requests over the quota is turned on. The X-Monthly-Quota-Limit, X-Monthly-Quota-Remaining and X-Monthly-Quota-Reset headers on every authenticated response say how close the account is. invalid_query, invalid_path, invalid_body (400 bad_request, #16146): a query parameter, a path segment or the JSON body did not parse or does not fit the route's schema, so no handler ran; param names the field when the parser named one (a query key, a path segment, a JSON path such as traders[0], or body); fix the request, never retry it as sent. unsupported_media_type (415 bad_request, param content-type): send the body with Content-Type: application/json. payload_too_large (413 bad_request, param body): the body is over 1048576 bytes. method_not_allowed (405 bad_request): the path is a route but not with this method; the Allow header names the methods it serves. ip_rate_limited (429 rate_limited, #16380): the per-address budget every caller behind one IP shares, counted before authentication, is spent; not the key's own window, and the RateLimit-* headers describe that bucket. ip_throttled (429 rate_limited): the address is in a cooldown after sustained over-limit traffic; Retry-After is minutes to days, and a request before it does not shorten the cooldown. cold_read_limited (429 rate_limited, #28752): the account has used its share of cold reads on GET /api/v1/market/{condition_id}/holders, requests for a market whose roster is not cached, each of which walks Polymarket (6 a minute, in bursts of up to 400); not the per-minute window, so a cached market still answers, and the next cold read is admitted at Retry-After. max_plan_required (403 forbidden, #23085): the key is valid and its account is on Pro, but the route is part of Max (GET /api/v1/edge-hunter); every Pro route keeps working with the same key, so do not disable it. The message names https://0xinsider.com/pricing, where the account upgrades; a retry never clears it. endpoint_retired (410): this legacy sports endpoint no longer serves data. Migrate to GET /api/v1/edge-hunter; retrying the retired path cannot succeed. */
95
+ reason?: "cursor_expired" | "unknown_endpoint" | "pick_not_released" | "trader_not_tracked" | "market_out_of_scope" | "read_model_warming" | "database_unavailable" | "request_accounting_unavailable" | "idempotency_in_progress" | "webhook_delivery_in_progress" | "webhook_secret_rotation_not_prepared" | "webhook_secret_rotation_overlap_active" | "sandbox_api_key" | "api_key_in_query" | "subscription_inactive" | "monthly_quota_exceeded" | "invalid_query" | "unknown_query_parameter" | "invalid_path" | "invalid_body" | "unsupported_media_type" | "payload_too_large" | "method_not_allowed" | "ip_rate_limited" | "ip_throttled" | "cold_read_limited" | "export_expired" | "freshness_ceiling_unsatisfied" | "max_plan_required" | "endpoint_retired";
95
96
  };
96
97
  export type BatchMarketFlowItem = {
97
98
  /** Zero-based request index. Duplicate inputs keep separate result rows. */
@@ -267,8 +268,6 @@ export type ComboFillsResponse = {
267
268
  /** Continuation offset for largest or payout ordering. */
268
269
  next_offset?: number;
269
270
  meta: ResponseMeta;
270
- /** Not computed for combo fill pages; omitted. */
271
- total?: number;
272
271
  };
273
272
  export type ComboLeg = {
274
273
  leg_index: number;
@@ -392,7 +391,8 @@ export type CounterpartyAnalysis = {
392
391
  };
393
392
  export type CounterpartyExecution = {
394
393
  execution_id: string;
395
- exchange_family: "ctf_v2" | "neg_risk_ctf_v2";
394
+ /** Polymarket exchange contract that emitted the execution: `ctf_v2` the CTF Exchange v2, `neg_risk_ctf_v2` the Neg Risk CTF Exchange v2, `exchange_v3` ExchangeV3, which settles Polymarket Protocol V2 binary and neg-risk markets. Treat an unknown value as another exchange. */
395
+ exchange_family: "ctf_v2" | "neg_risk_ctf_v2" | "exchange_v3";
396
396
  transaction_hash: string;
397
397
  orders_matched_log_index: number;
398
398
  taker: CounterpartyParticipant;
@@ -603,7 +603,7 @@ export type EdgeHunterObservation = {
603
603
  provider_read_source: "cached" | "live";
604
604
  /** True only when the provider page read for each outcome token listed every holder of that token. Observation collection reads one 100-row page per token; a token with more holders stays incomplete. False means holder counts and dollar totals measure the observed positive-holder subset. sharp_pct describes that observed subset and is not a lower bound on the full-population percentage. Incomplete scans cannot satisfy a future capital-promotion gate. */
605
605
  holder_scan_complete: boolean;
606
- /** Proven provider holder observation time. A warm cache hit uses only the original provider completion time from its companion metadata, never cache-read time. A wider_holder or emerging_pile row whose holder read did not finish in the current pass may reuse that market's last pregame holder page for up to 15 minutes; an in_play row may reuse its last in-play page, read after the provider reported the game live and never before that market's own kickoff, for up to 10 minutes. Both ages are counted when the snapshot is computed. Either reuse carries that page's original time here and provider_read_source cached. A pregame market more than an hour before kickoff reuses its last page the same way until that page is 10 minutes old, and only then is read again. Once that market's own kickoff has passed, an in_play row with provider_read_source cached, a warm hit or a reuse, never carries a page read before it. Null, malformed, future, or stale holder time fails in-play closed. */
606
+ /** Proven provider holder observation time. A warm cache hit uses only the original provider completion time from its companion metadata, never cache-read time. A wider_holder or emerging_pile row whose holder read did not finish or failed in the current pass may reuse that market's last pregame holder page for up to 15 minutes; an in_play row may reuse its last in-play page, read after the provider reported the game live and never before that market's own kickoff, for up to 10 minutes. Both ages are counted when the snapshot is computed. Either reuse carries that page's original time here and provider_read_source cached. A pregame market more than an hour before kickoff reuses its last page the same way until that page is 10 minutes old, and only then is read again; while that market has had no trade since the page, it keeps reusing the page until it is 30 minutes old. Once that market's own kickoff has passed, an in_play row with provider_read_source cached, a warm hit or a reuse, never carries a page read before it. Null, malformed, future, or stale holder time fails in-play closed. */
607
607
  holder_snapshot_at: string | null;
608
608
  /** Truthful state of the directional read, which classifies each graded holder by its fresh synced legs across the game's markets and, when holder_scan_complete is true, by Polymarket's currentValue on both outcomes of this market. A wider_holder row can remain emitted with unavailable and terminal wider_holder_emitted; in_play fails closed instead and terminates as in_play_directional_unavailable. */
609
609
  directional_status: "available" | "unknown_ungrouped" | "unknown_stale" | "unavailable";
@@ -622,7 +622,7 @@ export type EdgeHunterObservation = {
622
622
  export type EdgeHunterObservationCoverage = {
623
623
  /** Sum of canonical source-generation funnel input across all sports, before category, cohort or selector projection. */
624
624
  input_markets: number;
625
- /** Canonical source-generation input assigned capacity_limited. These markets were intentionally outside the bounded holder-work admission and are not missing emitted rows. */
625
+ /** Canonical source-generation input assigned capacity_limited. These markets were intentionally outside the bounded holder-work admission and are not missing emitted rows. It includes the admitted pregame wider_holder markets of any sport no request named in the last 30 minutes, whose holders the generation did not read. */
626
626
  capacity_limited_markets: number;
627
627
  /** All wider_holder and in_play observations emitted in the canonical source generation, before cohort, category or selector projection. Emerging pile is an overlapping projection and does not add source emissions. */
628
628
  emitted_observations: number;
@@ -655,7 +655,7 @@ export type EdgeHunterObservationDeparture = {
655
655
  last_observed_at: string;
656
656
  /** snapshot_as_of of the first snapshot of this selection without the card. */
657
657
  departed_at: string;
658
- /** Why the market has no card: its terminal in this selection's funnel in the snapshot it left, and while that terminal reports a read that did not finish (holder_deadline_unavailable, provider_unavailable, holder_computation_unavailable, internal_unclassified), the terminal of each later snapshot until one answers; an answered reason never changes. primary_slate_candidate: the market joined the funded slate, which view=signals covers. capacity_limited: it lost its evaluation place without another outcome. missing_stored_market: the market was no longer in the stored market universe. Any other value means what it means in the funnel, for example split_holder_pile, no_current_graded_holder or resolved. */
658
+ /** Why the market has no card: its terminal in this selection's funnel in the snapshot it left, and while that terminal reports a read that did not finish (holder_deadline_unavailable, provider_unavailable, holder_computation_unavailable, internal_unclassified), the terminal of each later snapshot until one answers; an answered reason stays, except as view=signals starts or stops listing the market. primary_slate_candidate: view=signals lists the market. While the entry stays, a later snapshot that read view=signals and no longer excludes the market replaces it with that snapshot's terminal, one that excludes the market replaces any other reason with it, and one with signals_as_of null leaves it as it is. capacity_limited: it lost its evaluation place without another outcome. missing_stored_market: the market was no longer in the stored market universe. Any other value means what it means in the funnel, for example split_holder_pile, no_current_graded_holder or resolved. */
659
659
  reason: EdgeHunterObservationTerminalReason;
660
660
  };
661
661
  /** Full Edge Hunter observations list envelope. Required degradation_reasons explains the source-generation verdict; required coverage distinguishes source input, intentional capacity exclusions, source emissions, incomplete holder scans, selection and the returned page. The view literal distinguishes advanced collections, including empty pages. */
@@ -679,10 +679,12 @@ export type EdgeHunterObservationsResponse = {
679
679
  selection?: EdgeHunterSelection;
680
680
  /** Echoes the opt-in admission rule a request named; omitted on a default read. When present, data, funnel, coverage, degraded and degradation_reasons describe that selection, not the default one. */
681
681
  admission?: "most_held_48h";
682
- /** cohort=wider_holder only, for the default selection and for admission=most_held_48h: markets that had a wider_holder card in an earlier snapshot of the same selection, have none in this one, and have not kicked off. Newest departed_at first. An entry stays until the game_start_time it carries passes, and leaves as soon as the market has a card again; while it stays only a reason that reports an unfinished read changes (see reason), and a later departure of the same market is a new entry. Filtered by the same category and selectors as data, and identical on every page of one snapshot. At most 336 entries; when more are open, the oldest departures leave first. An empty array means no card of this selection is departed. Omitted on in_play and emerging_pile, and on a snapshot that could not establish its departures, never reported as an empty array. Tracking that restarts after its record is lost starts empty. */
682
+ /** cohort=wider_holder only, for the default selection and for admission=most_held_48h: markets that had a wider_holder card in an earlier snapshot of the same selection, have none in this one, and have not kicked off. Newest departed_at first. An entry stays until the game_start_time it carries passes, and leaves as soon as the market has a card again; while it stays, its reason changes only while it reports an unfinished read or when view=signals starts or stops listing the market (see reason), and a later departure of the same market is a new entry. Filtered by the same category and selectors as data, and identical on every page of one snapshot. At most 336 entries; when more are open, the oldest departures leave first. An empty array means no card of this selection is departed. Omitted on in_play and emerging_pile, and on a snapshot that could not establish its departures, never reported as an empty array. Tracking that restarts after its record is lost starts empty. */
683
683
  departures?: EdgeHunterObservationDeparture[];
684
+ /** The ranked_at of the view=signals snapshot whose listed markets this snapshot excluded from wider_holder as primary_slate_candidate. The refresh that computed this snapshot read it as it started, so it can be one refresh older than the view=signals snapshot a reader sees at the same moment. null when no view=signals snapshot could be read: that refresh excluded no market, and the funnel counts no primary_slate_candidate. Omitted on an unmappable legacy category, which reads no generation. */
685
+ signals_as_of?: string | null;
684
686
  };
685
- /** Closed 25-value terminal-reason vocabulary for the accountable Edge Hunter observation funnel. capacity_limited is intentional bounded provider-work admission and does not itself set the snapshot degraded. board_source_unavailable is a completed board-source failure; board_deadline_unavailable means live-board work missed either an internal configured-scope deadline or the outer fair-wave deadline; both classify only already-started rows, so for the upcoming source read funnel.sports[].board_upcoming_status instead; provider_unavailable is reserved for an attempted holder-provider failure; holder_deadline_unavailable is holder cache/provider absolute-deadline exhaustion. */
687
+ /** Closed 25-value terminal-reason vocabulary for the accountable Edge Hunter observation funnel. capacity_limited is intentional bounded provider-work admission and does not itself set the snapshot degraded. board_source_unavailable is a completed board-source failure; board_deadline_unavailable means live-board work missed either an internal configured-scope deadline or the outer fair-wave deadline; both classify only already-started rows, so for the upcoming source read funnel.sports[].board_upcoming_status instead; provider_unavailable is reserved for a holder read sent to the provider that failed, with no reusable holder page; holder_deadline_unavailable is holder cache/provider absolute-deadline exhaustion or a holder read local capacity never sent, with no reusable holder page. */
686
688
  export type EdgeHunterObservationTerminalReason = "outside_horizon" | "resolved" | "provider_closed" | "provider_excluded" | "invalid_market" | "missing_token" | "missing_stored_market" | "not_provider_live" | "board_source_unavailable" | "board_deadline_unavailable" | "primary_slate_candidate" | "zero_indexed_holder_research" | "capacity_limited" | "provider_unavailable" | "holder_deadline_unavailable" | "holder_computation_unavailable" | "holder_scan_incomplete" | "no_current_graded_holder" | "split_holder_pile" | "price_unavailable" | "wider_holder_emitted" | "in_play_emitted" | "in_play_stale_observed" | "in_play_directional_unavailable" | "internal_unclassified";
687
689
  /** One provider outcome in fixed YES/NO order, including its frozen token identity and independently observed quote. Null current_price means no verified current quote is available. */
688
690
  export type EdgeHunterOutcome = {
@@ -702,6 +704,8 @@ export type EdgeHunterParticipant = {
702
704
  headshot_revision?: number;
703
705
  tour?: string;
704
706
  name: string;
707
+ logo_mark_light?: boolean;
708
+ logo_mark_measured?: boolean;
705
709
  };
706
710
  export type EdgeHunterPrice = {
707
711
  /** Provider probability as a decimal string. Keep its precision until display. */
@@ -877,15 +881,15 @@ export type EdgeHunterSportFunnelReport = {
877
881
  board_live_available: boolean;
878
882
  /** Whether a provider-backed upcoming-board source is configured and applicable for this sport. False means not applicable, not provider failure. */
879
883
  board_upcoming_configured: boolean;
880
- /** Whether every configured upcoming-board scope completed as available. False with board_upcoming_configured=false means not applicable. When board_upcoming_configured is true and this flag is false, read board_upcoming_status for the cause (it reads unknown, i.e. no recorded cause, only on a snapshot cached before that field existed, which self-clears within one TTL): the board_source_unavailable and board_deadline_unavailable terminals are assigned only to already-started rows (the live half) and are structurally 0 for the upcoming source, so they never explain this flag. */
884
+ /** Whether every configured upcoming-board scope completed as available. False with board_upcoming_configured=false means not applicable. When board_upcoming_configured is true and this flag is false, read board_upcoming_status for the cause (unknown means no cause was recorded, which no computed snapshot reports): the board_source_unavailable and board_deadline_unavailable terminals are assigned only to already-started rows (the live half) and are structurally 0 for the upcoming source, so they never explain this flag. */
881
885
  board_upcoming_available: boolean;
882
- /** Why the upcoming-board source is (un)available. Board supply is one canonical-sport union: the bare category owns live truth and every configured composed league scope contributes upcoming rows; folded leagues without a configured board (currently NCAAB and CFL) are not in the upcoming union. available: every configured scope completed truthfully (a successful empty schedule still counts). capacity_limited: provider pagination or a configured upcoming cache published an intentionally bounded complete-event prefix; those rows are excluded from diagnostic-universe input and must not be treated as a complete upcoming universe. Cache-bound prefixes are limited to an exact 5,000,000-byte final envelope. source_unavailable: composition failed before a truthful union; resolved scope readers turn half failures into cold_unavailable, so fresh producers are whole-union identity reconciliation or a registry contract failure and carry zero rows. cold_unavailable: every scope completed but at least one reported its upcoming half unavailable because no servable entry was inside the stale-serve bound and the background warm did not land in time; it is not by itself proof of a provider outage. deadline_unavailable: an internal configured-scope deadline or the outer bounded fair wave expired. An internal deadline may retain healthy bare-category or sibling-scope rows; the outer wave records zero rows. These upcoming fields do not describe league live-membership availability. If the bare-category live scope fails, all live rows are dropped even when a league scope completed, because the bare category is the sole live-truth owner. not_configured: no upcoming scope applies to the sport. unknown: exactly one cause -- a snapshot cached before this field existed whose legacy flags recorded an unavailable-but-configured half without saying why. Every freshly computed snapshot reports a concrete status, and a legacy available or not-configured row is reconstructed exactly, so unknown self-clears within one TTL. board_upcoming_available is exactly board_upcoming_status == available. */
886
+ /** Why the upcoming-board source is (un)available. Board supply is one canonical-sport union: the bare category owns live truth and every configured composed league scope contributes upcoming rows; folded leagues without a configured board (currently NCAAB and CFL) are not in the upcoming union. available: every configured scope completed truthfully (a successful empty schedule still counts). capacity_limited: provider pagination or a configured upcoming cache published an intentionally bounded complete-event prefix; those rows are excluded from diagnostic-universe input and must not be treated as a complete upcoming universe. Cache-bound prefixes are limited to an exact 5,000,000-byte final envelope. source_unavailable: composition failed before a truthful union; resolved scope readers turn half failures into cold_unavailable, so fresh producers are whole-union identity reconciliation or a registry contract failure and carry zero rows. cold_unavailable: every scope completed but at least one reported its upcoming half unavailable because no servable entry was inside the stale-serve bound and the background warm did not land in time; it is not by itself proof of a provider outage. deadline_unavailable: an internal configured-scope deadline or the outer bounded fair wave expired. An internal deadline may retain healthy bare-category or sibling-scope rows; the outer wave records zero rows. These upcoming fields do not describe league live-membership availability. If the bare-category live scope fails, all live rows are dropped even when a league scope completed, because the bare category is the sole live-truth owner. not_configured: no upcoming scope applies to the sport. unknown: no cause was recorded; every computed snapshot reports a concrete status, so none reads unknown. board_upcoming_available is exactly board_upcoming_status == available. */
883
887
  board_upcoming_status: "unknown" | "not_configured" | "available" | "capacity_limited" | "source_unavailable" | "cold_unavailable" | "deadline_unavailable";
884
888
  /** Configured upcoming scopes that did not complete as available. Values are category, a provider league tag slug (nfl, cfb, nba, wnba, euroleague-basketball, nhl, mls, valorant, league-of-legends, counter-strike-2, or dota-2), registry when the compiled scope/projection contract drifted, union when cross-scope identity reconciliation failed, or wave when the outer fair-wave deadline expired before scope-level evidence returned. Empty means no unavailable upcoming scope was identified; this includes healthy/not-configured rows and a legacy cached row. Observation league scopes are upcoming-only and perform no live-membership read. */
885
889
  board_upcoming_unavailable_scopes: ("category" | "nfl" | "cfb" | "nba" | "wnba" | "euroleague-basketball" | "nhl" | "mls" | "valorant" | "league-of-legends" | "counter-strike-2" | "dota-2" | "registry" | "union" | "wave")[];
886
890
  /** Stored-universe rows plus provider-board rows missing from storage. */
887
891
  input: number;
888
- /** Sparse counts over the closed 25-value terminal vocabulary: outside_horizon, resolved, provider_closed, provider_excluded, invalid_market, missing_token, missing_stored_market, not_provider_live, board_source_unavailable, board_deadline_unavailable, primary_slate_candidate, zero_indexed_holder_research, capacity_limited, provider_unavailable, holder_deadline_unavailable, holder_computation_unavailable, holder_scan_incomplete, no_current_graded_holder, split_holder_pile, price_unavailable, wider_holder_emitted, in_play_emitted, in_play_stale_observed, in_play_directional_unavailable, or internal_unclassified. primary_slate_candidate means exact admission by the funded route's raw shared signals query before provider/holder enrichment; recent-flow rows rejected by its event, bucket, or total caps remain eligible for wider_holder measurement. capacity_limited is intentional bounded provider-work admission, is fully accounted here, and does not itself set degraded=true. board_source_unavailable means a completed board source was unavailable; board_deadline_unavailable means live-board work missed either an internal configured-scope deadline or the outer fair-wave deadline; provider_unavailable means an attempted holder-provider read failed; holder_deadline_unavailable means holder cache/provider work missed the absolute request deadline; holder_computation_unavailable means post-holder provider or DB-backed price/metadata evaluation was unavailable. */
892
+ /** Sparse counts over the closed 25-value terminal vocabulary: outside_horizon, resolved, provider_closed, provider_excluded, invalid_market, missing_token, missing_stored_market, not_provider_live, board_source_unavailable, board_deadline_unavailable, primary_slate_candidate, zero_indexed_holder_research, capacity_limited, provider_unavailable, holder_deadline_unavailable, holder_computation_unavailable, holder_scan_incomplete, no_current_graded_holder, split_holder_pile, price_unavailable, wider_holder_emitted, in_play_emitted, in_play_stale_observed, in_play_directional_unavailable, or internal_unclassified. primary_slate_candidate means the view=signals snapshot named by signals_as_of lists the market at its widest selection (horizon_hours=48, min_grade=B, no selector), so it is not a wider_holder candidate; when no view=signals snapshot could be read (signals_as_of null), no market takes it. capacity_limited is intentional bounded provider-work admission, is fully accounted here, and does not itself set degraded=true. board_source_unavailable means a completed board source was unavailable; board_deadline_unavailable means live-board work missed either an internal configured-scope deadline or the outer fair-wave deadline; provider_unavailable means a holder read sent to the provider failed and the market had no reusable holder page; holder_deadline_unavailable means holder cache/provider work missed the absolute request deadline, or local capacity never sent the holder read, and the market had no reusable holder page; holder_computation_unavailable means post-holder provider or DB-backed price/metadata evaluation was unavailable. */
889
893
  terminals: Record<string, number>;
890
894
  /** Sum of every sparse terminal count. */
891
895
  terminal_total: number;
@@ -927,7 +931,6 @@ export type EventReplayMeta = {
927
931
  /** Unique request ID (req_ prefix). The same value as the X-Request-Id response header, the request's usage accounting row and its log lines. */
928
932
  request_id: string;
929
933
  cached: boolean;
930
- cache_age_s?: number;
931
934
  /** Advisory request weight (relative compute cost). 1 for simple reads; higher for heavier endpoints. Not a credit/price. */
932
935
  cost: number;
933
936
  replay: {
@@ -1005,8 +1008,12 @@ export type ExploreGroup = {
1005
1008
  markets: ExploreMarket[];
1006
1009
  /** The volume of the group's highest-volume market, which is markets[0]: the same figure as that market's volume, Polymarket's cumulative taker volume in shares rather than cash. Null when unavailable. */
1007
1010
  rep_volume: number | null;
1008
- /** Canonical key since #16304; rep_whales is its deprecated spelling, emitted beside it with the same value. */
1011
+ /** Canonical key since #16304; rep_whales is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1009
1012
  rep_large_trades: number | null;
1013
+ /**
1014
+ * Deprecated spelling of rep_large_trades, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read rep_large_trades.
1015
+ * @deprecated
1016
+ */
1010
1017
  rep_whales: number | null;
1011
1018
  };
1012
1019
  export type ExploreMarket = {
@@ -1028,17 +1035,33 @@ export type ExploreMarket = {
1028
1035
  /** Polymarket's traded-volume figure for the market, as last stored: cumulative taker volume in shares, each counted at its $1 settlement value, not the cash that changed hands (100 shares bought at $0.40 add 100, not 40). It can lag Polymarket's current figure. sort=volume orders by it. Null when unavailable. */
1029
1036
  volume: number | null;
1030
1037
  liquidity: number | null;
1031
- /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value. */
1038
+ /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1032
1039
  large_trade_count: number | null;
1040
+ /**
1041
+ * Deprecated spelling of large_trade_count, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_count.
1042
+ * @deprecated
1043
+ */
1033
1044
  whale_trade_count: number | null;
1034
- /** Canonical key since #16304; whale_distinct_wallets is its deprecated spelling, emitted beside it with the same value. */
1045
+ /** Canonical key since #16304; whale_distinct_wallets is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1035
1046
  large_trade_distinct_wallets: number | null;
1047
+ /**
1048
+ * Deprecated spelling of large_trade_distinct_wallets, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_distinct_wallets.
1049
+ * @deprecated
1050
+ */
1036
1051
  whale_distinct_wallets: number | null;
1037
- /** Canonical key since #16304; whale_total_usd is its deprecated spelling, emitted beside it with the same value. */
1052
+ /** Canonical key since #16304; whale_total_usd is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1038
1053
  large_trade_total_usd: number | null;
1054
+ /**
1055
+ * Deprecated spelling of large_trade_total_usd, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_total_usd.
1056
+ * @deprecated
1057
+ */
1039
1058
  whale_total_usd: number | null;
1040
- /** Canonical key since #16304; whale_last_trade_at is its deprecated spelling, emitted beside it with the same value. */
1059
+ /** Canonical key since #16304; whale_last_trade_at is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1041
1060
  large_trade_last_at: string | null;
1061
+ /**
1062
+ * Deprecated spelling of large_trade_last_at, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_last_at.
1063
+ * @deprecated
1064
+ */
1042
1065
  whale_last_trade_at: string | null;
1043
1066
  end_date: string | null;
1044
1067
  created_at: string | null;
@@ -1075,15 +1098,19 @@ export type ExploreMarket = {
1075
1098
  discover_score: number | null;
1076
1099
  score_components: {
1077
1100
  volume_signal: number | null;
1078
- /** Canonical key since #16304; whale_signal is its deprecated spelling, emitted beside it with the same value. */
1101
+ /** Canonical key since #16304; whale_signal is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1079
1102
  large_trade_signal: number | null;
1103
+ /**
1104
+ * Deprecated spelling of large_trade_signal, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_signal.
1105
+ * @deprecated
1106
+ */
1080
1107
  whale_signal: number | null;
1081
1108
  liquidity_signal: number | null;
1082
1109
  recency_signal: number | null;
1083
- /** Canonical key since #16308; smart_money_signal is its deprecated spelling, emitted beside it with the same value. */
1110
+ /** Canonical key since #16308; smart_money_signal is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1084
1111
  sharp_money_signal: number | null;
1085
1112
  /**
1086
- * Deprecated spelling of sharp_money_signal; emitted beside it with the same value and never removed.
1113
+ * Deprecated spelling of sharp_money_signal; emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read sharp_money_signal.
1087
1114
  * @deprecated
1088
1115
  */
1089
1116
  smart_money_signal: number | null;
@@ -1105,7 +1132,7 @@ export type ExportCompleteness = {
1105
1132
  sync_coverage: number;
1106
1133
  };
1107
1134
  export type ExportCounts = {
1108
- /** Daily P&L rows. The daily P&L covers every market of the wallet. */
1135
+ /** The days in the export file's pnl section, the wallet's sports and esports realized P&L by UTC day: the file's export_metadata.pnl_rows, at most its earliest 3650 days. 0 while source_range.pnl_series_status is pending, and 0 with it ready for a wallet that traded no sports or esports market. */
1109
1136
  pnl_days: number;
1110
1137
  /** The wallet's sports and esports markets: the rows of the export's markets section, before its 50,000-row cap. */
1111
1138
  exported_markets: number;
@@ -1149,23 +1176,30 @@ export type ExportJobReadyData = {
1149
1176
  data_as_of: string | null;
1150
1177
  };
1151
1178
  export type ExportSourceRange = {
1179
+ /** The first UTC day in the export file's pnl section, the wallet's sports and esports realized P&L by day: the file's export_metadata.pnl_date_from. Null when that section has no day, including while pnl_series_status is pending. */
1152
1180
  first_pnl_date: string | null;
1181
+ /** The last UTC day in the export file's pnl section: the file's export_metadata.pnl_date_to. Null when that section has no day. */
1153
1182
  last_pnl_date: string | null;
1183
+ /** Whether the export file's pnl section holds the wallet's sports and esports day series, the file's export_metadata.pnl_series_status. pending means 0xinsider has not computed the series yet: the dates are null and counts.pnl_days is 0, which then never means the wallet has no day. A wallet that traded no sports or esports market is ready with null dates and counts.pnl_days 0: it never gets a series, and with nothing stored completeness.status is empty (since 2026-10-29, #30620, #30657). */
1184
+ pnl_series_status: "ready" | "pending";
1154
1185
  /** The latest trade in the wallet's sports and esports markets. Null when it has none. */
1155
1186
  latest_trade_at: string | null;
1156
1187
  /** Same instant as latest_trade_at: the latest activity of the markets the export holds. */
1157
1188
  latest_market_activity_at: string | null;
1158
1189
  };
1159
1190
  export type ExportVolumeReconciliation = {
1160
- /** Verified full-history both-sides USD cash volume. Null without coverage; the local activity numerator may cover only a subset of history. */
1191
+ /**
1192
+ * Deprecated (#30499): always null since 2026-10-29. It held Polymarket's volume across every market of the wallet, which reconciles nothing against the sports and esports exported_activity_volume; the key stays so existing V1 clients keep parsing. Read exported_activity_volume for the wallet's sports and esports volume.
1193
+ * @deprecated
1194
+ */
1161
1195
  provider_lifetime_volume: number | null;
1162
- /** Cash in USD, buys and sells, summed over the daily P&L rows this export carries, from the fills 0xinsider has stored for the wallet. It can cover less history than provider_lifetime_volume; never Polymarket's share count. */
1163
- exported_activity_volume: number;
1196
+ /** Volume in USD, buys and sells, in sports and esports markets, each fill's size times its price with fees excluded, summed over the wallet's stored daily volume rows (from the fills 0xinsider stores for the wallet): the export file's summary.volume_reconciliation.exported_activity_volume, not the sum of its pnl[].total_volume, which is null on a day the trade rollups do not cover. Never Polymarket's share count. Null when any of those rows has no volume: a sum over the other days would be a partial subtotal. */
1197
+ exported_activity_volume: number | null;
1164
1198
  /** Cost basis in USD summed over the wallet's sports and esports markets, the markets section of the export. */
1165
1199
  exported_market_cost_basis: number;
1166
- /** provider_lifetime_volume minus exported_activity_volume, in USD, rounded to cents. Null when provider_lifetime_volume is null. */
1200
+ /** Always null. provider_lifetime_volume covered every market and exported_activity_volume sports and esports markets only, so their difference measured nothing; the field stays so existing clients keep parsing the object. */
1167
1201
  provider_activity_volume_gap: number | null;
1168
- /** exported_activity_volume divided by provider_lifetime_volume, a fraction of the cash, not a percent. Null when provider_lifetime_volume is null or zero. */
1202
+ /** Always null, for the same reason as provider_activity_volume_gap. */
1169
1203
  activity_volume_coverage: number | null;
1170
1204
  };
1171
1205
  export type FreshnessFailure = {
@@ -1339,7 +1373,7 @@ export type GamesCoverage = {
1339
1373
  };
1340
1374
  /** Where the game is in its own life, as the provider reports it. A postponement, a cancellation and a suspension each keep their own state, so a client can tell a game that will be played later from one that never will be. */
1341
1375
  export type GameStatus = {
1342
- /** scheduled: kickoff is ahead or the provider still calls it scheduled. live: the provider reports it in play. paused: halftime or a provider-reported break. ended: the provider reported a final, an award or a forfeit. postponed, cancelled, suspended, delayed: the provider's own verdict, kept distinct. unknown: no provider state reached this read. A kickoff in the past is never read as live on its own. */
1376
+ /** scheduled: kickoff is ahead or the provider still calls it scheduled. live: the provider reports it in play. paused: halftime or a provider-reported break. ended: the provider reported a final, an award or a forfeit. postponed, cancelled, suspended, delayed: the provider's own verdict, kept distinct. A tennis match that the provider still lists in play, with no live score feed and no change of period or score for 3 hours, also reads suspended. unknown: no provider state reached this read. A kickoff in the past is never read as live on its own. */
1343
1377
  state: "scheduled" | "live" | "paused" | "ended" | "postponed" | "cancelled" | "suspended" | "delayed" | "unknown";
1344
1378
  /** The provider status folded onto one vocabulary across leagues. unknown means the provider sent a value this API has no meaning for; provider_status keeps that value verbatim. Omitted when no live-score frame carries a status. */
1345
1379
  match_status?: "scheduled" | "in_progress" | "halftime" | "penalty_shootout" | "delayed" | "suspended" | "final" | "final_overtime" | "final_shootout" | "awarded" | "forfeit" | "not_necessary" | "postponed" | "cancelled" | "unknown";
@@ -1349,7 +1383,7 @@ export type GameStatus = {
1349
1383
  period?: string;
1350
1384
  /** The game clock as the provider spells it, never reformatted. Omitted when the provider sent none. */
1351
1385
  clock?: string;
1352
- /** Whether the game is in play. It is the provider's own in-play flag, except that a game the provider reports suspended (period SUS) or rescheduled to a later kickoff reads false. Omitted when no live-score frame exists, which is not the same as false. */
1386
+ /** Whether the game is in play. It is the provider's own in-play flag, except that three cases read false: a game the provider reports suspended (period SUS), a game rescheduled to a later kickoff, and a tennis match that the provider still lists in play with no live score feed and no change of period or score for 3 hours. Omitted when no live-score frame exists, which is not the same as false. */
1353
1387
  live?: boolean;
1354
1388
  /** Whether the game is over. Always present. */
1355
1389
  ended: boolean;
@@ -1380,9 +1414,20 @@ export type LargeExportPolicy = {
1380
1414
  /** How long a finished export is retained before expiry. */
1381
1415
  retention: string;
1382
1416
  };
1383
- direct_streaming: Record<string, unknown>;
1384
- async_job: Record<string, unknown>;
1385
- rate_limit: Record<string, unknown>;
1417
+ direct_streaming: {
1418
+ available_when: string;
1419
+ backpressure: string;
1420
+ chunk_size_rows: number;
1421
+ };
1422
+ async_job: {
1423
+ available_when: string;
1424
+ status_values: string[];
1425
+ retention: string;
1426
+ };
1427
+ rate_limit: {
1428
+ daily_cap_per_user: number;
1429
+ per_address_hourly_cap: number;
1430
+ };
1386
1431
  };
1387
1432
  export type LargePosition = {
1388
1433
  /** Composite prefixed ID `pos_<wallet>:<condition_id>:<outcome_index>`. */
@@ -1440,9 +1485,16 @@ export type LargePosition = {
1440
1485
  address: string;
1441
1486
  username?: string;
1442
1487
  grade?: "S" | "A" | "B" | "C" | "D" | "F";
1488
+ /** Sports and esports win rate as a ratio from 0 to 1 (0.62 means 62%): wins over the decided sports and esports markets on the wallet's record, the same figure as pnl.in_scope.win_rate on GET /api/v1/trader/{address}. Since 2026-10-27 it no longer counts other markets (#29953). Absent when the wallet has no record or no decided market. */
1443
1489
  win_rate?: number;
1444
- /** Polymarket's net total P&L for the wallet in USD: native Polymarket position P&L across all markets, fees included, plus credited maker and taker rebates. The 0xinsider profile's Total P&L is this figure unless the wallet has a published correction for neg-risk conversions, which GET /api/v1/trader/{address} serves as pnl.correction; the profile then shows pnl.correction.net_total. Distinct from this position's position_unrealized_pnl. Omitted when the wallet has no native accounting snapshot. */
1490
+ /**
1491
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's net total P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29953). Read trader.in_scope_realized_pnl.
1492
+ * @deprecated
1493
+ */
1445
1494
  pnl?: number;
1495
+ /** The wallet's realized P&L in USD on sports and esports markets, the figure the 0xinsider profile shows: the record behind pnl.in_scope.realized_pnl on GET /api/v1/trader/{address}, to cents. Distinct from this position's position_unrealized_pnl. For a graded wallet it is read from the latest grading pass, so it can trail that figure until the next pass. Omitted until 0xinsider has computed the wallet's record (#29953). */
1496
+ in_scope_realized_pnl?: number;
1497
+ /** Sports and esports markets on the wallet's record, pnl.in_scope.markets on GET /api/v1/trader/{address}. Since 2026-10-27 it no longer counts other markets (#29953). Absent when the wallet has no record. */
1446
1498
  markets_traded?: number;
1447
1499
  };
1448
1500
  market: {
@@ -1474,14 +1526,14 @@ export type LargeTrade = {
1474
1526
  /** Current trade review score on a 0..1 scale; higher values indicate a stronger review signal. This is the current response value and can differ from the recorded score. Missing measurements remain unavailable. */
1475
1527
  review_score: number;
1476
1528
  /**
1477
- * Deprecated alias of review_score with the same current value and 0..1 scale.
1529
+ * Deprecated alias of review_score with the same current value and 0..1 scale. Sunset 2027-02-01 (#29352): removed from V1 on that date; read review_score.
1478
1530
  * @deprecated
1479
1531
  */
1480
1532
  signal_score: number;
1481
1533
  /** 0.0–1.0 review score written once when the trade row is inserted, from the trader's statistics at that moment. Populated from 2026-08-03T11:59Z; older rows return null and are never backfilled, because a backfill could only read today's statistics. If a trade is added later, its time-sensitive recorded score reflects that delay. Canonical since #16311; recorded_signal_score carries the same value. */
1482
1534
  recorded_review_score: number | null;
1483
1535
  /**
1484
- * 0.0–1.0 review score written once when the trade row is inserted; null before 2026-08-03T11:59Z. Deprecated (#16311): `recorded_review_score` is the canonical spelling and carries the same value; this key stays on the wire.
1536
+ * 0.0–1.0 review score written once when the trade row is inserted; null before 2026-08-03T11:59Z. Deprecated (#16311): `recorded_review_score` is the canonical spelling and carries the same value; this key stays on the wire until its sunset on 2027-02-01 (#29352), when it is removed.
1485
1537
  * @deprecated
1486
1538
  */
1487
1539
  recorded_signal_score: number | null;
@@ -1496,7 +1548,7 @@ export type LargeTrade = {
1496
1548
  address: string;
1497
1549
  username?: string;
1498
1550
  /** The trader's grade today, on every row however old. For what the grade was when the trade happened, read grade_at_trade. */
1499
- grade?: string;
1551
+ grade?: "S" | "A" | "B" | "C" | "D" | "F";
1500
1552
  /** The grade the trader held when the trade happened, from recorded grade history (recorded from 2026-09-19T23:00Z). Null unless grade_at_trade_status is graded. Never today's grade projected backward. */
1501
1553
  grade_at_trade: "S" | "A" | "B" | "C" | "D" | "F" | null;
1502
1554
  /** graded: grade_at_trade holds the recorded grade. ungraded: the trader was recorded without a grade at that moment. unknown: no record covers the moment, which is every trade before 2026-09-19T23:00Z and a trade that fell between a grade change and its confirmation. unknown never means ungraded. */
@@ -1558,7 +1610,7 @@ export type LargeTradeInsertedV2Data = {
1558
1610
  traded_at: string;
1559
1611
  platform: "polymarket";
1560
1612
  };
1561
- /** `large_trades_inserted` data (Pro and Max): new large trades were ingested. It carries a count and no trade; subscribe to `large_trade_inserted_v2` for the trade itself. The deprecated spelling `whale_trades_inserted` delivers the same object. */
1613
+ /** `large_trades_inserted` data (Pro and Max): new large trades were ingested. It carries a count and no trade; subscribe to `large_trade_inserted_v2` for the trade itself. The deprecated spelling `whale_trades_inserted` delivers the same object until its sunset on 2027-02-01 (#29352). */
1562
1614
  export type LargeTradesInsertedData = {
1563
1615
  /** Large trades the producing batch admitted. */
1564
1616
  count: number;
@@ -1578,21 +1630,36 @@ export type LeaderboardEntry = {
1578
1630
  id: string;
1579
1631
  address: string;
1580
1632
  username?: string;
1581
- grade?: string;
1633
+ grade?: "S" | "A" | "B" | "C" | "D" | "F";
1582
1634
  /** Hot-streak tier (trailing-7d cross-sectional percentile); a separate axis from the all-time grade. Omitted when there is no recent activity. */
1583
1635
  streak_tier?: "hot" | "rising" | "neutral" | "cooling" | "cold";
1584
1636
  score?: number;
1585
- /** Polymarket's all-time leaderboard P&L in USD, from Polymarket's latest observation of this wallet on its all-time leaderboard (dated by the leaderboard_pnl data_quality group). Omitted when that leaderboard has no current observation ranking the wallet; 0xinsider requests one, and never serves an older stored figure in its place. Includes unrealized open positions. Kept for back-compat. Not the profile's Total P&L, which GET /api/v1/trader/{address} serves as pnl.net_total; the two can differ by a wide margin. Prefer realized_pnl for the banked figure. */
1637
+ /**
1638
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's all-time leaderboard P&L, which covered every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29971). Read in_scope.realized_pnl.
1639
+ * @deprecated
1640
+ */
1586
1641
  pnl?: number;
1587
- /** Native realized P&L plus credited maker and taker rebates in USD, with fees already included. The exact numeric value is truncated toward zero to cents before JSON conversion. Omitted when the wallet has no native snapshot or the snapshot has no net realized value; never filled from another P&L basis. */
1642
+ /**
1643
+ * Deprecated since 2026-10-27 and never sent. It was native Polymarket realized P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29971). Read in_scope.realized_pnl.
1644
+ * @deprecated
1645
+ */
1588
1646
  realized_pnl?: number;
1589
- /** The 0xinsider correction to Polymarket's P&L for neg-risk conversions. Present only when one is published; realized_pnl keeps Polymarket's own figure and pnl_correction.realized adds the amount to it. The grade and the ranking use the corrected figure. net_total is omitted here. */
1647
+ /**
1648
+ * Deprecated since 2026-10-27 and never sent. It was the neg-risk conversion correction to the wallet-wide realized_pnl (#29971). Its sports and esports part is inside in_scope.realized_pnl.
1649
+ * @deprecated
1650
+ */
1590
1651
  pnl_correction?: PnlCorrection;
1591
- /** Full-history both-sides USD cash volume from a verified Polymarket user-volume observation. Omitted without coverage. */
1652
+ /**
1653
+ * Deprecated since 2026-10-27 and never sent. It was full-history USD cash volume over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29971).
1654
+ * @deprecated
1655
+ */
1592
1656
  volume?: number;
1657
+ /** Sports and esports markets on the wallet's record, the same count as in_scope.markets. Since 2026-10-27 (#29971); before, it counted every Polymarket market. Sent exactly when in_scope is. */
1593
1658
  markets_traded?: number;
1594
- /** The wallet's win rate across ALL categories, not the filtered one. ?category= decides WHICH wallets are listed (the wallet must be ranked in that category); it does not rescope this field, so a soccer-filtered list still reports each wallet's overall rate. For a per-category record use GET /api/v1/trader/{address}/categories. */
1659
+ /** The wallet's sports and esports win rate, in_scope.win_rate rounded to four places. Since 2026-10-27 (#29971); before, it covered every Polymarket market. ?category= decides WHICH wallets are listed (the wallet must be ranked in that category); it does not rescope this field. For a per-category record use GET /api/v1/trader/{address}/categories. Omitted when in_scope is omitted or has no win rate. */
1595
1660
  win_rate?: number;
1661
+ /** Additive (#27859): the wallet's sports and esports record, the same object as GET /api/v1/trader/{address} pnl.in_scope, as of the leaderboard's last refresh. The 0xinsider leaderboard page shows and sorts by in_scope.realized_pnl and in_scope.win_rate. Omitted until 0xinsider has computed the wallet's record; absent means not computed yet, never zero. */
1662
+ in_scope?: TraderPnlInScope;
1596
1663
  /** Observed trading style identifier. New rows use two_sided, category_focused, high_activity, diversified, mixed, or unclassified, counted over the wallet's sports and esports markets only. Historical identifiers remain readable during normal reclassification; style does not predict skill or intent. */
1597
1664
  strategy_type?: string;
1598
1665
  /** Provider platform. Always polymarket. */
@@ -1666,8 +1733,12 @@ export type MarketFlow = {
1666
1733
  direction: "YES" | "NO";
1667
1734
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for the net-flow direction outcome; null when unavailable (e.g. unsynced markets). */
1668
1735
  token_id: string | null;
1669
- /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value. */
1736
+ /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1670
1737
  large_trade_count: number;
1738
+ /**
1739
+ * Deprecated spelling of large_trade_count, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_count.
1740
+ * @deprecated
1741
+ */
1671
1742
  whale_trade_count: number;
1672
1743
  buy_volume_usd: number;
1673
1744
  sell_volume_usd: number;
@@ -1675,7 +1746,7 @@ export type MarketFlow = {
1675
1746
  id: string;
1676
1747
  address: string;
1677
1748
  username: string | null;
1678
- grade: string | null;
1749
+ grade: "S" | "A" | "B" | "C" | "D" | "F" | null;
1679
1750
  side: "YES" | "NO";
1680
1751
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for this outcome; null when unavailable (e.g. unsynced markets). */
1681
1752
  token_id: string | null;
@@ -1685,7 +1756,7 @@ export type MarketFlow = {
1685
1756
  oldest_snapshot_as_of: string | null;
1686
1757
  };
1687
1758
  /**
1688
- * Deprecated alias of sharp_money; byte-identical and retained for backward compatibility.
1759
+ * Deprecated alias of sharp_money; byte-identical. Sunset 2027-02-01 (#29352): removed from V1 on that date; read sharp_money.
1689
1760
  * @deprecated
1690
1761
  */
1691
1762
  smart_money: {
@@ -1693,8 +1764,12 @@ export type MarketFlow = {
1693
1764
  direction: "YES" | "NO";
1694
1765
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for the net-flow direction outcome; null when unavailable (e.g. unsynced markets). */
1695
1766
  token_id: string | null;
1696
- /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value. */
1767
+ /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
1697
1768
  large_trade_count: number;
1769
+ /**
1770
+ * Deprecated spelling of large_trade_count, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_count.
1771
+ * @deprecated
1772
+ */
1698
1773
  whale_trade_count: number;
1699
1774
  buy_volume_usd: number;
1700
1775
  sell_volume_usd: number;
@@ -1702,7 +1777,7 @@ export type MarketFlow = {
1702
1777
  id: string;
1703
1778
  address: string;
1704
1779
  username: string | null;
1705
- grade: string | null;
1780
+ grade: "S" | "A" | "B" | "C" | "D" | "F" | null;
1706
1781
  side: "YES" | "NO";
1707
1782
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for this outcome; null when unavailable (e.g. unsynced markets). */
1708
1783
  token_id: string | null;
@@ -1736,23 +1811,23 @@ export type MarketHolder = {
1736
1811
  other_outcome_shares?: number;
1737
1812
  /** The wallet's last recorded trade anywhere, null when unknown. */
1738
1813
  last_traded_at: string | null;
1739
- /** This wallet's win rate in the market's canonical category (`market.category`): the share of its resolved markets in that category whose realized P&L closed positive, as a 0..1 fraction. Present only with `category_win_rate_status` = `measured`. The same read `GET /api/v1/trader/{address}/categories` serves per wallet. */
1814
+ /** This wallet's win rate in the market's canonical category (`market.category`): the share of its settled markets in that category (it closed its position by selling out, or the market resolved) whose realized P&L closed positive, as a 0..1 fraction. Present only with `category_win_rate_status` = `measured`. The same read `GET /api/v1/trader/{address}/categories` serves per wallet. */
1740
1815
  category_win_rate?: number;
1741
- /** The two counts `category_win_rate` is the ratio of, from the same row: `wins / decided` equals the rate. Every resolved Polymarket market the wallet traded in the market's canonical category, at any position size, rebuilt daily. Present only with `category_win_rate_status` = `measured`. */
1816
+ /** The two counts `category_win_rate` is the ratio of, from the same row: `wins / decided` equals the rate. Every settled Polymarket market the wallet traded (it closed its position by selling out, or the market resolved) in the market's canonical category, at any position size, rebuilt daily. Present only with `category_win_rate_status` = `measured`. */
1742
1817
  category_win_record?: {
1743
- /** Resolved markets in the category that this wallet closed with a profit. */
1818
+ /** Settled markets in the category that this wallet closed with a profit. */
1744
1819
  wins: number;
1745
- /** Resolved markets in the category that this wallet closed with a profit or a loss. A market resolved at zero realized P&L is in neither count. */
1820
+ /** Settled markets in the category that this wallet closed with a profit or a loss. A market resolved at zero realized P&L is in neither count. */
1746
1821
  decided: number;
1747
1822
  };
1748
- /** The wallet's average entry price in the market's canonical category, as a 0..1 fraction of $1 (0.98 is 98 cents). Its sample is the wallet's settled markets in that category of $20 or more where it bought one side at a known price, so it can differ from the `category_win_record` sample. A wallet that buys near-certain outcomes wins almost every time, so read the win rate beside this price. Present only with `category_win_rate_status` = `measured`, and only when that sample has at least 5 markets. When `category_win_rate_game` is present the price is still the `Esports` category's: there is no per-game price. Absent otherwise and on payloads predating the field. */
1823
+ /** The wallet's average entry price in the market's canonical category, as a 0..1 fraction of $1 (0.98 is 98 cents). Its sample is the wallet's markets in that category that resolved to a winning side, of $20 or more where it bought one side at a known price, so it can differ from the `category_win_record` sample. A wallet that buys near-certain outcomes wins almost every time, so read the win rate beside this price. Present only with `category_win_rate_status` = `measured`, and only when that sample has at least 5 markets. When `category_win_rate_game` is present the price is still the whole `category` bucket's: this field has no per-game or per-league price. Absent otherwise and on payloads predating the field. */
1749
1824
  category_avg_price?: number;
1750
- /** For an esports market, the game `category_win_rate` and `category_win_record` were measured in: `LoL`, `CS2`, `Dota 2`, `Valorant`, `Call of Duty`, `Honor of Kings`, `Mobile Legends: Bang Bang`, `Overwatch`, `Rainbow Six Siege`, `Rocket League` or `StarCraft II`. Present only when the wallet's record in that game clears the 5-resolved-market floor, in which case the rate and record are the game's rather than the `Esports` bucket's. Absent when the rate is the bucket's (the wallet's game history is under the floor), on every non-esports market, and beside every non-measured status. Label the rate with this when present and with the market's `category` otherwise. */
1825
+ /** Where `category_win_rate` and `category_win_record` were measured: for an esports market the game (`LoL`, `CS2`, `Dota 2`, `Valorant`, `Call of Duty`, `Honor of Kings`, `Mobile Legends: Bang Bang`, `Overwatch`, `Rainbow Six Siege`, `Rocket League` or `StarCraft II`), and for a market in a registered league that league, by the name Pick of the Day uses for it (`NBA`, `NFL`, `NHL`, `MLB`, `UFC`, `ATP`, `WTA`, `LaLiga`, `Premier League`, `Serie A`, `UEFA Champions League`, `MLS` and the other registered leagues). Present only when the wallet's record there clears the 5-settled-market floor, in which case the rate and record are the game's or league's rather than the whole `category` bucket's. Absent when the rate is the bucket's (the wallet's history there is under the floor, or the competition is not a registered league), on every other market, and beside every non-measured status. Label the rate with this when present and with the market's `category` otherwise. */
1751
1826
  category_win_rate_game?: string;
1752
1827
  /** Why `category_win_rate` is present or absent: `measured` (rate present), `not_enough_data` (under the floor of 5 decided markets in the category), or `unavailable` (the market has no canonical category, or the read failed; retry later). Always present on this route. */
1753
1828
  category_win_rate_status: "measured" | "not_enough_data" | "unavailable";
1754
1829
  category_evidence?: HolderCategoryEvidence;
1755
- /** Days since this wallet's first trade. The five badge fields are present together, only for a wallet that draws at least one badge. */
1830
+ /** Whole days since this wallet's first trade, rounded down (3.6 days reads 3), so it changes once a day, not on every request. The five badge fields are present together, only for a wallet that draws at least one badge. */
1756
1831
  wallet_age_days?: number | null;
1757
1832
  /** True when the wallet's first trade was under 30 days ago. */
1758
1833
  is_new_wallet?: boolean;
@@ -1838,12 +1913,12 @@ export type MarketSnapshot = {
1838
1913
  /** Polymarket series slug from the canonical identity row, null when unavailable. A sports series identifies a league and must not be used as a per-matchup grouping key. */
1839
1914
  series_slug: string | null;
1840
1915
  /**
1841
- * Always null. Deprecated (#24169): 0xinsider has never stored a value for this field. The key stays on the wire so existing clients keep parsing; do not read it.
1916
+ * Always null. Deprecated (#24169): 0xinsider has never stored a value for this field. The key stays on the wire until its sunset on 2027-02-01 (#29352), when it is removed; do not read it.
1842
1917
  * @deprecated
1843
1918
  */
1844
1919
  market_type: string | null;
1845
1920
  /**
1846
- * Always null. Deprecated (#24169): 0xinsider stores no value for this field on a Polymarket market. The key stays on the wire so existing clients keep parsing; do not read it. market.status and market.resolved_at say whether the market has closed or resolved.
1921
+ * Always null. Deprecated (#24169): 0xinsider stores no value for this field on a Polymarket market. The key stays on the wire until its sunset on 2027-02-01 (#29352), when it is removed; do not read it. market.status and market.resolved_at say whether the market has closed or resolved.
1847
1922
  * @deprecated
1848
1923
  */
1849
1924
  market_result: string | null;
@@ -1916,7 +1991,8 @@ export type MarketSnapshotTrust = {
1916
1991
  };
1917
1992
  export type McpJsonRpcError = {
1918
1993
  jsonrpc: "2.0";
1919
- id: string | number | null;
1994
+ /** The request's id, or null when the request could not be parsed. Omitted on the answer to an unsolicited response message. */
1995
+ id?: string | number | null;
1920
1996
  error: {
1921
1997
  code: number;
1922
1998
  message: string;
@@ -1945,22 +2021,22 @@ export type PickHolder = {
1945
2021
  shares: number;
1946
2022
  /** USD entry value of this wallet's position: `shares` times the pick's frozen `backed_price`. An entry valuation, never a live balance or the provider's current value. Omitted when the holder snapshot has no valid price. */
1947
2023
  entry_value_usd?: number;
1948
- /** This wallet's win rate in the pick's canonical category bucket (the pick's `category` field, e.g. Basketball -- label the rate with it, never with the narrower `display_category` league, except when `category_win_rate_game` is present, in which case the rate is that game's and is labelled with it): the share of the wallet's resolved markets in that category whose realized P&L closed positive, as a 0..1 fraction. Present only with `category_win_rate_status` = `measured`, on `display_holders` entries, and only when the wallet clears the resolved-market floor; recomputed at serve time from the current category read model, not frozen with the pick. Absent on `holders` entries, legacy rows, and payloads predating the field. */
2024
+ /** This wallet's win rate in the pick's canonical category bucket (the pick's `category` field, e.g. Basketball -- label the rate with it, never with the narrower `display_category` league, except when `category_win_rate_game` is present, in which case the rate is that game's or league's and is labelled with it): the share of the wallet's settled markets in that category (it closed its position by selling out, or the market resolved) whose realized P&L closed positive, as a 0..1 fraction. Present only with `category_win_rate_status` = `measured`, on `display_holders` entries, and only when the wallet clears the settled-market floor; recomputed at serve time from the current category read model, not frozen with the pick. Absent on `holders` entries, legacy rows, and payloads predating the field. */
1949
2025
  category_win_rate?: number;
1950
- /** The two counts `category_win_rate` is the ratio of, read from the same row: `wins / decided` equals the rate. Counts every resolved Polymarket market the wallet traded in the pick's canonical category (or in its game, when `category_win_rate_game` is present), at any position size; the counts are rebuilt daily. Present only with `category_win_rate_status` = `measured`; absent otherwise and on payloads predating the field. */
2026
+ /** The two counts `category_win_rate` is the ratio of, read from the same row: `wins / decided` equals the rate. Counts every settled Polymarket market the wallet traded (it closed its position by selling out, or the market resolved) in the pick's canonical category (or in its game or league, when `category_win_rate_game` is present), at any position size; the counts are rebuilt daily. Present only with `category_win_rate_status` = `measured`; absent otherwise and on payloads predating the field. */
1951
2027
  category_win_record?: {
1952
- /** Resolved markets in the category that this wallet closed with a profit. */
2028
+ /** Settled markets in the category that this wallet closed with a profit. */
1953
2029
  wins: number;
1954
- /** Resolved markets in the category that this wallet closed with a profit or a loss. A market resolved at zero realized P&L is in neither count. */
2030
+ /** Settled markets in the category that this wallet closed with a profit or a loss. A market resolved at zero realized P&L is in neither count. */
1955
2031
  decided: number;
1956
2032
  };
1957
- /** The wallet's average entry price in the pick's canonical category, as a 0..1 fraction of $1 (0.98 is 98 cents). Its sample is the wallet's settled markets in that category of $20 or more where it bought one side at a known price, so it can differ from the `category_win_record` sample. A wallet that buys near-certain outcomes wins almost every time, so read the win rate beside this price. Present only with `category_win_rate_status` = `measured`, and only when that sample has at least 5 markets. When `category_win_rate_game` is present the price is still the `Esports` category's: there is no per-game price. Absent otherwise and on payloads predating the field. */
2033
+ /** The wallet's average entry price in the pick's canonical category, as a 0..1 fraction of $1 (0.98 is 98 cents). Its sample is the wallet's markets in that category that resolved to a winning side, of $20 or more where it bought one side at a known price, so it can differ from the `category_win_record` sample. A wallet that buys near-certain outcomes wins almost every time, so read the win rate beside this price. Present only with `category_win_rate_status` = `measured`, and only when that sample has at least 5 markets. When `category_win_rate_game` is present the price is still the whole `category` bucket's: this field has no per-game or per-league price. Absent otherwise and on payloads predating the field. */
1958
2034
  category_avg_price?: number;
1959
- /** For an esports pick, the game `category_win_rate` and `category_win_record` were measured in, by the same name the pick's `display_category` uses for it: `LoL`, `CS2`, `Dota 2`, `Valorant`, `Call of Duty`, `Honor of Kings`, `Mobile Legends: Bang Bang`, `Overwatch`, `Rainbow Six Siege`, `Rocket League` or `StarCraft II`. Present only when the wallet's record in that game clears the 5-resolved-market floor, in which case the rate and record are the game's rather than the `Esports` bucket's. Absent when the rate is the bucket's (the wallet's game history is under the floor), on every non-esports pick, beside every non-measured status, and on payloads predating the field. Label the rate with this when present and with `category` otherwise. */
2035
+ /** Where `category_win_rate` and `category_win_record` were measured, by the same name the pick's `display_category` uses for it: for an esports pick the game (`LoL`, `CS2`, `Dota 2`, `Valorant`, `Call of Duty`, `Honor of Kings`, `Mobile Legends: Bang Bang`, `Overwatch`, `Rainbow Six Siege`, `Rocket League` or `StarCraft II`), and for a pick in a registered league that league (`NBA`, `NFL`, `NHL`, `MLB`, `UFC`, `ATP`, `WTA`, `LaLiga`, `Premier League`, `Serie A`, `UEFA Champions League`, `MLS` and the other registered leagues). Present only when the wallet's record there clears the 5-settled-market floor, in which case the rate and record are the game's or league's rather than the whole `category` bucket's. Absent when the rate is the bucket's (the wallet's history there is under the floor, or the competition is not a registered league), on every other pick, beside every non-measured status, and on payloads predating the field. Label the rate with this when present and with `category` otherwise. */
1960
2036
  category_win_rate_game?: string;
1961
- /** Why `category_win_rate` is present or absent on a `display_holders` entry: `measured` (rate present), `not_enough_data` (the wallet is below the resolved-market floor of 5 in the category), or `unavailable` (the annotation read failed; retry later). Absent entirely on `holders` entries, legacy rows, and payloads predating the field -- absence means the roster was never annotated, not a small sample. */
2037
+ /** Why `category_win_rate` is present or absent on a `display_holders` entry: `measured` (rate present), `not_enough_data` (the wallet is below the settled-market floor of 5 in the category), or `unavailable` (the annotation read failed; retry later). Absent entirely on `holders` entries, legacy rows, and payloads predating the field -- absence means the roster was never annotated, not a small sample. */
1962
2038
  category_win_rate_status?: "measured" | "not_enough_data" | "unavailable";
1963
- /** Days since this wallet's first trade. Stamped at serve time from the wallet's current trader record, never frozen with the pick. The five badge fields are present together, and only for a wallet that carries at least one badge; all absent means no badge, or a body cached before the fields shipped. */
2039
+ /** Whole days since this wallet's first trade, rounded down (3.6 days reads 3), so it changes once a day, not on every request, and the pick's ETag holds between requests. Stamped at serve time from the wallet's current trader record, never frozen with the pick. The five badge fields are present together, and only for a wallet that carries at least one badge; all absent means no badge, or a body cached before the fields shipped. */
1964
2040
  wallet_age_days?: number | null;
1965
2041
  /** True when the wallet's first trade was under 30 days ago. Stamped at serve time from the wallet's current trader record, never frozen with the pick. The five badge fields are present together, and only for a wallet that carries at least one badge; all absent means no badge, or a body cached before the fields shipped. */
1966
2042
  is_new_wallet?: boolean;
@@ -2106,9 +2182,9 @@ export type PickOfTheDay = {
2106
2182
  grade: string | null;
2107
2183
  /** The canonical sport bucket the win rate was measured over (for example Basketball). Can be BROADER than the pick's display_category, which names an exact league such as NBA — label the rate with this field, never with display_category. */
2108
2184
  canonical_category: string;
2109
- /** Share of the trader’s resolved markets in canonical_category with positive realized P&L, as a 0..1 fraction. Null when not measured. This is a trader statistic, not the pick’s probability of winning. */
2185
+ /** Share of the trader’s settled markets in canonical_category (closed by selling out, or resolved) with positive realized P&L, as a 0..1 fraction. Null when not measured. This is a trader statistic, not the pick’s probability of winning. */
2110
2186
  win_rate: number | null;
2111
- /** Number of resolved markets behind win_rate; null when not measured. */
2187
+ /** Number of settled markets behind win_rate; null when not measured. */
2112
2188
  n_resolved: number | null;
2113
2189
  /** Recorded Polymarket position value on the backed outcome, in USD. It can change after this snapshot. */
2114
2190
  position_usd: number;
@@ -2429,7 +2505,7 @@ export type PickOfTheDayLedgerOpenedEntry = {
2429
2505
  matchup: string;
2430
2506
  /** Frozen canonical sport bucket (for example Basketball or MMA), not the exact public league identity; the archive owns that. */
2431
2507
  category: string;
2432
- /** The pick's public page. */
2508
+ /** The pick's stable public page, `https://0xinsider.com/pick-of-the-day/picks/{pick_id}`. */
2433
2509
  permalink: string;
2434
2510
  /** Stable pick row identity as decimal text. Never use a quality rank as identity. */
2435
2511
  pick_id: string;
@@ -2461,7 +2537,7 @@ export type PickOfTheDayLedgerSealedEntry = {
2461
2537
  commitment_algo: "sha256(canonical_json(payload)||nonce)";
2462
2538
  /** When the hash was frozen. Always strictly before kickoff: a pick that reaches kickoff unsealed stays unsealed forever, because a seal written after the game started would be a backdated proof. */
2463
2539
  sealed_at: string;
2464
- /** The pick's public page. */
2540
+ /** The pick's stable public page, `https://0xinsider.com/pick-of-the-day/picks/{pick_id}`. */
2465
2541
  permalink: string;
2466
2542
  /** Stable pick row identity as decimal text. Never use a quality rank as identity. */
2467
2543
  pick_id: string;
@@ -2501,7 +2577,7 @@ export type PickOfTheDayLedgerUncommittedEntry = {
2501
2577
  resolved_at: string | null;
2502
2578
  /** The pick's market, side and price once it has settled; null while it is pending, and null for a settled pick whose stored row lacks one of these columns. Not hashed: nothing was committed over these values, which is what pre_commitment: true says. */
2503
2579
  payload: PickOfTheDayUncommittedPayload | null;
2504
- /** The pick's public page. */
2580
+ /** The pick's stable public page, `https://0xinsider.com/pick-of-the-day/picks/{pick_id}`. */
2505
2581
  permalink: string;
2506
2582
  /** Stable pick row identity as decimal text. Never use a quality rank as identity. */
2507
2583
  pick_id: string;
@@ -2534,13 +2610,11 @@ export type PickOfTheDayNoEntitledPicks = {
2534
2610
  message: string;
2535
2611
  /** Rank-ordered entitled selections that have not released. Every row retains release_at and kickoff; unauthorized scheduled ranks appear only in identity-free locked_picks. */
2536
2612
  scheduled_picks?: ScheduledPickSlot[];
2537
- /** Entitled published picks whose holder proof is unreadable, ordered by rank. Unauthorized ranks appear only in locked_picks and cannot trigger proof warming. Read retry_at for the next read. */
2538
- proof_pending_picks?: ProofPendingPickSlot[];
2539
2613
  /**
2540
- * Deprecated (#24157): always null, as on every Pick of the Day shape.
2614
+ * Deprecated (#24157): always null. No replacement lineage was ever recorded in this field; the key stays so existing V1 clients keep parsing. Identify a pick by pick_id.
2541
2615
  * @deprecated
2542
2616
  */
2543
- supersedes_pick_id: null;
2617
+ supersedes_pick_id: string | null;
2544
2618
  };
2545
2619
  /** A settled uncommitted pick's market, side and price. The same eight fields as PickOfTheDayCommitmentPayload, in the same key order, so a settled pick's side and price sit under payload whatever the entry's state. It is NOT a commitment: no hash was taken over it before the game, and it proves nothing about when the pick was made. */
2546
2620
  export type PickOfTheDayUncommittedPayload = {
@@ -2561,18 +2635,18 @@ export type PickOfTheDayUncommittedPayload = {
2561
2635
  /** Provider platform. Always polymarket. */
2562
2636
  platform: "polymarket";
2563
2637
  };
2564
- /** Provider-first sports context for a Pick of the Day market: team crests, league branding, and live score. Team logos and league logo are provider-owned (Polymarket /teams crests for clubs, country flags for national teams and tennis players); no local derivation. */
2638
+ /** Provider-first sports context for a Pick of the Day market: team crests, league branding, and live score. Each team `logo` is a registered club crest or national flag as a same-origin path where one exists, and provider artwork otherwise. */
2565
2639
  export type PickSportsContext = {
2566
2640
  /** League or competition display name (e.g. "Premier League"). */
2567
2641
  league_name: string | null;
2568
- /** Provider-owned event taxonomy from Gamma eventMetadata, joined in league · serie · tournament order with blanks and case-insensitive duplicates removed. Separate from league_name; omitted when the provider does not supply the metadata. */
2642
+ /** Provider-owned event taxonomy from Gamma eventMetadata, joined in league · serie · tournament order with blanks and case-insensitive duplicates removed. A tennis qualifying match ends in ", Qualification", including an ATP Challenger qualifying match, which Gamma marks only in eventMetadata.tennisFixtureSource. Separate from league_name; omitted when the provider does not supply the metadata. */
2569
2643
  competition_label?: string;
2570
2644
  /** League logo URL (provider-owned). */
2571
2645
  league_logo: string | null;
2572
2646
  /** The team mapped to the market's YES outcome, or the parent-event home/first team when event_matchup is true. */
2573
- yes_team: PickSportsTeam;
2647
+ yes_team: PickSportsTeam | null;
2574
2648
  /** The team mapped to the market's NO outcome, or the parent-event away/second team when event_matchup is true. */
2575
- no_team: PickSportsTeam;
2649
+ no_team: PickSportsTeam | null;
2576
2650
  /** Provider game identifier (Polymarket Gamma gameId); omitted when the provider supplies none. */
2577
2651
  game_id?: number;
2578
2652
  /** Always present. True when the two teams are the parent-event match identity for a teamless binary leg (e.g. a draw, totals, or prop market), not the market's own outcomes. */
@@ -2588,11 +2662,11 @@ export type PickSportsTeam = {
2588
2662
  label: string | null;
2589
2663
  /** Abbreviated team label (e.g. "POR"). */
2590
2664
  short_label: string | null;
2591
- /** Full team or competitor name (e.g. "Portugal national football team"). */
2665
+ /** The name to show for this team or competitor, the same on every surface (e.g. "UCF Knights", "Oklahoma City Thunder", "Portugal"). `label` keeps the market outcome's own spelling. */
2592
2666
  full_name: string | null;
2593
2667
  /** Provider team identifier (Polymarket /teams id). */
2594
2668
  provider_id: number | null;
2595
- /** Team crest or flag URL. Official NFL (32), WNBA (15), NBA (30), NHL (32), and MLB (30) club crests use same-origin relative paths (`/api/sports/team-logos/{league}/{abbr}.svg?v=<content hash>`); resolve relative URLs against the API origin. Vendored soccer club crests use the same path with `.png`. Other teams use provider artwork, including country flags for national teams and tennis players. Novelty and national-team rows outside the vendored club sets retain provider artwork. */
2669
+ /** Team crest or flag URL. Official NFL (32), WNBA (15), NBA (30), NHL (32), and MLB (30) club crests use same-origin relative paths (`/api/sports/team-logos/{league}/{abbr}.svg?v=<content hash>`); resolve relative URLs against the API origin. Vendored soccer club crests use the same path with `.png`. National teams in the registered national-team competitions use the same path with `.svg`: the official national flag, drawn whole at its own aspect. Other teams use provider artwork, including country flags for tennis players. Novelty rows, and national-team rows that are not exactly one country, retain provider artwork. */
2596
2670
  logo: string | null;
2597
2671
  /** True when artwork measurements show that the team mark needs a light plate on a dark background. Vendored crest verdicts are tied to the exact asset bytes; provider artwork is measured by the teams sync. Always sent; false when no current measurement marks the logo dark. */
2598
2672
  logo_mark_dark: boolean;
@@ -2615,16 +2689,28 @@ export type PickSportsTeam = {
2615
2689
  headshot_revision?: number;
2616
2690
  /** Optional latest retrieved ATP/WTA singles rank for this player. Absent for unranked, ambiguous, doubles, expired, or unavailable identities. This is not rank at match time. */
2617
2691
  ranking?: TennisRanking;
2692
+ /** True when artwork measurements show that the team mark disappears on a white background and needs a dark plate there: the light-background twin of logo_mark_dark. Vendored crest verdicts are tied to the exact asset bytes; provider artwork is measured on white by the teams sync. Always sent; false when no current measurement marks the logo light. */
2693
+ logo_mark_light: boolean;
2694
+ /** True when logo_mark_dark and logo_mark_light are both measurements of this exact logo URL, so their false means the mark is legible on that background. Every vendored crest is measured; a provider logo is measured once the teams sync has scored it, usually within a few hourly cycles of first appearing. Always sent; false while the logo is not measured yet. */
2695
+ logo_mark_measured: boolean;
2618
2696
  };
2619
2697
  export type PlatformCapabilities = {
2620
2698
  grade: PlatformCapabilityStatus;
2621
2699
  pnl: PlatformCapabilityStatus;
2622
2700
  strategy: PlatformCapabilityStatus;
2623
2701
  timeline: PlatformCapabilityStatus;
2624
- /** The large-trade feed. Canonical key since #16304; whale_signal is its deprecated spelling, emitted beside it with the same value. */
2702
+ /** The large-trade feed. Canonical key since #16304; whale_signal is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
2625
2703
  large_trades: PlatformCapabilityStatus;
2704
+ /**
2705
+ * Deprecated spelling of large_trades, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trades.
2706
+ * @deprecated
2707
+ */
2626
2708
  whale_signal: PlatformCapabilityStatus;
2627
2709
  suspicious_trades: PlatformCapabilityStatus;
2710
+ /**
2711
+ * Deprecated spelling of suspicious_trades, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read suspicious_trades.
2712
+ * @deprecated
2713
+ */
2628
2714
  insider_radar: PlatformCapabilityStatus;
2629
2715
  market_snapshot: PlatformCapabilityStatus;
2630
2716
  };
@@ -2635,15 +2721,15 @@ export type Platforms = {
2635
2721
  polymarket: PlatformCapabilities;
2636
2722
  };
2637
2723
  };
2638
- /** A derived 0xinsider correction to Polymarket's P&L, never a Polymarket value. Polymarket misbooks neg-risk conversions, in both directions: it puts cost on placeholder YES outcomes minted by a conversion and never books it as a loss (negative amount), and its position records leave out shares the wallet really got, such as YES minted by a conversion, so it books no P&L on them (positive amount). Per neg-risk market the wallet converted in, 0xinsider measures Polymarket's own activity cash against the sum of its position P&L, and sums the difference over every measured market whose shares did not move by direct transfer: transferred shares have no activity row, so such a market keeps Polymarket's figure and is counted in markets_excluded. It is published once every neg-risk market the wallet converted in is measured and checked for transfers, and stays as last published until then (on the trader body, pnl.correction_pending says so); a sum under $1 either way publishes nothing. The body's own P&L fields keep Polymarket's figures; this object adds the amount and the corrected figures. Money is truncated toward zero to cents. */
2724
+ /** A derived 0xinsider correction to Polymarket's P&L, never a Polymarket value. Polymarket misbooks neg-risk conversions, in both directions: it puts cost on placeholder YES outcomes minted by a conversion and never books it as a loss (negative amount), and its position records leave out shares the wallet really got, such as YES minted by a conversion, so it books no P&L on them (positive amount). Per neg-risk market the wallet converted in, 0xinsider measures Polymarket's own activity cash against the sum of its position P&L, and sums the difference over every measured market whose shares did not move by direct transfer: transferred shares have no activity row, so such a market keeps Polymarket's figure and is counted in markets_excluded. It is published once every neg-risk market with a sports or esports event that the wallet converted in is measured and checked for transfers, and stays as last published until then; a market with no sports or esports event is not measured, and counts only when it was measured before (on the trader body, pnl.correction_pending says so); a sum under $1 either way publishes nothing. The body's own P&L fields keep Polymarket's figures; this object adds the amount and the corrected figures. Money is truncated toward zero to cents. */
2639
2725
  export type PnlCorrection = {
2640
2726
  /** The correction method. */
2641
2727
  basis: "neg_risk_conversion_v1";
2642
2728
  /** The correction in USD. Negative when Polymarket overstates the wallet. */
2643
2729
  amount: number;
2644
- /** Polymarket's net realized P&L plus amount: the figure 0xinsider grades on. Omitted when Polymarket's figure is. */
2730
+ /** Polymarket's net realized P&L plus amount. Since 2026-10-22 the grade reads this figure's sports and esports share. Omitted when Polymarket's figure is. */
2645
2731
  realized?: number;
2646
- /** Polymarket's net total P&L plus amount: the 0xinsider profile's Total P&L. Omitted when Polymarket's figure is, and on leaderboard entries. */
2732
+ /** Polymarket's net total P&L over every Polymarket market of the wallet, plus amount. Omitted when Polymarket's figure is, and on leaderboard entries. */
2647
2733
  net_total?: number;
2648
2734
  /** The newest measurement among the measured markets. */
2649
2735
  as_of: string;
@@ -2686,10 +2772,16 @@ export type Position = {
2686
2772
  address: string;
2687
2773
  username?: string;
2688
2774
  grade?: "S" | "A" | "B" | "C" | "D" | "F";
2689
- /** Win rate as a ratio from 0 to 1 (0.62 means 62%), the same scale as stats.win_rate on GET /api/v1/trader/{address}. Absent when unknown. */
2775
+ /** Sports and esports win rate as a ratio from 0 to 1 (0.62 means 62%): wins over the decided sports and esports markets on the wallet's record, the same figure as pnl.in_scope.win_rate and stats.win_rate on GET /api/v1/trader/{address}. Since 2026-10-27 it no longer counts other markets (#29953). Absent when the wallet has no record or no decided market. */
2690
2776
  win_rate?: number;
2691
- /** Polymarket's net total P&L for the wallet in USD: native Polymarket position P&L across all markets, fees included, plus credited maker and taker rebates (trader_trading_pnl.net_total_pnl). The 0xinsider profile's Total P&L is this figure unless the wallet has a published correction for neg-risk conversions, which GET /api/v1/trader/{address} serves as pnl.correction; the profile then shows pnl.correction.net_total. Not the Polymarket leaderboard figure, which GET /api/v1/trader/{address} still serves as pnl.total. Omitted when the wallet has no native accounting snapshot; the leaderboard figure is never substituted. */
2777
+ /**
2778
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's net total P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29953). Read trader.in_scope_realized_pnl.
2779
+ * @deprecated
2780
+ */
2692
2781
  pnl?: number;
2782
+ /** The wallet's realized P&L in USD on sports and esports markets, the figure the 0xinsider profile shows: the record behind pnl.in_scope.realized_pnl on GET /api/v1/trader/{address}, to cents. For a graded wallet it is read from the latest grading pass, so it can trail that figure until the next pass. Omitted until 0xinsider has computed the wallet's record (#29953). */
2783
+ in_scope_realized_pnl?: number;
2784
+ /** Sports and esports markets on the wallet's record, pnl.in_scope.markets on GET /api/v1/trader/{address}. Since 2026-10-27 it no longer counts other markets (#29953). Absent when the wallet has no record. */
2693
2785
  markets?: number;
2694
2786
  /** Days since the wallet's first-seen time. For a wallet 0xinsider first recorded on or after March 21, 2026, that is when 0xinsider recorded it. For a wallet recorded earlier, it is usually the wallet's first Polymarket activity, so the age can run to years. It is not the wallet's on-chain age or the time of its first trade. Absent when the first-seen time is unknown. */
2695
2787
  wallet_age_days?: number;
@@ -2793,15 +2885,15 @@ export type ProofPendingPickSlot = {
2793
2885
  supersedes_pick_id: string | null;
2794
2886
  };
2795
2887
  export type ReportPayload = {
2796
- /** Canonical key since #16304; total_whale_trades is its deprecated spelling, emitted beside it with the same value. */
2888
+ /** Canonical key since #16304; total_whale_trades is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
2797
2889
  total_large_trades: number | null;
2798
2890
  total_whale_trades: number | null;
2799
- /** Canonical key since #16304; total_whale_volume is its deprecated spelling, emitted beside it with the same value. */
2891
+ /** Canonical key since #16304; total_whale_volume is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
2800
2892
  total_large_trade_volume: number | null;
2801
2893
  total_whale_volume: number | null;
2802
2894
  biggest_trade_size: number | null;
2803
2895
  active_traders: number | null;
2804
- /** Canonical key since #16304; top_whale_trades is its deprecated spelling, emitted beside it with the same value. */
2896
+ /** Canonical key since #16304; top_whale_trades is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
2805
2897
  top_large_trades: ({
2806
2898
  /** Provider outcome label for the traded side. */
2807
2899
  outcome: string | null;
@@ -2828,7 +2920,7 @@ export type ReportPayload = {
2828
2920
  /** Trader pseudonym, when no display name is known. */
2829
2921
  pseudonym: string | null;
2830
2922
  /** Trader grade (S-F) at snapshot time. */
2831
- trader_grade: string | null;
2923
+ trader_grade: "S" | "A" | "B" | "C" | "D" | "F" | null;
2832
2924
  })[] | null;
2833
2925
  top_whale_trades: ({
2834
2926
  /** Provider outcome label for the traded side. */
@@ -2856,11 +2948,19 @@ export type ReportPayload = {
2856
2948
  /** Trader pseudonym, when no display name is known. */
2857
2949
  pseudonym: string | null;
2858
2950
  /** Trader grade (S-F) at snapshot time. */
2859
- trader_grade: string | null;
2951
+ trader_grade: "S" | "A" | "B" | "C" | "D" | "F" | null;
2952
+ })[] | null;
2953
+ categories: ({
2954
+ category: string | null;
2955
+ large_trade_count: number | null;
2956
+ whale_trade_count: number | null;
2957
+ category_volume: number | null;
2860
2958
  })[] | null;
2861
- categories: Record<string, unknown>[] | null;
2862
2959
  /** Counts of current grades for distinct Polymarket traders with at least one whale alert in the report's source date range. The grade is the current projection at snapshot materialization time, not a historical grade at trade time. Traders without a current ranking projection are omitted; a null grade entry means the active trader's current grade is unavailable. */
2863
- grade_distribution: Record<string, unknown>[] | null;
2960
+ grade_distribution: ({
2961
+ grade: "S" | "A" | "B" | "C" | "D" | "F" | null;
2962
+ count: number | null;
2963
+ })[] | null;
2864
2964
  /** Which markets the report counts. sports_and_esports for a period that ends on or after 2026-10-21: totals, categories, top trades and the grade cohort cover sports and esports markets only. all_markets for an earlier period, whose stored report keeps every Polymarket market it published. */
2865
2965
  market_scope: "all_markets" | "sports_and_esports";
2866
2966
  };
@@ -2954,7 +3054,7 @@ export type ScoreCell = {
2954
3054
  };
2955
3055
  /** Shape the provider score string was parsed into. `two_side` is one aggregate per side (basketball `105-98`), `multi_set` is per-set columns (tennis `6-7(5-7), 6-0, 1-0`), `esports_series` is a maps/sets/format triplet (`000-000|2-0|Bo3`). Omitted when the score could not be parsed. */
2956
3056
  export type ScoreFormat = "two_side" | "multi_set" | "esports_series";
2957
- /** `sharp_money_flow_detected` data (Pro and Max): ranked-trader net flow on a market crossed the threshold. The deprecated spelling `smart_money_flow_detected` delivers the same object. */
3057
+ /** `sharp_money_flow_detected` data (Pro and Max): ranked-trader net flow on a market crossed the threshold. The deprecated spelling `smart_money_flow_detected` delivers the same object until its sunset on 2027-02-01 (#29352). */
2958
3058
  export type SharpMoneyFlowDetectedData = {
2959
3059
  /** Polymarket condition id of the market. */
2960
3060
  condition_id: string;
@@ -2987,14 +3087,18 @@ export type SmartMoneyFlowMarket = {
2987
3087
  direction: "YES" | "NO";
2988
3088
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for the net-flow direction outcome; null when unavailable (e.g. unsynced markets). */
2989
3089
  token_id: string | null;
2990
- /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value. */
3090
+ /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
2991
3091
  large_trade_count: number;
3092
+ /**
3093
+ * Deprecated spelling of large_trade_count, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_count.
3094
+ * @deprecated
3095
+ */
2992
3096
  whale_trade_count: number;
2993
3097
  buy_volume_usd: number;
2994
3098
  sell_volume_usd: number;
2995
3099
  };
2996
3100
  /**
2997
- * Deprecated alias of sharp_money; byte-identical and retained for backward compatibility.
3101
+ * Deprecated alias of sharp_money; byte-identical. Sunset 2027-02-01 (#29352): removed from V1 on that date; read sharp_money.
2998
3102
  * @deprecated
2999
3103
  */
3000
3104
  smart_money: {
@@ -3002,8 +3106,12 @@ export type SmartMoneyFlowMarket = {
3002
3106
  direction: "YES" | "NO";
3003
3107
  /** The Polymarket CLOB token id (ERC1155 asset id, decimal string) for the net-flow direction outcome; null when unavailable (e.g. unsynced markets). */
3004
3108
  token_id: string | null;
3005
- /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value. */
3109
+ /** Canonical key since #16304 (Polymarket's noun is large trade); whale_trade_count is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
3006
3110
  large_trade_count: number;
3111
+ /**
3112
+ * Deprecated spelling of large_trade_count, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read large_trade_count.
3113
+ * @deprecated
3114
+ */
3007
3115
  whale_trade_count: number;
3008
3116
  buy_volume_usd: number;
3009
3117
  sell_volume_usd: number;
@@ -3015,8 +3123,12 @@ export type SnapshotCompleteness = {
3015
3123
  status: "complete" | "partial" | "empty";
3016
3124
  reason: string;
3017
3125
  expected_days: number;
3018
- /** Canonical key since #16304; covered_days_with_whale_activity is its deprecated spelling, emitted beside it with the same value. */
3126
+ /** Canonical key since #16304; covered_days_with_whale_activity is its deprecated spelling, emitted beside it with the same value until its sunset on 2027-02-01 (#29352). */
3019
3127
  covered_days_with_large_trade_activity: number;
3128
+ /**
3129
+ * Deprecated spelling of covered_days_with_large_trade_activity, emitted beside it with the same value. Sunset 2027-02-01 (#29352): removed from V1 on that date; read covered_days_with_large_trade_activity.
3130
+ * @deprecated
3131
+ */
3020
3132
  covered_days_with_whale_activity: number;
3021
3133
  };
3022
3134
  export type SnapshotState = {
@@ -3069,7 +3181,7 @@ export type SuspiciousTrade = {
3069
3181
  /** Stored trade timestamp. */
3070
3182
  created_at: string;
3071
3183
  };
3072
- /** `suspicious_trade_flagged` data (Pro and Max): a trade's suspicion score crossed the flag threshold for the first time. The deprecated spelling `insider_radar_flag_raised` delivers the same object. */
3184
+ /** `suspicious_trade_flagged` data (Pro and Max): a trade's suspicion score crossed the flag threshold for the first time. The deprecated spelling `insider_radar_flag_raised` delivers the same object until its sunset on 2027-02-01 (#29352). */
3073
3185
  export type SuspiciousTradeFlaggedData = {
3074
3186
  /** Numeric id of the flagged trade, a JSON number. It is the `id` that `GET /api/v1/large-trades/{id}` accepts. */
3075
3187
  trade_id: number;
@@ -3090,7 +3202,7 @@ export type SuspiciousTradeFlaggedData = {
3090
3202
  /** Fill price of the flagged trade. */
3091
3203
  price: number;
3092
3204
  };
3093
- /** Optional current-game tennis facts from API-Tennis, aligned with live_score.scores display order. These facts have their own revision and expiry; Polymarket remains the source of sets, match status, period, and the outer live-score revision. New observations require corroborated identity, current set/games, and live state. Cached responses and replayed frames may still carry expired facts, so clients must enforce expires_at. */
3205
+ /** Optional current-game tennis facts from API-Tennis, aligned with live_score.scores display order. These facts have their own revision and expiry; Polymarket remains the source of sets, match status, period, and the outer live-score revision. New observations require corroborated identity, current set/games, and live state. Where Polymarket publishes no score (tennis doubles, whose live_score reads one 0-0 set throughout), the group binds on both pairs' names, the tour, the date and API-Tennis's live flag, and carries set_games, the provider's set score for the match. Cached responses and replayed frames may still carry expired facts, so clients must enforce expires_at. */
3094
3206
  export type TennisPoints = {
3095
3207
  source: "api_tennis";
3096
3208
  /** API-Tennis match ID. This is not a Polymarket market or event ID. */
@@ -3107,10 +3219,12 @@ export type TennisPoints = {
3107
3219
  observed_at: string;
3108
3220
  /** Stop displaying the point group at this instant, even if the enclosing score remains fresh. The group expires 30 seconds after observed_at. */
3109
3221
  expires_at: string;
3110
- /** Current set number. Display points only while this matches the enclosing scoreboard. */
3222
+ /** Current set number. Display points only while this matches the enclosing scoreboard, unless set_games is present. */
3111
3223
  set_number: number;
3112
- /** Current-set games in first/second order. Display points only while these match the enclosing scoreboard. */
3224
+ /** Current-set games in first/second order. Display points only while these match the enclosing scoreboard, unless set_games is present. */
3113
3225
  games: number[];
3226
+ /** API-Tennis games in every listed set, first set first, each in first/second order. Present only when Polymarket publishes no score for the match (tennis doubles): display these as the set score, and discard the group once live_score carries a nonzero game. A deciding match tie-break is listed as games, for example 9-5. Omitted for every other match. */
3227
+ set_games?: number[][];
3114
3228
  };
3115
3229
  /** A provider-reported ATP/WTA singles rank with independent retrieval and expiry clocks. API-Tennis provides no ranking publication date. Retrieval time does not establish when the tour published the ranking. */
3116
3230
  export type TennisRanking = {
@@ -3140,33 +3254,52 @@ export type Trader = {
3140
3254
  forecast_evidence?: number;
3141
3255
  rank?: number;
3142
3256
  pnl: {
3143
- /** Polymarket's all-time leaderboard P&L in USD, from Polymarket's latest observation of this wallet on its all-time leaderboard (dated by the leaderboard_pnl data_quality group). Omitted when that leaderboard has no current observation ranking the wallet; 0xinsider requests one, and never serves an older stored figure in its place. Kept for provider parity and back-compat. Not the profile's Total P&L and not realized plus unrealized: it can differ from net_total by a wide margin. Read net_total for the figure the 0xinsider profile shows. */
3257
+ /**
3258
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's all-time leaderboard P&L, which covered every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29830). Read pnl.in_scope.realized_pnl.
3259
+ * @deprecated
3260
+ */
3144
3261
  total?: number;
3145
- /** Polymarket's net total P&L in USD: native Polymarket position P&L, with fees already included, plus credited maker and taker rebates (trader_trading_pnl.net_total_pnl). Truncated toward zero to cents before conversion to a JSON number. Omitted when the wallet has no native accounting snapshot; pnl.total is never substituted. The 0xinsider profile's Total P&L is this figure unless pnl.correction is present, then pnl.correction.net_total. */
3262
+ /**
3263
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's net total P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29830). Read pnl.in_scope.realized_pnl.
3264
+ * @deprecated
3265
+ */
3146
3266
  net_total?: number;
3147
- /** The 0xinsider correction to Polymarket's P&L for neg-risk conversions. Present only when one is published; pnl.net_total and pnl.realized keep Polymarket's own figures, and correction.net_total and correction.realized add the amount to them. */
3267
+ /**
3268
+ * Deprecated since 2026-10-27 and never sent. It was the neg-risk conversion correction to the wallet-wide pnl.net_total and pnl.realized (#29830). Its sports and esports part is inside pnl.in_scope.realized_pnl.
3269
+ * @deprecated
3270
+ */
3148
3271
  correction?: PnlCorrection;
3149
- /** true while 0xinsider is still checking some of the wallet's converted neg-risk markets (not yet measured, measured and not yet checked for transfers, or its latest reads keep failing), so the correction may change, or arrive where none is published yet. Omitted otherwise. */
3272
+ /** true while 0xinsider is still checking some of the wallet's converted neg-risk markets with a sports or esports event (not yet measured, measured and not yet checked for transfers, or its latest reads keep failing), so the correction's part inside pnl.in_scope.realized_pnl may change, or arrive where none is published yet. Omitted otherwise. */
3150
3273
  correction_pending?: boolean;
3151
- /** For pnl.realized, expand=trust marks a matching native accounting snapshot as computed: native Polymarket realized P&L plus credited maker and taker rebates, with fees already included. The exact numeric value is truncated toward zero to cents before conversion to a JSON number. Without a matching native accounting snapshot, pnl.realized is omitted and its trust metadata is unavailable. Raw total P&L is never substituted for realized P&L. */
3274
+ /**
3275
+ * Deprecated since 2026-10-27 and never sent. It was native Polymarket realized P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29830). Read pnl.in_scope.realized_pnl.
3276
+ * @deprecated
3277
+ */
3152
3278
  realized?: number;
3279
+ /** Unrealized P&L in USD of the wallet's open positions on its synced markets, from the open-position aggregate (dated by the positions data_quality group). Since 2026-10-27 (#29366) a wallet that holds a sports or esports market has only sports and esports markets synced, so this covers those positions; before, it covered every Polymarket market. A wallet with no sports or esports market can still carry older markets of other categories until they are deleted. */
3153
3280
  unrealized?: number;
3154
- /** DEPRECATED, never sent. The local pnl_7d rollup over-counted P&L (#5416 class) and is no longer emitted. Read the provider-native weekly window from GET /api/trader/{address}/profile-summary instead. */
3155
- last_7d?: number;
3156
- /** DEPRECATED, never sent. The local pnl_30d rollup over-counted P&L (#5416 class) and is no longer emitted. Read the provider-native monthly window from GET /api/trader/{address}/profile-summary instead. */
3157
- last_30d?: number;
3158
- /** Additive lossless counterpart. Omitted when the trusted native realized-P&L source is unavailable; existing numeric fields keep their display-safe v1 semantics. */
3281
+ /**
3282
+ * Deprecated since 2026-10-27 and never sent: its one member was the lossless counterpart of the retired pnl.realized (#29830).
3283
+ * @deprecated
3284
+ */
3159
3285
  exact?: TraderPnlExact;
3160
- /** Additive (#27311): the wallet's sports and esports record, the figure the 0xinsider profile headlines. Omitted until 0xinsider has computed the wallet's record; absent means not computed yet, never zero. The other pnl fields stay Polymarket's wallet-wide figures. */
3286
+ /** Additive (#27311): the wallet's sports and esports record, the figure the 0xinsider profile headlines, dated by the sports_record data_quality group. Omitted until 0xinsider has computed the wallet's record; absent means not computed yet, never zero. Also omitted for a wallet that traded no sports or esports market, which never gets a record: then stats.markets_traded is 0 and the sports_record group is partial with owner traders.last_synced (since 2026-10-29, #30589, #30657). Also omitted for a wallet that trades only combos and holds no single sports or esports market: the record counts single markets, so it has none, stats.markets_traded and stats.win_rate are omitted, and the sports_record group is partial with owner traders.last_synced (since 2026-10-29, #30637). Since 2026-10-27 it is the wallet's only P&L figure besides pnl.unrealized (#29830). */
3161
3287
  in_scope?: TraderPnlInScope;
3162
3288
  };
3289
+ /** Sports and esports markets only since 2026-10-27 (#29830): markets_traded and win_rate come from the wallet's sports and esports record (pnl.in_scope), and total_volume from its stored trade days. A wallet that traded no sports or esports market never gets a record: markets_traded is 0 and win_rate is omitted (since 2026-10-29, #30589, #30657). A wallet that trades only combos has no record either: both are omitted (since 2026-10-29, #30637). */
3163
3290
  stats: {
3291
+ /** Sports and esports markets the wallet traded, any status: pnl.in_scope.markets, dated by the sports_record data_quality group. Omitted until the record is computed. 0 for a wallet that traded no sports or esports market, which never gets a record: at its last completed sync Polymarket counted no market for it, or the sync read its Polymarket positions and found no sports or esports market; none is stored, and no Polymarket sports or esports board lists it; the sports_record group then carries the sync clock (since 2026-10-29, #30589; the second case since #30657). Omitted for a wallet that trades only combos and holds no single sports or esports market, which has no record (since 2026-10-29, #30637). Counted every Polymarket market before 2026-10-27. */
3164
3292
  markets_traded?: number;
3293
+ /** Won over decided sports and esports markets, 0 to 1: pnl.in_scope.win_rate truncated to four places, dated by the sports_record data_quality group. Omitted until the record is computed, while the wallet has no decided sports or esports market, for a wallet that traded no sports or esports market (#30589, #30657), and for one that trades only combos (#30637). Counted every Polymarket market before 2026-10-27. */
3165
3294
  win_rate?: number;
3295
+ /**
3296
+ * Deprecated since 2026-10-27 and never sent. It counted mark-to-market days over every Polymarket market of the wallet (#29830). Read stats.all.win_days and stats.all.loss_days from GET /api/v1/trader/{address}/pnl, which count sports and esports days.
3297
+ * @deprecated
3298
+ */
3166
3299
  daily_win_rate?: number;
3167
- /** Full-history both-sides USD cash volume from Polymarket user-volume. Omitted without a verified observation; never leaderboard shares. Its observation time is published as the volume group in data_quality and as trust.total_volume.freshness.as_of, both trader_usd_volume.observed_at; synced_at is a different clock and is never a substitute for it. */
3300
+ /** Sports and esports USD volume, all time: the sum of every stored trade day's in-scope volume (trader_trade_daily_rollups.in_scope_volume_total), the profile's Volume traded. Dated by the volume data_quality group, which carries the trader sync clock. 0 for a synced wallet with no stored trade day. Omitted before the wallet's first completed sync and while any stored day's in-scope volume is not computed yet, so a partial sum is never served. Polymarket's full-history wallet-wide volume before 2026-10-27 (#29830). */
3168
3301
  total_volume?: number;
3169
- /** Additive lossless counterpart to `total_volume`. Omitted when the verified provider observation is unavailable. */
3302
+ /** Additive lossless counterpart to `total_volume`, present exactly when it is. */
3170
3303
  exact?: TraderStatsExact;
3171
3304
  };
3172
3305
  strategy?: {
@@ -3175,9 +3308,12 @@ export type Trader = {
3175
3308
  description?: string;
3176
3309
  confidence?: number;
3177
3310
  };
3178
- /** Per-category rank context when expand=categories is requested. Values include available rank, category totals, performance and record counts; scaled_total_pnl is a legacy alias of total_pnl. Its measurement basis and update timing differ from the plain record returned by GET /api/v1/trader/{address}/categories, so the two need not agree. Use this for rank context and that route for the plain record. The inner key-set is intentionally unconstrained and may contain additional compatibility fields. */
3311
+ /** Per-category rank context when expand=categories is requested. Values include available rank, category totals, performance and record counts; scaled_total_pnl is a legacy alias of total_pnl. Its measurement basis and update timing differ from the plain record returned by GET /api/v1/trader/{address}/categories, so the two need not agree. Use this for rank context and that route for the plain record. Sports and esports only (#28761): keys are sports and esports categories, and a category outside them is omitted, as on that route. The inner key-set is intentionally unconstrained and may contain additional compatibility fields. */
3179
3312
  category_strengths?: Record<string, unknown>;
3180
- /** Curated advanced risk/performance metrics (expand=quant_metrics or expand[]=quant_metrics). Omitted unless expanded and backed by a computed row strictly under six hours old; a missing row, NULL computed_at, or age of exactly six hours or more is stale and omitted. Provider-input changes may intentionally lag inside the bounded six-hour window. When present, all listed fields are present (each is a number or null); null means insufficient trade history and must not be treated as 0. The fixed field shape is unchanged. */
3313
+ /**
3314
+ * Deprecated since 2026-10-27 and never sent. These advanced risk and performance metrics covered every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29589). expand=quant_metrics is still accepted and adds nothing. For the sports and esports record read pnl.in_scope here, and GET /api/v1/trader/{address}/pnl for its daily series. The member shape below is what the object held before; it is kept so existing type declarations still compile.
3315
+ * @deprecated
3316
+ */
3181
3317
  quant_metrics?: {
3182
3318
  /** Trader smart score on a 0..100 display scale; higher is stronger. Null when unavailable. */
3183
3319
  smart_score: number | null;
@@ -3202,11 +3338,11 @@ export type Trader = {
3202
3338
  synced_at?: string;
3203
3339
  /** synced, unknown, or pending. */
3204
3340
  sync_status?: string;
3205
- /** Data age and coverage for this trader body. Always present. Its six groups are sync (traders.last_synced, covering pnl.net_total, pnl.realized, stats.markets_traded, stats.win_rate, stats.daily_win_rate, last_active, synced_at and sync_status), ranking (trader_rankings.computed_at, covering grade, score, streak_tier, forecast_score and forecast_evidence), leaderboard_rank (leaderboard_rank_refresh_state.completed_at, the completion time of the latest fully completed global rank refresh, covering rank), volume (trader_usd_volume.observed_at, covering stats.total_volume) and positions (trader_position_snapshots.last_refreshed_at with traders.last_synced as fallback, covering pnl.unrealized, the open-position aggregate) and leaderboard_pnl (trader_profile_provider_snapshots.observed_at, covering pnl.total: unavailable when Polymarket's all-time leaderboard has no current observation ranking the wallet). The positions clock is the latest successful /positions snapshot when one exists, otherwise the last completed trader sync; it does not date closed or native accounting values. A rank or position value remains unknown or unavailable when its clock or value is absent. For an unknown wallet every group is unavailable. If the open-position read itself fails, positions is unavailable with a reason that says so, pnl.unrealized is absent, and the body is answered fresh (meta.cached false) and is not kept for later callers. */
3341
+ /** Data age and coverage for this trader body. Always present. Its six groups are sync (traders.last_synced, covering last_active, synced_at and sync_status), sports_record (trader_product_scope_records.computed_at, covering pnl.in_scope, stats.markets_traded and stats.win_rate: unavailable until the wallet's sports and esports record is computed, partial while it has no decided sports or esports market; for a wallet that traded no sports or esports market, which never gets a record, partial with owner traders.last_synced, as of the completed sync that found none, stats.markets_traded 0 and pnl.in_scope and stats.win_rate omitted, since 2026-10-29, #30589, #30657; for a wallet that trades only combos and holds no single sports or esports market, partial with owner traders.last_synced and all three omitted, since 2026-10-29, #30637), ranking (trader_rankings.computed_at, covering grade, score, streak_tier, forecast_score and forecast_evidence), leaderboard_rank (leaderboard_rank_refresh_state.completed_at, the completion time of the latest fully completed global rank refresh, covering rank), volume (traders.last_synced, covering stats.total_volume, the sum of the trade days the sync stores: unavailable before the first completed sync and while a stored day's sports and esports volume is not computed) and positions (trader_position_snapshots.last_refreshed_at with traders.last_synced as fallback, covering pnl.unrealized, the open-position aggregate). Since 2026-10-27 (#29830) there is no leaderboard_pnl group, and volume is dated by the sync clock instead of trader_usd_volume.observed_at. The positions clock is the latest successful /positions snapshot when one exists, otherwise the last completed trader sync. A rank or position value remains unknown or unavailable when its clock or value is absent. For an unknown wallet every group is unavailable. If the open-position read itself fails, positions is unavailable with a reason that says so, pnl.unrealized is absent, and the body is answered fresh (meta.cached false) and is not kept for later callers. */
3206
3342
  data_quality: DataQuality;
3207
3343
  /** Field-level trust metadata. Present only when expand=trust or expand[]=trust is requested. */
3208
3344
  trust?: TraderTrust;
3209
- /** Current evidence for observed and known categories (expand=categories or expand[]=categories). Omitted unless expanded. Includes insufficient, stale, unknown and degraded rows; absence of a category is not proof of skill. The global grade is unchanged. */
3345
+ /** Current evidence for observed and known categories (expand=categories or expand[]=categories). Omitted unless expanded. Includes insufficient, stale, unknown and degraded rows; absence of a category is not proof of skill. The global grade is unchanged. Sports and esports only (#28827): a category outside them is omitted, as on GET /api/v1/trader/{address}/categories. */
3210
3346
  category_records?: CategorySkillV2[];
3211
3347
  category_skill_model?: CategorySkillModelReadiness;
3212
3348
  };
@@ -3240,31 +3376,37 @@ export type TraderCategoryRecords = {
3240
3376
  };
3241
3377
  export type TraderContext = {
3242
3378
  trader: Trader;
3243
- /** Aggregate position and P&L coverage for the trader. Counts all Polymarket markets, not only sports and esports. Omitted entirely (key absent, never null) when the trader is not in the local database or native net economics is unavailable. Realized fields remain numbers when present, including a genuine zero. */
3379
+ /** Aggregate position and P&L coverage for the trader, over its synced markets. Since 2026-10-27 (#29366) a wallet that holds a sports or esports market has only sports and esports markets synced, so markets_synced, markets_resolved, markets_open, unrealized_mtm, cost_basis_locked and the resolved win figures cover those markets; before, they covered every Polymarket market. A wallet with no sports or esports market can still carry older markets of other categories until they are deleted. markets_total, total_realized_pnl and synced_realized_pnl still cover every Polymarket market of the wallet. Omitted entirely (key absent, never null) when the trader is not in the local database or native net economics is unavailable. Realized fields remain numbers when present, including a genuine zero. */
3244
3380
  position_summary?: {
3245
- /** Provider markets_traded count when known; null when the provider total is unavailable. */
3381
+ /** Polymarket's count of the markets the wallet traded, every category, when known; null when the provider total is unavailable. */
3246
3382
  markets_total: number | null;
3247
3383
  /** Markets with locally synced position rows. */
3248
3384
  markets_synced: number;
3249
- /** Synced markets that have resolved. */
3385
+ /** Markets outside sports and esports that the wallet traded and whose synced rows 0xinsider deleted, counted when they were deleted (from 2026-10-27, #29366); 0 when none were. Not in markets_synced or any other count here; sync_coverage adds it to markets_synced so both sides of that ratio count every category. */
3386
+ markets_pruned: number;
3387
+ /** Markets outside sports and esports that the wallet first traded since 2026-10-26, which 0xinsider does not store, counted as the wallet syncs (#30165); 0 when none are. Not in markets_synced, markets_pruned or any other count here; sync_coverage adds it with markets_pruned to markets_synced. */
3388
+ markets_unstored: number;
3389
+ /** Combo markets the wallet traded, as maker or taker, counted from the combo fills 0xinsider indexes from the chain (#30218); 0 when it traded none. Polymarket counts each combo as one market in markets_total, and no position read lists one, so a combo is in no other count here; sync_coverage adds it with markets_pruned and markets_unstored to markets_synced. */
3390
+ markets_combo: number;
3391
+ /** Synced markets the wallet has settled: it closed its position by selling out, or the market resolved. Its P&L there is final. */
3250
3392
  markets_resolved: number;
3251
3393
  /** Synced markets still open with residual value (open positions with current value > 0). */
3252
3394
  markets_open: number;
3253
- /** markets_synced divided by markets_total when the provider total is known (capped at 1.0); 0.0-1.0. When markets_total is unknown or not positive (null, 0, or negative), this is 1.0 if any markets are synced (else 0.0), so cross-check markets_total before treating 1.0 as full coverage. */
3395
+ /** markets_synced plus markets_pruned plus markets_unstored plus markets_combo, divided by markets_total when the provider total is known (capped at 1.0); 0.0-1.0. Both sides count every category: no Polymarket count of a wallet's sports and esports markets exists, so the ratio does not estimate one. When markets_total is unknown or not positive (null, 0, or negative), this is 1.0 if that sum is positive (else 0.0), so cross-check markets_total before treating 1.0 as full coverage. */
3254
3396
  sync_coverage: number;
3255
- /** Native net realized P&L (USD) including credited rebates, minus the stored realized component of open positions with positive current value. Rebates are credited to the account, not to a position, so every credited rebate stays in this figure. NUMERIC arithmetic precedes conversion to a JSON number. */
3397
+ /** Native net realized P&L (USD) over every Polymarket market of the wallet, including credited rebates, minus the stored realized component of synced open positions with positive current value. Rebates are credited to the account, not to a position, so every credited rebate stays in this figure. NUMERIC arithmetic precedes conversion to a JSON number. */
3256
3398
  synced_realized_pnl: number;
3257
- /** Native net realized P&L (USD) including credited rebates, read directly from the accounting snapshot. Position sync_coverage is separate from this accounting basis. */
3399
+ /** Native net realized P&L (USD) over every Polymarket market of the wallet, including credited rebates, read directly from the accounting snapshot. For the sports and esports figure read trader.pnl.in_scope.realized_pnl. Position sync_coverage is separate from this accounting basis. */
3258
3400
  total_realized_pnl: number;
3259
- /** Mark-to-market unrealized P&L (USD) on open positions. */
3401
+ /** Mark-to-market unrealized P&L (USD) on open positions in synced markets. */
3260
3402
  unrealized_mtm: number;
3261
- /** Cost basis (USD) currently tied up in open positions. */
3403
+ /** Cost basis (USD) currently tied up in open positions in synced markets. */
3262
3404
  cost_basis_locked: number;
3263
- /** Win rate as a percentage (0-100): resolved_wins over resolved_decided. A resolved market that settled at exactly zero realized P&L (a void, a refund, a fully hedged position) is neither a win nor a loss and is not in the denominator, the same rule the leaderboard applies; null when no resolved market was decided. It is the rule of trader.stats.win_rate, read from the synced rows at request time; stats.win_rate is the stored figure the profile shows, refreshed by each sync and a few minutes after a closed-history write. context.md prints one Market win rate: this one when position_summary is present, else stats.win_rate. */
3405
+ /** Win rate as a percentage (0-100): resolved_wins over resolved_decided. A settled market that closed at exactly zero realized P&L (a void, a refund, a fully hedged position) is neither a win nor a loss and is not in the denominator, the same rule the leaderboard applies; null when no resolved market was decided. It is the rule of trader.stats.win_rate, read from the synced rows at request time; stats.win_rate is the stored figure the profile shows, refreshed by each sync and a few minutes after a closed-history write. context.md prints one Market win rate, stats.win_rate. */
3264
3406
  resolved_win_rate: number | null;
3265
- /** Resolved markets that settled at positive realized P&L: the win-rate numerator. Additive; null only on a summary cached before the field existed. */
3407
+ /** Settled markets that closed at positive realized P&L: the win-rate numerator. Additive; null only on a summary cached before the field existed. */
3266
3408
  resolved_wins: number | null;
3267
- /** Resolved markets that settled at a non-zero realized P&L: the win-rate denominator. At most markets_resolved; the difference is markets settled at exactly zero or with an unknown P&L. Additive; null only on a summary cached before the field existed. */
3409
+ /** Settled markets that closed at a non-zero realized P&L: the win-rate denominator. At most markets_resolved; the difference is markets settled at exactly zero or with an unknown P&L. Additive; null only on a summary cached before the field existed. */
3268
3410
  resolved_decided: number | null;
3269
3411
  /** RFC3339 freshness of the served OPEN-position data: the trader's latest /positions snapshot, else the last completed sync. The snapshot advances ONLY open positions, so read this as the open-position freshness clock -- the resolved/closed aggregates on this same summary (markets_resolved, resolved_win_rate) advance only on a full sync. The value is the /positions snapshot instant when one exists, so it is typically at or just before the trader-level last sync on a normal sync, and can be AFTER it while the active-view loop refreshes open positions between full syncs. This clock does not establish native accounting freshness. Always present on the wire (serialized as JSON null when the trader has neither a snapshot nor a sync); never omitted. */
3270
3412
  as_of: string | null;
@@ -3328,7 +3470,7 @@ export type TraderExportJob = {
3328
3470
  object: "trader_export_job";
3329
3471
  data: {
3330
3472
  job_id: number;
3331
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
3473
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
3332
3474
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
3333
3475
  format: "json" | "ndjson" | "csv";
3334
3476
  /** Trade rows the file holds: trades in the wallet's sports and esports markets, counted in the file's own read snapshot. Null until the worker has read the snapshot (queued, and early in running); a job accepted before 2026-10-22 can carry the earlier all-markets estimate until its file is read. */
@@ -3359,7 +3501,7 @@ export type TraderExportJob = {
3359
3501
  cancel_requested_at: string | null;
3360
3502
  /** When the job reached cancelled; null until then. */
3361
3503
  cancelled_at: string | null;
3362
- /** Worker claims so far. */
3504
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
3363
3505
  attempt: number;
3364
3506
  /** The job fails when attempt reaches this. */
3365
3507
  max_attempts: number;
@@ -3393,7 +3535,7 @@ export type TraderExportPositionWatermark = {
3393
3535
  };
3394
3536
  export type TraderExportSnapshot = {
3395
3537
  address: string;
3396
- /** The markets the export file's trades and markets sections hold: sports and esports markets only. counts.exported_markets, counts.estimated_trade_rows, counts.estimated_size_mb, reconciliation.exported_market_cost_basis and source_range.latest_trade_at and latest_market_activity_at describe those markets. The pnl dates, pnl_days, exported_activity_volume and completeness cover every market of the wallet. */
3538
+ /** The markets the export file's trades and markets sections hold: sports and esports markets only. counts.exported_markets, counts.estimated_trade_rows, counts.estimated_size_mb, reconciliation.exported_market_cost_basis and source_range.latest_trade_at and latest_market_activity_at describe those markets, and reconciliation.exported_activity_volume is the cash the wallet traded in sports and esports markets. source_range.first_pnl_date, last_pnl_date and pnl_series_status and counts.pnl_days describe the file's pnl section, the wallet's sports and esports realized P&L by day. completeness.sync_coverage is the wallet's stored markets (its sports and esports markets since 2026-10-27, #29366) plus the markets of other categories whose rows were deleted and counted (position_summary.markets_pruned on the context) and those first traded since 2026-10-26, which are not stored and are counted as the wallet syncs (position_summary.markets_unstored, #30165) and its combo markets, which Polymarket counts and no position read lists (position_summary.markets_combo, #30218), over Polymarket's count of every market it traded: both sides count every category, so a fully synced wallet reads 1.0 and complete. A wallet with nothing stored and no pnl day is empty whatever its coverage. */
3397
3539
  product_scope: "sports_esports_v1";
3398
3540
  generated_at: string;
3399
3541
  source_range: ExportSourceRange;
@@ -3447,7 +3589,7 @@ export type TraderGradeAt = {
3447
3589
  source_observed_by: string | null;
3448
3590
  } | null;
3449
3591
  };
3450
- /** A trader's daily P&L object. `id` is always present. The five sections -- `entries`, `stats`, `monthly`, `year_totals`, `drawdown` -- are present unless the request's `sections` parameter excluded them, so a request that sends no `sections` always carries all five. An excluded section is absent from the object, never null and never an empty array. */
3592
+ /** A trader's sports and esports daily P&L object. `id`, `freshness_at`, `series_status` and `realized` are always present. The five sections -- `entries`, `stats`, `monthly`, `year_totals`, `drawdown` -- are present unless the request's `sections` parameter excluded them, so a request that sends no `sections` always carries all five. An excluded section is absent from the object, never null and never an empty array. While `series_status` is `pending` the sections are empty and never mean zero. */
3451
3593
  export type TraderPnl = {
3452
3594
  /** Prefixed trader ID (`trd_...`). */
3453
3595
  id: string;
@@ -3474,18 +3616,35 @@ export type TraderPnl = {
3474
3616
  drawdown: number | null;
3475
3617
  } | null;
3476
3618
  };
3477
- /** RFC3339 served-freshness clock for this trader's PnL history = traders.daily_pnl_recomputed_at, when the daily_pnl read model this response is served from was last rebuilt; null when it has never been recomputed for the trader. Always present, so read it as a value that can be null rather than a key that can be missing. */
3619
+ /** RFC3339 served-freshness clock: when the wallet's sports and esports record, which this series is read from, was last computed, or, for a wallet that traded no sports or esports market (#30589, #30657) or trades only combos (#30637) and so has no record, its last completed sync; null while series_status is pending. Always present, so read it as a value that can be null rather than a key that can be missing. */
3478
3620
  freshness_at: string | null;
3479
- /** Daily cumulative-P&L series (oldest-first). Present unless the request's `sections` excluded it, and clipped to `from`/`to` when either is set. cumulative_profit and total_pnl stay cumulative from the start of the stored history, so a clipped slice keeps the same economic meaning; view.anchor carries the point before the window. */
3480
- entries?: {
3621
+ /** `ready` when the series is served; an empty one is a wallet with no sports or esports day, or one that traded no sports or esports market (#30589, #30657) or trades only combos (#30637). `pending` when the wallet's sports and esports record does not carry the daily series yet: every section is empty, realized is null, and the empty sections never mean zero. Retry later. */
3622
+ series_status: "ready" | "pending";
3623
+ /** How the daily series adds up to the wallet's Sports P&L, full precision: dated_pnl + undated_pnl = realized_pnl. null while series_status is pending, and for a wallet that traded no sports or esports market or trades only combos, which has no record (#30589, #30657, #30637). */
3624
+ realized: {
3625
+ /** The rule behind realized_pnl, the same basis as pnl.in_scope.basis on GET /api/v1/trader/{address}. */
3626
+ basis: "polymarket_sports_esports_v1" | "sports_esports_split_v1";
3627
+ /** The wallet's Sports P&L: pnl.in_scope.realized_pnl on GET /api/v1/trader/{address}. null when the wallet has no published realized figure. */
3628
+ realized_pnl: number | null;
3629
+ /** The sum of every day's daily_change over the full history, whatever from/to say. */
3630
+ dated_pnl: number;
3631
+ /** realized_pnl less dated_pnl. realized_pnl starts from Polymarket's figures under either basis (its sports and esports figures, or its published figure for the whole wallet split by cost) and the days from the per-market record, so undated_pnl holds the wallet's share of Polymarket rebates, the in-scope part of the neg-risk conversion correction, any market with no trade date, and the difference between Polymarket's figure and the per-market record, which on some wallets is most of it. null exactly when realized_pnl is. */
3632
+ undated_pnl: number | null;
3633
+ } | null;
3634
+ /** Sports and esports daily P&L series (oldest-first): one point for each UTC day with realized P&L or sports and esports volume. Present unless the request's `sections` excluded it, and clipped to `from`/`to` when either is set. cumulative_profit and total_pnl are the running sum of daily_change from the start of the history, so a clipped slice keeps the same economic meaning; view.anchor carries the point before the window. */
3635
+ entries?: ({
3481
3636
  date: string;
3637
+ /** Sports and esports markets this wallet traded on this UTC day, counted from the fills 0xinsider stores for it. Omitted on a day whose stored fills include a market outside sports and esports (stored before October 2026), where the count would include it, and on a day above 20 times the wallet's median day. */
3482
3638
  markets_traded?: number;
3483
- /** Cash in USD this wallet traded on this UTC day, buys and sells, summed from the fills 0xinsider has stored for it. Not Polymarket's share count, and not the full-history stats.total_volume on GET /api/v1/trader/{address}. Omitted, with markets_traded, on a day above 20 times the wallet's median day. */
3639
+ /** Volume in USD this wallet traded on this UTC day in sports and esports markets, buys and sells: each fill's size times its price, fees excluded, the measure of Polymarket user-volume `volume_usdc`, summed from the fills 0xinsider stores for it. A day stored before 2026-10-27 counts the cash each fill moved, fee included, until it is recomputed. Not Polymarket's share count, and not the full-history stats.total_volume on GET /api/v1/trader/{address}, which covers every market. Omitted on a day with realized P&L and no stored sports or esports fill, and, with markets_traded, on a day above 20 times the wallet's median day. */
3484
3640
  total_volume?: number;
3641
+ /** Running sum of daily_change through this day. */
3485
3642
  cumulative_profit?: number;
3643
+ /** The same running sum as cumulative_profit. */
3486
3644
  total_pnl?: number;
3645
+ /** Realized P&L of the wallet's sports and esports markets dated to this UTC day: a settled market on its resolution day, else its last trade day; an open market's realized part on its last trade day. 0 on a day with volume and nothing realized. */
3487
3646
  daily_change: number;
3488
- }[];
3647
+ })[];
3489
3648
  /** Pre-derived period stats. Present unless the request's `sections` excluded it. Always the published all/90d/30d/7d windows over the full stored history; `from`/`to` never recompute them over the request's range. */
3490
3649
  stats?: {
3491
3650
  all: {
@@ -3542,12 +3701,13 @@ export type TraderPnl = {
3542
3701
  };
3543
3702
  };
3544
3703
  /** Per-month P&L aggregation. Present unless the request's `sections` excluded it. Whole months over the full stored history, never clipped to `from`/`to`, so a month is never a partial month. */
3545
- monthly?: {
3704
+ monthly?: ({
3546
3705
  year: number;
3547
3706
  month: number;
3548
3707
  pnl: number;
3549
- markets_traded: number;
3550
- }[];
3708
+ /** The month's entries[].markets_traded summed: a market traded on several days counts once a day. null when a day of the month has total_volume and no markets_traded, a day whose stored fills include a market outside sports and esports, where a sum would undercount. A day with no stored fill, or above 20 times the wallet's median day, adds 0. */
3709
+ markets_traded: number | null;
3710
+ })[];
3551
3711
  /** Per-year P&L totals (ascending by year). Present unless the request's `sections` excluded it. Whole years over the full stored history, never clipped to `from`/`to`. */
3552
3712
  year_totals?: {
3553
3713
  year: number;
@@ -3560,34 +3720,34 @@ export type TraderPnl = {
3560
3720
  drawdown: number;
3561
3721
  }[];
3562
3722
  };
3563
- /** Lossless counterparts for trader P&L values. The object is omitted when no trusted native realized-P&L snapshot is available. */
3723
+ /** Deprecated since 2026-10-27 and never sent: pnl.exact held the lossless counterpart of the retired wallet-wide pnl.realized (#29830). The member shape below is what the object held before; it is kept so existing type declarations still compile. */
3564
3724
  export type TraderPnlExact = {
3565
3725
  /** Native Polymarket realized P&L plus credited maker and taker rebates, with fees included, from the trusted matching `trader_trading_pnl.net_realized_pnl` snapshot. */
3566
3726
  realized: ExactDecimal;
3567
3727
  };
3568
- /** A wallet's sports and esports record (#27311): Polymarket's published realized P&L (pnl.realized plus any published pnl.correction) split into the part earned on sports and esports markets. Fees, refunds and rebates stay in, apportioned by cost. A wallet wholly in sports keeps the published figure exactly; one with no sports market gets 0. Refreshed after each wallet sync; as_of dates it. */
3728
+ /** A wallet's sports and esports record (#27311). basis names the rule behind realized_pnl (#29370): polymarket_sports_esports_v1 is Polymarket's own realized P&L for the wallet in its sports and esports categories, plus the wallet's maker and taker rebates apportioned by its sports and esports share of its Polymarket volume (by cost while Polymarket reports no overall volume) and the in-scope part of any published neg-risk conversion correction; sports_esports_split_v1, used until both of the wallet's category figures are confirmed, is Polymarket's published wallet-wide realized P&L (with any published correction) split into the part earned on sports and esports markets, with fees, refunds and rebates apportioned by cost. Refreshed after each wallet sync and each read of Polymarket's category leaderboards; as_of dates the market counts. */
3569
3729
  export type TraderPnlInScope = {
3570
- /** Names the split rule, currently sports_esports_split_v1. A new value means the rule changed; compare figures only within one basis. */
3730
+ /** The rule behind realized_pnl: polymarket_sports_esports_v1 (Polymarket's sports and esports category figures plus apportioned rebates) or sports_esports_split_v1 (the published realized figure split by cost). A new value means the rule changed; compare figures only within one basis. */
3571
3731
  basis: string;
3572
- /** Sports and esports realized P&L in USD, display-safe. null when the wallet has no published realized figure to split. */
3732
+ /** Sports and esports realized P&L in USD, display-safe. null when the split basis has no published realized figure to split. */
3573
3733
  realized_pnl: number | null;
3574
3734
  /** Sports and esports markets the wallet has traded, any status. */
3575
3735
  markets: number;
3576
- /** Of those, the markets that have resolved. */
3736
+ /** Of those, the settled markets: the wallet closed its position by selling out, or the market resolved. Its P&L there is final. */
3577
3737
  markets_resolved: number;
3578
3738
  /** Share of decided sports and esports markets the wallet won, 0 to 1. null with no decided market. */
3579
3739
  win_rate: number | null;
3580
- /** The wallet's markets outside sports and esports, which 0xinsider no longer lists. */
3740
+ /** The wallet's markets outside sports and esports, which 0xinsider no longer lists: those it still stores, those whose rows it deleted and counted, and those of other categories first traded since 2026-10-26, which it does not store and counts as the wallet syncs (#30165). */
3581
3741
  markets_out_of_scope: number;
3582
3742
  /** When the record behind these figures was computed. */
3583
3743
  as_of: string;
3584
3744
  };
3585
- /** Lossless counterparts for trader statistics. The object is omitted when the verified provider observation is unavailable. */
3745
+ /** Lossless counterparts for trader statistics. The object is present exactly when stats.total_volume is. */
3586
3746
  export type TraderStatsExact = {
3587
- /** stats.total_volume as an exact decimal: full-history both-sides cash volume in USD, Polymarket user-volume `volume_usdc`, from the verified `trader_usd_volume` observation. Never Polymarket's share count. */
3747
+ /** stats.total_volume as an exact decimal: the sports and esports USD volume, the sum of every stored trade day's `trader_trade_daily_rollups.in_scope_volume_total` (#29830). Polymarket's full-history wallet-wide user volume before 2026-10-27. */
3588
3748
  total_volume: ExactDecimal;
3589
3749
  };
3590
- /** `trader_synced` data: a tracked wallet finished a sync pass and has a fresh grade. The deprecated spelling `whale_trader_synced` delivers the same object. */
3750
+ /** `trader_synced` data: a tracked wallet finished a sync pass and has a fresh grade. The deprecated spelling `whale_trader_synced` delivers the same object until its sunset on 2027-02-01 (#29352). */
3591
3751
  export type TraderSyncedData = {
3592
3752
  /** 0xinsider's numeric id for the wallet. */
3593
3753
  trader_id: number;
@@ -3596,15 +3756,25 @@ export type TraderSyncedData = {
3596
3756
  };
3597
3757
  /** Field-level trust metadata returned only when GET /api/v1/trader/{address} includes expand=trust. */
3598
3758
  export type TraderTrust = {
3759
+ /** Since 2026-10-27 always not_computed: pnl.total is retired and never sent (#29830). The key stays so the object keeps its shape. */
3599
3760
  total_pnl: TrustMetadata;
3761
+ /** Since 2026-10-27 always not_computed: pnl.realized and pnl.exact are retired and never sent (#29830). The key stays so the object keeps its shape. */
3600
3762
  realized_pnl: TrustMetadata;
3763
+ /** Since 2026-10-27 always not_computed: pnl.net_total is retired and never sent (#29830). The key stays so the object keeps its shape. */
3601
3764
  net_total_pnl: TrustMetadata;
3602
- /** Present only with pnl.correction: a computed value owned by trader_pnl_corrections, dated by the newest measurement behind it. */
3765
+ /**
3766
+ * Deprecated since 2026-10-27 and never sent: it was present only with pnl.correction, which is retired (#29830).
3767
+ * @deprecated
3768
+ */
3603
3769
  pnl_correction?: TrustMetadata;
3604
3770
  unrealized_pnl: TrustMetadata;
3771
+ /** Computed, owned by trader_product_scope_records (markets) and dated by the record's computed_at, since 2026-10-27 (#29830). For a wallet that traded no sports or esports market, which never gets a record, owned by traders (last_synced), the completed sync that found none, and dated by it, since 2026-10-29 (#30589, #30657; owned by traders (markets_traded) until #30657). */
3605
3772
  markets_traded: TrustMetadata;
3773
+ /** Computed, owned by trader_product_scope_records (win_rate) and dated by the record's computed_at, since 2026-10-27 (#29830). */
3606
3774
  win_rate: TrustMetadata;
3775
+ /** Since 2026-10-27 always not_computed: stats.daily_win_rate is retired and never sent (#29830). The key stays so the object keeps its shape. */
3607
3776
  daily_win_rate: TrustMetadata;
3777
+ /** Computed, owned by trader_trade_daily_rollups (in_scope_volume_total) and dated by traders.last_synced, since 2026-10-27 (#29830). */
3608
3778
  total_volume: TrustMetadata;
3609
3779
  grade: TrustMetadata;
3610
3780
  score: TrustMetadata;
@@ -3641,21 +3811,31 @@ export type TrendingWallet = {
3641
3811
  window_markets_traded: number;
3642
3812
  /** Distinct in-window UTC trade days from our trades (0 if the winner is not in our DB). */
3643
3813
  window_trade_days: number;
3644
- /** All-time trader grade; a separate axis from streak_tier. Led by realized profit (the money actually banked, about 95 percent of the grade), with forecasting calibration, risk-adjusted returns, and consistency as the tie-breaker and proven-trader guardrails: any grade above C requires verified net-positive realized profit, and the top grades also require a real resolved-market track record plus a survivable drawdown. Relative, so it drifts as the cohort moves. Omitted when the trader is Unranked (fewer than 5 markets, or too little verified record to cohort-rank). */
3814
+ /** All-time trader grade; a separate axis from streak_tier. Led by realized profit on sports and esports markets (the money actually banked, about 95 percent of the grade; since 2026-10-22, the sports and esports share of the wallet's realized P&L), with forecasting calibration, risk-adjusted returns, and consistency as the tie-breaker and proven-trader guardrails: any grade above C requires verified net-positive realized profit on those markets, and the top grades also require a real track record of resolved sports and esports markets plus a survivable drawdown. Relative, so it drifts as the cohort moves. Omitted when the trader is Unranked (fewer than 5 markets, or too little verified record to cohort-rank). */
3645
3815
  grade?: "S" | "A" | "B" | "C" | "D" | "F";
3646
3816
  /** Hot-streak tier (trailing-7d cross-sectional percentile). Omitted when there is no recent activity. */
3647
3817
  streak_tier?: "hot" | "rising" | "neutral" | "cooling" | "cold";
3648
- /** Polymarket's net total P&L for the wallet in USD: native Polymarket position P&L across all markets, fees included, plus credited maker and taker rebates (trader_trading_pnl.net_total_pnl). The 0xinsider profile's Total P&L is this figure unless pnl_correction is present, then pnl_correction.net_total. Context only: it does not affect the ranking, which follows trending_pnl_usd. Omitted when the wallet is not in the 0xinsider database or has no native accounting snapshot; the Polymarket leaderboard all-time figure is never substituted. */
3818
+ /** Additive (#29971): the wallet's sports and esports realized P&L in USD, the same figure as pnl.in_scope.realized_pnl on GET /api/v1/trader/{address} and the 0xinsider profile's Sports P&L, as of the board's last rebuild. Context only: it does not affect the ranking, which follows trending_pnl_usd. Omitted when the wallet is not in the 0xinsider database or has no sports and esports record yet: absent means not computed, never zero. */
3819
+ in_scope_realized_pnl?: number;
3820
+ /**
3821
+ * Deprecated since 2026-10-27 and never sent. It was Polymarket's net total P&L over every Polymarket market of the wallet, and wallet figures cover sports and esports markets only (#29971). Read in_scope_realized_pnl.
3822
+ * @deprecated
3823
+ */
3649
3824
  all_time_pnl_usd?: number;
3650
- /** The 0xinsider correction to Polymarket's P&L for neg-risk conversions. Present only when one is published; all_time_pnl_usd keeps Polymarket's own figure and pnl_correction.net_total is the profile's Total P&L. */
3825
+ /**
3826
+ * Deprecated since 2026-10-27 and never sent. It was the neg-risk conversion correction to the wallet-wide all_time_pnl_usd (#29971). Its sports and esports part is inside in_scope_realized_pnl.
3827
+ * @deprecated
3828
+ */
3651
3829
  pnl_correction?: PnlCorrection;
3652
3830
  all_time_score?: number;
3653
3831
  last_synced?: string;
3654
- /** Shape-only daily P&L sparkline across the window, derived from Polymarket's documented user-pnl cumulative curve (GET /v2/user-pnl) converted to per-day deltas. It conveys the trend of the curve only and is NOT guaranteed to sum to trending_pnl_usd, which is the canonical leaderboard total. */
3832
+ /** The wallet's sports and esports realized P&L on each UTC day of the window, ascending, one point a day, pnl_usd 0 on a day with none: the same in-scope realized day series the trader P&L endpoint serves. Empty while daily_pnl_series_status is pending, which never means zero. It leaves out non-sports markets, so it does not sum to trending_pnl_usd, which is Polymarket's leaderboard figure across all markets. */
3655
3833
  daily_pnl_series: {
3656
3834
  date: string;
3657
3835
  pnl_usd: number;
3658
3836
  }[];
3837
+ /** `ready` when daily_pnl_series is served; an all-zero one is a wallet with no sports or esports P&L in the window. `pending` when the wallet's sports and esports record does not carry its daily series yet, or the wallet is not in the 0xinsider database: daily_pnl_series is empty and never means zero. Retry later. */
3838
+ daily_pnl_series_status: "ready" | "pending";
3659
3839
  };
3660
3840
  /** Whether the described value or result set is complete for its stated contract. */
3661
3841
  export type TrustCompleteness = {
@@ -3802,7 +3982,7 @@ export type WebhookEndpoint = {
3802
3982
  signing_secret?: string;
3803
3983
  verification?: WebhookVerification;
3804
3984
  };
3805
- /** Self-describing entry in the webhook event catalog: the event type a subscriber lists in event_types, when it fires, the data payload shape, and whether it currently fires (active) or is reserved (dormant, subscribable but not yet delivered). Pro-only event types (large_trades_inserted, whale_trades_inserted, wallet_grade_changed, suspicious_trade_flagged, insider_radar_flag_raised, sharp_money_flow_detected, smart_money_flow_detected) only deliver to API keys on an active Pro subscription. Export lifecycle event types (export_job_ready, export_job_failed, export_job_expired, export_job_cancelled) are owner-scoped to the API-key account that created the export and contain no download URL; use the authorized export status/download routes. Some entries are two spellings of one event: large_trades_inserted and whale_trades_inserted, trader_synced and whale_trader_synced, suspicious_trade_flagged and insider_radar_flag_raised, sharp_money_flow_detected and smart_money_flow_detected. Either spelling subscribes, and an endpoint receives deliveries under the spelling it registered. */
3985
+ /** Self-describing entry in the webhook event catalog: the event type a subscriber lists in event_types, when it fires, the data payload shape, and whether it currently fires (active) or is reserved (dormant, subscribable but not yet delivered). Pro-only event types (large_trades_inserted, whale_trades_inserted, wallet_grade_changed, suspicious_trade_flagged, insider_radar_flag_raised, sharp_money_flow_detected, smart_money_flow_detected) only deliver to API keys on an active Pro subscription. Export lifecycle event types (export_job_ready, export_job_failed, export_job_expired, export_job_cancelled) are owner-scoped to the API-key account that created the export and contain no download URL; use the authorized export status/download routes. Some entries are two spellings of one event: large_trades_inserted and whale_trades_inserted, trader_synced and whale_trader_synced, suspicious_trade_flagged and insider_radar_flag_raised, sharp_money_flow_detected and smart_money_flow_detected. Either spelling subscribes, and an endpoint receives deliveries under the spelling it registered. The deprecated spellings (whale_trades_inserted, whale_trader_synced, insider_radar_flag_raised, smart_money_flow_detected) reach their sunset on 2027-02-01 (#29352); register the canonical spelling. */
3806
3986
  export type WebhookEventDescriptor = {
3807
3987
  id: WebhookEventType;
3808
3988
  /** One-line description of when the event fires. */
@@ -3913,7 +4093,7 @@ export type WhaleDatasetJob = {
3913
4093
  object: "whale_dataset_job";
3914
4094
  data: {
3915
4095
  job_id: number;
3916
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4096
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
3917
4097
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
3918
4098
  format: "ndjson";
3919
4099
  total_trades: number | null;
@@ -3942,7 +4122,7 @@ export type WhaleDatasetJob = {
3942
4122
  cancel_requested_at: string | null;
3943
4123
  /** When the job reached cancelled; null until then. */
3944
4124
  cancelled_at: string | null;
3945
- /** Worker claims so far. */
4125
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
3946
4126
  attempt: number;
3947
4127
  /** The job fails when attempt reaches this. */
3948
4128
  max_attempts: number;
@@ -4020,7 +4200,7 @@ export interface OperationData {
4020
4200
  batchGetTraders: BatchTraderItem[];
4021
4201
  cancelTraderExport: {
4022
4202
  job_id: number;
4023
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4203
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4024
4204
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4025
4205
  format: "json" | "ndjson" | "csv";
4026
4206
  /** Trade rows the file holds: trades in the wallet's sports and esports markets, counted in the file's own read snapshot. Null until the worker has read the snapshot (queued, and early in running); a job accepted before 2026-10-22 can carry the earlier all-markets estimate until its file is read. */
@@ -4051,7 +4231,7 @@ export interface OperationData {
4051
4231
  cancel_requested_at: string | null;
4052
4232
  /** When the job reached cancelled; null until then. */
4053
4233
  cancelled_at: string | null;
4054
- /** Worker claims so far. */
4234
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4055
4235
  attempt: number;
4056
4236
  /** The job fails when attempt reaches this. */
4057
4237
  max_attempts: number;
@@ -4071,7 +4251,7 @@ export interface OperationData {
4071
4251
  };
4072
4252
  cancelWhaleDataset: {
4073
4253
  job_id: number;
4074
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4254
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4075
4255
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4076
4256
  format: "ndjson";
4077
4257
  total_trades: number | null;
@@ -4100,7 +4280,7 @@ export interface OperationData {
4100
4280
  cancel_requested_at: string | null;
4101
4281
  /** When the job reached cancelled; null until then. */
4102
4282
  cancelled_at: string | null;
4103
- /** Worker claims so far. */
4283
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4104
4284
  attempt: number;
4105
4285
  /** The job fails when attempt reaches this. */
4106
4286
  max_attempts: number;
@@ -4137,7 +4317,8 @@ export interface OperationData {
4137
4317
  getAccountIdentity: {
4138
4318
  user_id: number;
4139
4319
  credential_id: number;
4140
- credential_kind: "api_key" | "oauth_grant";
4320
+ /** The kind of credential that made the request: api_key is a full-access developer key, oauth_grant an OAuth access token, integration_key a named integration key with fixed scopes created on https://0xinsider.com/developers. Before integration_key was added, these keys reported oauth_grant. */
4321
+ credential_kind: "api_key" | "oauth_grant" | "integration_key";
4141
4322
  /** The credential is currently valid; revoked, expired or unknown credentials are rejected. */
4142
4323
  credential_status: "active";
4143
4324
  entitlement: {
@@ -4145,7 +4326,7 @@ export interface OperationData {
4145
4326
  /** When paid data access is lapsed, the caller should renew the subscription; otherwise null. */
4146
4327
  recovery_action: "renew_subscription" | null;
4147
4328
  };
4148
- /** Approved OAuth scopes; null for full developer-key access. */
4329
+ /** The scopes an OAuth grant or integration key carries; null for full developer-key access. */
4149
4330
  scopes: string[] | null;
4150
4331
  };
4151
4332
  getApiDiscovery: ApiDiscovery;
@@ -4204,7 +4385,7 @@ export interface OperationData {
4204
4385
  getTraderExportSnapshot: TraderExportSnapshot;
4205
4386
  getTraderExportStatus: {
4206
4387
  job_id: number;
4207
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4388
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4208
4389
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4209
4390
  format: "json" | "ndjson" | "csv";
4210
4391
  /** Trade rows the file holds: trades in the wallet's sports and esports markets, counted in the file's own read snapshot. Null until the worker has read the snapshot (queued, and early in running); a job accepted before 2026-10-22 can carry the earlier all-markets estimate until its file is read. */
@@ -4235,7 +4416,7 @@ export interface OperationData {
4235
4416
  cancel_requested_at: string | null;
4236
4417
  /** When the job reached cancelled; null until then. */
4237
4418
  cancelled_at: string | null;
4238
- /** Worker claims so far. */
4419
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4239
4420
  attempt: number;
4240
4421
  /** The job fails when attempt reaches this. */
4241
4422
  max_attempts: number;
@@ -4298,7 +4479,7 @@ export interface OperationData {
4298
4479
  getWeeklyReportSnapshot: ReportSnapshot;
4299
4480
  getWhaleDatasetStatus: {
4300
4481
  job_id: number;
4301
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4482
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4302
4483
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4303
4484
  format: "ndjson";
4304
4485
  total_trades: number | null;
@@ -4327,7 +4508,7 @@ export interface OperationData {
4327
4508
  cancel_requested_at: string | null;
4328
4509
  /** When the job reached cancelled; null until then. */
4329
4510
  cancelled_at: string | null;
4330
- /** Worker claims so far. */
4511
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4331
4512
  attempt: number;
4332
4513
  /** The job fails when attempt reaches this. */
4333
4514
  max_attempts: number;
@@ -4377,7 +4558,7 @@ export interface OperationData {
4377
4558
  searchMarkets: MarketSearchResult[];
4378
4559
  submitTraderExport: {
4379
4560
  job_id: number;
4380
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4561
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4381
4562
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4382
4563
  format: "json" | "ndjson" | "csv";
4383
4564
  /** Trade rows the file holds: trades in the wallet's sports and esports markets, counted in the file's own read snapshot. Null until the worker has read the snapshot (queued, and early in running); a job accepted before 2026-10-22 can carry the earlier all-markets estimate until its file is read. */
@@ -4408,7 +4589,7 @@ export interface OperationData {
4408
4589
  cancel_requested_at: string | null;
4409
4590
  /** When the job reached cancelled; null until then. */
4410
4591
  cancelled_at: string | null;
4411
- /** Worker claims so far. */
4592
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4412
4593
  attempt: number;
4413
4594
  /** The job fails when attempt reaches this. */
4414
4595
  max_attempts: number;
@@ -4428,7 +4609,7 @@ export interface OperationData {
4428
4609
  };
4429
4610
  submitWhaleDataset: {
4430
4611
  job_id: number;
4431
- /** queued: accepted, not started. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the hourly reconciler reads the object back and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4612
+ /** queued: waiting for a worker. A running job reads queued again, with error saying why, when its worker restarts for a deploy (the next worker claims it within seconds) or stops without handing it back (requeued within a minute of its 30-minute lease lapsing); it starts again from the beginning. running: the worker is streaming rows. reconcile_required: the upload finished but the storage completion answer was lost; the reconciler reads the object back within a minute, retries a failed readback an hour later, and moves the job to ready or failed, and expires_at bounds the wait. ready: downloadable until expires_at. failed: terminal; error says why; submit a new export. expired: the retention window passed; the file is retired, the download route answers 410, submit a new export. cancel_requested: the owner cancelled a running job (POST /api/v1/trader/{address}/export/cancel); the worker stops at its next safe point and the job reads cancelled. cancelled: terminal; the owner cancelled the job and no file was published; submit a new export. A job that has not reached ready by expires_at reads failed with error 'export expired before completion'. failed, cancelled and expired rows stay readable for 48 hours, then the job answers 404. */
4432
4613
  status: "queued" | "running" | "ready" | "failed" | "reconcile_required" | "expired" | "cancel_requested" | "cancelled";
4433
4614
  format: "ndjson";
4434
4615
  total_trades: number | null;
@@ -4457,7 +4638,7 @@ export interface OperationData {
4457
4638
  cancel_requested_at: string | null;
4458
4639
  /** When the job reached cancelled; null until then. */
4459
4640
  cancelled_at: string | null;
4460
- /** Worker claims so far. */
4641
+ /** Worker claims so far. A claim handed back when its worker restarts for a deploy is not counted, so attempt steps back by one when the job reads queued again for that reason. */
4461
4642
  attempt: number;
4462
4643
  /** The job fails when attempt reaches this. */
4463
4644
  max_attempts: number;
@@ -4501,7 +4682,7 @@ export interface OperationQuery {
4501
4682
  status?: "active" | "closed" | "all";
4502
4683
  /** Filter by source platform. Explore is Polymarket-only; polymarket is the only supported value and the parameter is accepted for backward-compatibility but does not change the result set. */
4503
4684
  platform?: "polymarket";
4504
- /** Sort order for the discovery feed. `large_trades` ranks by large-trade activity; `whales` is its deprecated spelling and selects the same order. */
4685
+ /** Sort order for the discovery feed. `large_trades` ranks by large-trade activity; `whales` is its deprecated spelling and selects the same order until its sunset on 2027-02-01 (#29352); from then it answers 400 bad_request. */
4505
4686
  sort?: "trending" | "hot" | "expiring" | "large_trades" | "whales" | "volume" | "newest";
4506
4687
  /** Opaque pagination cursor from the previous response. */
4507
4688
  cursor?: string;
@@ -4524,9 +4705,9 @@ export interface OperationQuery {
4524
4705
  view?: "board" | "signals" | "observations";
4525
4706
  /** Legacy canonical bucket alias, now accepted in every view. Provider aliases canonicalize: NFL reaches Football and EPL reaches Soccer. Use leagues for a league-specific selection. An unmappable non-sport category returns an empty result and echoes category non_sport. Combines with other selection axes using AND. */
4526
4707
  category?: string;
4527
- /** Required for view=observations; wider_holder, in_play or emerging_pile. Rejected for board and signals. wider_holder covers pregame markets outside the funded slate. A market that enters the slate leaves wider_holder; view=signals lists it only while its holder pile leans to one side, its backed side has a holder at or above min_grade and its kickoff is within horizon_hours, and otherwise neither view lists it. Each refresh evaluates at most 8 markets per sport and cohort, wider_holder by soonest kickoff (most graded holders first among equal kickoffs) and in_play by most graded holders, so a market among a sport's 8 soonest stays evaluated until its game starts. wider_holder also evaluates up to 8 more markets per sport that kick off within 24 hours, most graded holders first, so the most-held markets appear up to a day before kickoff. Each of these keeps its place in later refreshes until its game starts while its holder page still shows a card or could not be read, so a more-held market waits for a free place instead of displacing it. Each row's admitted_by names its place, most_held or soonest_kickoff. The rest count in coverage.capacity_limited_markets. Emerging pile is a wider-holder projection with sharp_pct in [0.75,0.85), complete holder scans and future kickoff, not an independent population or arrival history. */
4708
+ /** Required for view=observations; wider_holder, in_play or emerging_pile. Rejected for board and signals. wider_holder covers pregame markets that view=signals does not list at its widest selection (horizon_hours=48, min_grade=B, no selector), so until kickoff a market is read in one view or the other. A market view=signals lists leaves wider_holder as primary_slate_candidate, and is a wider_holder candidate again in the first refresh after view=signals stops listing it; signals_as_of names the view=signals snapshot each refresh read. Each refresh evaluates at most 8 markets per sport and cohort, wider_holder by soonest kickoff (most graded holders first among equal kickoffs) and in_play by most graded holders, so a market among a sport's 8 soonest stays evaluated until its game starts. wider_holder also evaluates up to 8 more markets per sport that kick off within 24 hours, most graded holders first, so the most-held markets appear up to a day before kickoff. Each of these keeps its place in later refreshes until its game starts while its holder page still shows a card or could not be read, so a more-held market waits for a free place instead of displacing it. Each row's admitted_by names its place, most_held or soonest_kickoff. The rest count in coverage.capacity_limited_markets. Emerging pile is a wider-holder projection with sharp_pct in [0.75,0.85), complete holder scans and future kickoff, not an independent population or arrival history. */
4528
4709
  cohort?: "wider_holder" | "in_play" | "emerging_pile";
4529
- /** Opt-in admission rule for view=observations with cohort=wider_holder; rejected for every other view and cohort. most_held_48h returns the most-held selection instead of the default one: per sport, up to 8 wider_holder markets kicking off within 48 hours, most graded holders first, then most volume, then soonest kickoff, at most 4 per event. It is recomputed every refresh and keeps no place, so a more-held market displaces a less-held one; funded-slate markets stay excluded. Every row carries admitted_by most_held_48h, including a market the default selection also evaluates, and the response echoes admission. funnel, coverage, degraded and degradation_reasons describe this selection: a wider_holder candidate it did not take counts as capacity_limited. Its markets that no default place covers are read after every default market, at most once per 10 minutes, so a row can rest on a holder page up to 15 minutes old (holder_snapshot_at). Omit for the default selection. Cursors and ETags bind it. */
4710
+ /** Opt-in admission rule for view=observations with cohort=wider_holder; rejected for every other view and cohort. most_held_48h returns the most-held selection instead of the default one: per sport, up to 8 wider_holder markets kicking off within 48 hours, most graded holders first, then most volume, then soonest kickoff, at most 4 per event. It is recomputed every refresh and keeps no place, so a more-held market displaces a less-held one; markets view=signals lists stay excluded. Every row carries admitted_by most_held_48h, including a market the default selection also evaluates, and the response echoes admission. funnel, coverage, degraded and degradation_reasons describe this selection: a wider_holder candidate it did not take counts as capacity_limited. Its markets that no default place covers are read after every default market, at most once per 10 minutes, so a row can rest on a holder page up to 15 minutes old (holder_snapshot_at). Omit for the default selection. Cursors and ETags bind it. */
4530
4711
  admission?: "most_held_48h";
4531
4712
  /** Board and signals: S, A or B, default B. Requires a piled-side holder at the selected grade floor or better, without removing other holders. Rejected for observations. */
4532
4713
  min_grade?: "S" | "A" | "B";
@@ -4593,7 +4774,7 @@ export interface OperationQuery {
4593
4774
  min_grade?: "S" | "A" | "B";
4594
4775
  /** Maximum holders per page. Out-of-range values are clamped to 1..100. */
4595
4776
  limit?: number;
4596
- /** Opaque pagination cursor from the previous response's next_cursor. New cursors carry an absolute next offset bound to normalized condition_id, outcome and effective min_grade, so limit can change without skipping or repeating rows on the same roster. Different market/filter bindings return 400 bad_request with param=cursor; omitted filters match all/B and mkt_-prefixed IDs match their raw condition_id. Legacy page-only cursors remain accepted without scheduled retirement and require their original limit; their next response emits the new format. A cursor remains valid across roster refreshes, which can still repeat or skip holders as the live roster changes. */
4777
+ /** Opaque pagination cursor from the previous response's next_cursor. New cursors carry an absolute next offset bound to normalized condition_id, outcome and effective min_grade, so limit can change without skipping or repeating rows on the same roster. Different market/filter bindings return 400 bad_request with param=cursor; omitted filters match all/B and mkt_-prefixed IDs match their raw condition_id. Page-only cursors from before 2026-10-02 are no longer accepted and return 400 bad_request with param=cursor; restart without a cursor. A cursor remains valid across roster refreshes, which can still repeat or skip holders as the live roster changes. */
4597
4778
  cursor?: string;
4598
4779
  };
4599
4780
  getMarketIntel: {
@@ -4655,9 +4836,9 @@ export interface OperationQuery {
4655
4836
  };
4656
4837
  getSuspiciousTrade: Record<string, never>;
4657
4838
  getTrader: {
4658
- /** Backward-compatible alias for expand. Repeatable: strategy, categories, quant_metrics, trust. */
4839
+ /** Backward-compatible alias for expand. Repeatable: strategy, categories, trust. quant_metrics is accepted and returns nothing since 2026-10-27. */
4659
4840
  "expand[]"?: ("strategy" | "categories" | "quant_metrics" | "trust")[];
4660
- /** Include heavy fields and trust metadata. Repeatable: strategy, categories, quant_metrics, trust. */
4841
+ /** Include heavy fields and trust metadata. Repeatable: strategy, categories, trust. quant_metrics is accepted and returns nothing since 2026-10-27. */
4661
4842
  expand?: ("strategy" | "categories" | "quant_metrics" | "trust")[];
4662
4843
  /** Opt into a whole-response freshness ceiling in seconds. The server returns 200 only when data_quality.status is fresh and data_quality.as_of is no older than this value; otherwise it returns 409 with error.reason=freshness_ceiling_unsatisfied. No refresh or alternate read is attempted. */
4663
4844
  max_age_s?: number;
@@ -4761,7 +4942,7 @@ export interface OperationQuery {
4761
4942
  min_size?: number;
4762
4943
  /** One RFC 4180 CSV record of exact current provider-backed market_canonical.category values. Legacy unquoted lists such as NBA,WNBA remain valid; values containing commas, quotes, or newlines are CSV-quoted. Matching is case-insensitive. Malformed quoted input fails closed as one unknown exact category. A value outside sports and esports returns 400 bad_request with param=category (#27305), as on GET /api/v1/markets/explore. */
4763
4944
  category?: string;
4764
- /** Minimum trader grade. */
4945
+ /** Minimum trader grade. Matched against the trader.grade each row returns, the wallet's current grade, so every row listed shows a grade at or above this floor. */
4765
4946
  min_grade?: "S" | "A" | "B" | "C" | "D" | "F";
4766
4947
  /** Scope to one market. Accepts the raw provider condition_id or the mkt_-prefixed market id (round-trips a value from a list response). Must be 0x followed by 64 hexadecimal characters after any mkt_ prefix is stripped; any other value returns 400. Polymarket-only; an unknown but well-formed id returns []. A market outside sports and esports returns 404 not_found with error.reason=market_out_of_scope (#27305). */
4767
4948
  condition_id?: string;
@@ -4837,8 +5018,8 @@ export interface OperationQuery {
4837
5018
  cursor?: string;
4838
5019
  /** Filter by category: a sport or esports bucket. Values are matched to canonical category buckets: league values fold into their sport (NBA and NCAAB into Basketball, NFL into Football). Mapped buckets are case-insensitive; passthrough buckets (Cricket, Sports) match case-sensitively against the provider-native bucket key, so use exact casing. Sports and esports only (#27306): a category outside them returns 400 bad_request with param category and names the accepted buckets. */
4839
5020
  category?: string;
4840
- /** Filter by observed trading style. Current styles: two_sided, category_focused, high_activity, diversified, mixed, unclassified. Current styles count the wallet's sports and esports markets only. The original ten archetype identifiers remain accepted for historical rows until normal reclassification. Style describes recorded behavior; grade measures performance. */
4841
- strategy?: "accumulator" | "algo_trader" | "arbitrageur" | "category_focused" | "directional" | "diversified" | "event_driven" | "high_activity" | "market_maker" | "mixed" | "momentum" | "scalper" | "speculator" | "swing_trader" | "two_sided" | "unclassified";
5021
+ /** Filter by observed trading style. Current styles: two_sided, category_focused, high_activity, diversified, mixed, unclassified. Current styles count the wallet's sports and esports markets only. The ten archetype keys retired on 2026-10-01 (accumulator, algo_trader, arbitrageur, directional, event_driven, market_maker, momentum, scalper, speculator, swing_trader) are still accepted and match no wallet. Style describes recorded behavior; grade measures performance. */
5022
+ strategy?: "category_focused" | "diversified" | "high_activity" | "mixed" | "two_sided" | "unclassified";
4842
5023
  };
4843
5024
  listPositions: {
4844
5025
  /** Maximum number of current positions to return. Out-of-range values are clamped to 1..100. */
@@ -5271,10 +5452,10 @@ export interface OperationBody {
5271
5452
  createMcpJsonRpcResponse: {
5272
5453
  /** JSON-RPC protocol version; this server accepts 2.0. */
5273
5454
  jsonrpc: "2.0";
5274
- /** Request identifier echoed exactly in one JSON-RPC response; supported notifications omit it and receive an empty HTTP 202. */
5275
- id?: string | number | null;
5455
+ /** Request identifier, a string or a number, echoed exactly in one JSON-RPC response; a notification omits it and receives an empty HTTP 202. A null id answers HTTP 400 with JSON-RPC error -32600. */
5456
+ id?: string | number;
5276
5457
  /** MCP method to invoke. */
5277
- method: "initialize" | "notifications/initialized" | "notifications/cancelled" | "ping" | "tools/list" | "tools/call";
5458
+ method: "initialize" | "notifications/initialized" | "notifications/cancelled" | "ping" | "tools/list" | "tools/call" | "server/discover";
5278
5459
  /** Method-specific MCP parameters. */
5279
5460
  params?: Record<string, unknown>;
5280
5461
  };