@0xinsider/sdk 0.20.0 → 0.21.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.
package/dist/schema.d.ts CHANGED
@@ -83,15 +83,15 @@ export type ApiError = {
83
83
  };
84
84
  export type ApiErrorBody = {
85
85
  /** FROZEN: an existing value never changes meaning. request_timeout (408, #16146) was added the way insufficient_scope was: the handler did not answer inside the server's 30-second timeout. Retry-After and retry_at ride on it only for a safe method (GET, HEAD); a timed-out mutation may have completed, so check its state and reuse its Idempotency-Key. */
86
- code: "bad_request" | "invalid_api_key" | "subscription_required" | "forbidden" | "insufficient_scope" | "not_found" | "account_locked" | "rate_limited" | "rate_limit_unavailable" | "internal_error" | "request_timeout";
86
+ code: "bad_request" | "invalid_api_key" | "subscription_required" | "forbidden" | "insufficient_scope" | "not_found" | "account_locked" | "rate_limited" | "rate_limit_unavailable" | "internal_error" | "request_timeout" | "endpoint_retired";
87
87
  message: string;
88
88
  doc_url?: string;
89
89
  param?: string;
90
90
  /** 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: before the 03:00 America/New_York operating-window start, before a selected pick's stored release, or after a skipped day, it names the automatic system's next boundary. While no candidate exists in the live window it normally names the persisted next automatic selector attempt. Every value is advisory and can change before release. When the automatic schedule is absent/due or a pick is overdue it degrades to ~60s. Schedule one request and do not poll. Prefer Retry-After for the duration because it is immune to client clock skew. */
91
91
  retry_at?: string;
92
92
  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. 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/sports/pre-game-sides, GET /api/v1/sports/pre-game-side-observations and their deprecated aliases); 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. */
94
- reason?: "cursor_expired" | "unknown_endpoint" | "pick_not_released" | "trader_not_tracked" | "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";
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. 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" | "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";
95
95
  };
96
96
  export type BatchMarketFlowItem = {
97
97
  /** Zero-based request index. Duplicate inputs keep separate result rows. */
@@ -488,6 +488,134 @@ export type EdgeHunterBoard = {
488
488
  total: number;
489
489
  rows: EdgeHunterRow[];
490
490
  };
491
+ export type EdgeHunterBoardResponse = {
492
+ object: "edge_hunter";
493
+ data: EdgeHunterBoard;
494
+ meta: ResponseMeta;
495
+ };
496
+ /** Category evidence over the full uncapped piled-side S/A/B holder allocation. It never changes signal membership, ordering, routing, or sizing. */
497
+ export type EdgeHunterCategorySkill = {
498
+ status: "live" | "insufficient" | "stale" | "unknown" | "degraded";
499
+ model_version: string;
500
+ taxonomy_version: string | null;
501
+ platform: "polymarket";
502
+ scope: "observed_goldsky_primary_taker_fill";
503
+ source_coverage: "partial_whale_threshold_fills" | "graded_wallet_fills";
504
+ observation_started_at: string;
505
+ as_of: string;
506
+ canonical_category: string | null;
507
+ eligible_holders: number;
508
+ covered_holders: number;
509
+ backed_sharp_usd: number | null;
510
+ covered_backed_usd: number | null;
511
+ coverage_pct: number | null;
512
+ weighted_edge_mean: number | null;
513
+ weighted_holder_lower_mean: number | null;
514
+ specialist_backed_usd: number | null;
515
+ specialist_backed_usd_pct: number | null;
516
+ largest_holder_backed_usd_pct: number | null;
517
+ minimum_holder_event_count: number | null;
518
+ };
519
+ /** Per-sport accountable funnel for the full observation snapshot, returned on every page. */
520
+ export type EdgeHunterFunnelReport = {
521
+ sports: EdgeHunterSportFunnelReport[];
522
+ };
523
+ /** One explicitly observation-only holder-pile measurement. It is evidence for cohort evaluation, not an execution instruction, and is isolated from the funded Edge Hunter signals view. */
524
+ export type EdgeHunterObservation = {
525
+ /** The side profitable wallets hold, as a provider-backed display label. Canonical spelling of piled_side (#16310), same value: when provider group context is unavailable it may remain a bare Yes/No/Over/Under, so do not use it alone as participant identity. */
526
+ side: string | null;
527
+ /** Recorded side backing score; higher values indicate stronger backing. */
528
+ backing_score: number;
529
+ /** Signed share of graded money on the side, in [-1, 1]. Canonical spelling of smart_score (#16309, #16310), same value. */
530
+ side_share: number;
531
+ /** Raw Polymarket condition id. */
532
+ condition_id: string;
533
+ /** Provider-backed Polymarket CLOB token id for the piled outcome. Rows without a verified token terminate before emission. */
534
+ token_id: string;
535
+ /** Canonical sport bucket. */
536
+ category: "Basketball" | "Football" | "Baseball" | "Hockey" | "MMA" | "Boxing" | "Soccer" | "Cricket" | "Golf" | "Tennis" | "Esports" | "Racing" | "Table Tennis" | "Pickleball";
537
+ /** Raw provider category as stored. */
538
+ raw_category: string | null;
539
+ /** Provider-backed market title. */
540
+ title: string;
541
+ event_slug: string | null;
542
+ /** Provider event id when available. */
543
+ event_id: string | null;
544
+ /** Provider parent-event id used as the first event-cap identity when available. */
545
+ parent_event_id: string | null;
546
+ /** Provider-backed kickoff time in UTC. */
547
+ game_start_time: string;
548
+ /** UTC instant when this row finished provider/holder evaluation. */
549
+ observed_at: string;
550
+ /** Source cohort or additive projection view. emerging_pile is projected from wider_holder after source computation, overlaps its funnel denominator, and uses the source row's directional evidence. */
551
+ cohort: "wider_holder" | "in_play" | "emerging_pile";
552
+ /** Always true. This row must not be routed to an order executor. */
553
+ observation_only: true;
554
+ /**
555
+ * Nullable provider-backed piled-outcome display label. When provider group context is unavailable, it may remain a bare Yes/No/Over/Under; do not use it alone as participant identity. Deprecated (#16310): `side` is the canonical spelling and carries the same value; this key stays on the wire.
556
+ * @deprecated
557
+ */
558
+ piled_side: string | null;
559
+ /** Provider binary-column selector: 0 selects outcome_yes/token_id_yes; 1 selects outcome_no/token_id_no. It does not identify home/away or a participant. Use piled_side together with title/event context for display. */
560
+ piled_outcome_index: 0 | 1;
561
+ /** Aggregate piled-side market midpoint recorded at observed_at. This is an observation price mark, not a wallet entry cost. */
562
+ backed_price: number;
563
+ /** Piled-side graded-holder dollar concentration. */
564
+ sharp_pct: number;
565
+ /** Raw graded-holder USD on the piled outcome. */
566
+ backed_sharp_usd: number;
567
+ s_count: number;
568
+ a_count: number;
569
+ b_count: number;
570
+ /** Piled-side S/A/B holder count. */
571
+ graded_holders: number;
572
+ top_grade: "S" | "A" | "B";
573
+ /**
574
+ * Canonical signed holder-pile score. Deprecated (#16310): `side_share` is the canonical spelling and carries the same value; this key stays on the wire.
575
+ * @deprecated
576
+ */
577
+ smart_score: number;
578
+ /** Cumulative provider taker volume in shares, not cash or dollars. */
579
+ volume: number;
580
+ /**
581
+ * Recorded conviction score; higher values indicate stronger conviction.
582
+ * @deprecated
583
+ */
584
+ conviction_score: number;
585
+ /** Whether the provider holder page came from the shared cache or a live provider read. */
586
+ provider_read_source: "cached" | "live";
587
+ /** True only when neither provider outcome holder page hit the top-100 scan bound. False means the pile is a positive lower bound and cannot satisfy a future capital-promotion gate. */
588
+ holder_scan_complete: boolean;
589
+ /** Proven provider holder observation time. A warm cache hit uses only the original provider completion time from its companion metadata, never cache-read time. Null, malformed, future, or stale holder time fails in-play closed. */
590
+ holder_snapshot_at: string | null;
591
+ /** 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. */
592
+ directional_status: "available" | "unknown_ungrouped" | "unknown_stale" | "unavailable";
593
+ one_way_holder_count: number | null;
594
+ hedged_holder_count: number | null;
595
+ one_way_graded_usd: number | null;
596
+ directional_confidence: number | null;
597
+ /** Recorded side ordering score; higher values sort first. */
598
+ directional_rank_score: number;
599
+ /** 1-based rank within this observation cohort and snapshot. */
600
+ rank: number;
601
+ };
602
+ /** Full Edge Hunter observations list envelope. The view literal distinguishes advanced collections, including empty pages. */
603
+ export type EdgeHunterObservationsResponse = {
604
+ object: "list";
605
+ view: "observations";
606
+ data: EdgeHunterObservation[];
607
+ has_more: boolean;
608
+ /** Pass as cursor for the next page. Always sent; null on the last page. */
609
+ next_cursor: string | null;
610
+ /** Completion time of the shared observation snapshot pinned by the cursor. */
611
+ snapshot_as_of: string;
612
+ /** True when an operational failure or unknown provider-board, holder, directional, reconciliation, or internal completeness state made this snapshot partial. This is snapshot-wide and can retain degradation that the funnel's one-terminal-per-input accounting cannot represent. Intentional bounded capacity_limited rows remain fully accounted in the funnel and do not by themselves set this field. */
613
+ degraded: boolean;
614
+ funnel: EdgeHunterFunnelReport;
615
+ meta: ResponseMeta;
616
+ };
617
+ /** 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. */
618
+ 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";
491
619
  /** One provider outcome in YES/NO order. Null current_price means no verified current quote is available. */
492
620
  export type EdgeHunterOutcome = {
493
621
  index: 0 | 1;
@@ -514,6 +642,82 @@ export type EdgeHunterPrice = {
514
642
  /** Backend validation clock in epoch milliseconds. Omitted when no current-source validation is available. */
515
643
  validated_at?: string;
516
644
  };
645
+ /** One ranked pre-game sports market where graded sharp money is piled on one side, with required-status category evidence from partial forward-observed Polymarket fills. */
646
+ export type EdgeHunterRankedSignal = {
647
+ /** The side profitable wallets hold, as a provider-backed display label. Canonical spelling of piled_side (#16310), same value: when provider group context is unavailable it may remain a bare Yes/No/Over/Under, so do not use it alone as participant identity. */
648
+ side: string | null;
649
+ /** UTC time at which the snapshot that ranked this row was computed. Canonical spelling of signal_created_at (#16310), same value. */
650
+ ranked_at: string;
651
+ /** Recorded side backing score; higher values indicate stronger backing. */
652
+ backing_score: number;
653
+ /** Signed share of graded money on the side, (yes_usd - no_usd)/(yes_usd + no_usd) in [-1, 1] (side-yes positive, side-no negative). Canonical spelling of smart_score (#16309, #16310), same value. */
654
+ side_share: number | null;
655
+ /** Polymarket condition id. */
656
+ condition_id: string;
657
+ /**
658
+ * UTC time at which the immutable signal snapshot was computed. Every row from one snapshot shares this value; it is not provider market creation time and is not rewritten at request time. Deprecated (#16310): `ranked_at` is the canonical spelling and carries the same value; this key stays on the wire.
659
+ * @deprecated
660
+ */
661
+ signal_created_at: string;
662
+ /** Polymarket CLOB token id (ERC1155 asset id, decimal string) for the PILED outcome; null when unavailable. */
663
+ token_id: string | null;
664
+ /** Canonical sport bucket (e.g. Basketball, Tennis); null when the raw category has no canonical mapping. */
665
+ category: "Basketball" | "Football" | "Baseball" | "Hockey" | "MMA" | "Boxing" | "Soccer" | "Cricket" | "Golf" | "Tennis" | "Esports" | "Racing" | "Table Tennis" | "Pickleball" | null;
666
+ /** Raw provider category as stored (e.g. NBA, EPL). */
667
+ raw_category: string | null;
668
+ title: string | null;
669
+ event_slug: string | null;
670
+ /** Kickoff (UTC). In the future at SNAPSHOT time and within the requested horizon; because the response is served from a shared snapshot cached up to the ~180s TTL, a served kickoff can be up to ~180s in the past relative to the response time. Not a live guarantee that the game has not yet started. */
671
+ game_start_time: string | null;
672
+ /**
673
+ * Nullable provider-backed piled-outcome display label. When provider group context is unavailable, it may remain a bare Yes/No/Over/Under; do not use it alone as participant identity. Deprecated (#16310): `side` is the canonical spelling and carries the same value; this key stays on the wire.
674
+ * @deprecated
675
+ */
676
+ piled_side: string | null;
677
+ /** Provider binary-column selector: 0 selects outcome_yes/token_id_yes; 1 selects outcome_no/token_id_no. It does not identify home/away or a participant. Use piled_side together with title/event context for display. */
678
+ piled_outcome_index: number;
679
+ /** Piled-side dollar concentration backed_usd / (yes_usd + no_usd), in (0.5, 1] for a real pile; null when there is no sharp USD. */
680
+ sharp_pct: number | null;
681
+ /** Raw piled-side sharp-money USD. */
682
+ backed_sharp_usd: number;
683
+ /** S-grade graded holders on the piled side. */
684
+ s_count: number;
685
+ /** A-grade graded holders on the piled side. */
686
+ a_count: number;
687
+ /** B-grade graded holders on the piled side. */
688
+ b_count: number;
689
+ /** Piled-side graded holder count (s_count + a_count + b_count). */
690
+ graded_holders: number;
691
+ /** Best grade present on the piled side; null when none. */
692
+ top_grade: "S" | "A" | "B" | null;
693
+ /**
694
+ * Canonical sharp-money score (yes_usd - no_usd)/(yes_usd + no_usd) in [-1, 1] (piled-yes positive, piled-no negative). Deprecated (#16310): `side_share` is the canonical spelling and carries the same value; this key stays on the wire.
695
+ * @deprecated
696
+ */
697
+ smart_score: number | null;
698
+ /** Cumulative provider taker volume in shares, not cash or dollars. */
699
+ volume: number | null;
700
+ /** Aggregate recent flow direction on the market; null when unavailable. */
701
+ net_side: "BUY" | "SELL" | null;
702
+ /**
703
+ * Recorded conviction score; higher values indicate stronger conviction.
704
+ * @deprecated
705
+ */
706
+ conviction_score: number;
707
+ /** Piled-side graded holders read one-way: their fresh open legs across the signal game's markets (cross-market within the one game; moneyline+spread family only) all back the same team, or, when the market's holder scan was complete, Polymarket's currentValue shows no opposite leg on this market worth 10% of the backed leg and no fresh leg opposes it. Null when the directional read was not computed (no groupable game, no holder-level data on this ranking path, or the enrichment read failed) or classified nobody. */
708
+ one_way_holder_count: number | null;
709
+ /** Piled-side graded holders classified HEDGED across the game by fresh legs (they back two or more distinct teams). A wallet long both outcomes of this market is not one-way and not counted here. Null when the directional read was not computed or classified nobody. */
710
+ hedged_holder_count: number | null;
711
+ /** Piled-side graded USD held by one-way wallets (share-weighted allocation of backed_sharp_usd). Null when the directional read was not computed or classified nobody. */
712
+ one_way_graded_usd: number | null;
713
+ /** One-way fraction of the piled graded dollars, in [0, 1] -- the metric orthogonal to sharp_pct. Stale, unknown, hedged, and two-sided dollars dilute it toward zero (conservative). Null when the directional read was not computed or classified nobody. */
714
+ directional_confidence: number | null;
715
+ /** Recorded side ordering score; higher values sort first. */
716
+ directional_rank_score: number;
717
+ category_skill: EdgeHunterCategorySkill;
718
+ /** 1-based rank within the (min_grade-filtered) ranked result. */
719
+ rank: number;
720
+ };
517
721
  /** One full Max row from Edge Hunter. signal is populated on every row this endpoint returns. Identity and quotes preserve provider values; unknown values stay null. */
518
722
  export type EdgeHunterRow = {
519
723
  rank: number;
@@ -554,6 +758,40 @@ export type EdgeHunterSignal = {
554
758
  directional_rank_score: number;
555
759
  current_price: EdgeHunterPrice;
556
760
  };
761
+ /** Full Edge Hunter signals list envelope. The view literal distinguishes advanced collections, including empty pages. */
762
+ export type EdgeHunterSignalsResponse = {
763
+ object: "list";
764
+ view: "signals";
765
+ data: EdgeHunterRankedSignal[];
766
+ has_more: boolean;
767
+ next_cursor?: string;
768
+ total?: number;
769
+ meta: ResponseMeta;
770
+ };
771
+ /** Independent sports-board supply plus stored-universe terminal accounting for one canonical sport. */
772
+ export type EdgeHunterSportFunnelReport = {
773
+ sport: "Basketball" | "Football" | "Baseball" | "Hockey" | "MMA" | "Boxing" | "Soccer" | "Cricket" | "Golf" | "Tennis" | "Esports" | "Racing" | "Table Tennis" | "Pickleball";
774
+ /** Unique condition ids independently visible on the provider-first sports board. */
775
+ board_input: number;
776
+ /** Whether the always-applicable live-board source completed as available. False can mean a completed source failure (board_source_unavailable) or live-board work missing an internal configured-scope deadline or the outer fair-wave deadline (board_deadline_unavailable); inspect terminals to distinguish them. */
777
+ board_live_available: boolean;
778
+ /** Whether a provider-backed upcoming-board source is configured and applicable for this sport. False means not applicable, not provider failure. */
779
+ board_upcoming_configured: boolean;
780
+ /** 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. */
781
+ board_upcoming_available: boolean;
782
+ /** 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 3,000 rows or 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. */
783
+ board_upcoming_status: "unknown" | "not_configured" | "available" | "capacity_limited" | "source_unavailable" | "cold_unavailable" | "deadline_unavailable";
784
+ /** 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. */
785
+ 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")[];
786
+ /** Stored-universe rows plus provider-board rows missing from storage. */
787
+ input: number;
788
+ /** 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. */
789
+ terminals: Record<string, number>;
790
+ /** Sum of every sparse terminal count. */
791
+ terminal_total: number;
792
+ /** True exactly when input equals terminal_total. */
793
+ reconciled: boolean;
794
+ };
557
795
  export type EventReplayEvent = {
558
796
  /** Opaque event identity: the ef_-encoded whale_alerts.id, stable across cursor formats. Deduplicate on this, never on cursor or sequence. */
559
797
  id: string;
@@ -2376,9 +2614,9 @@ export type ResponseMeta = {
2376
2614
  ranking_generation?: number;
2377
2615
  /** Authoritative RFC3339 timestamp from cache_generations.updated_at for ranking_generation. It is read in the same repeatable-read snapshot as the leaderboard rows and is not request time, cache write time, or row insertion order. */
2378
2616
  ranking_as_of?: string;
2379
- /** Which path produced the team-directional read on this response. Only present on endpoints that compute one (today: GET /api/v1/edge-hunter). "live" means the read RAN. "degraded" means it FAILED, so nothing was measured and the ranking fell back to raw conviction. The flag describes the READ, not its consequence: a read that ran and found nothing groupable also leaves the directional fields null, and that is honestly "live" -- the per-signal nulls already say "nothing to enrich here", so this snapshot-level flag carries only what they cannot, namely whether the read ran at all. A degraded response is cached on the shorter degraded TTL so it self-heals. Reported SEPARATELY from ranking_source because the two degradations are independent -- a sharp-money DB miss weakens the ranking DATA, a directional failure removes a ranking WEIGHT -- and a consumer down-weighting a degraded response needs to know which input it lost. Omitted on endpoints that compute no directional read. */
2617
+ /** Directional evidence provenance for Edge Hunter signals collections. The default board carries this provenance in data.directional_source and omits this optional meta field. */
2380
2618
  directional_source?: "live" | "degraded";
2381
- /** Which ranking-data path produced this response. Only present on endpoints that can degrade a ranking (today: GET /api/v1/edge-hunter). "live" is the normal path (the current holder pile from the provider batch); "db_only" is the degraded fallback (a truthful but weaker trader_markets ranking) served when the live sharp-money ranking batch is unavailable (a sharp-money DB read failure, not a Polymarket outage) and cached on a shorter TTL, so a consumer can down-weight or skip it. Omitted on endpoints that never degrade. */
2619
+ /** Ranking evidence provenance for Edge Hunter signals collections. The default board carries this clock/provenance in data.ranking_source and omits this optional meta field. */
2382
2620
  ranking_source?: "live" | "db_only";
2383
2621
  /** Whole filtered snapshot category-evidence status before pagination. Operational live always remains partial source coverage. */
2384
2622
  category_skill_source?: "live" | "partial" | "degraded" | "unavailable";
@@ -2388,7 +2626,7 @@ export type ResponseMeta = {
2388
2626
  category_skill_scope?: "observed_goldsky_primary_taker_fill";
2389
2627
  category_skill_source_coverage?: "partial_whale_threshold_fills" | "graded_wallet_fills";
2390
2628
  category_skill_observation_started_at?: string;
2391
- /** Whole-model operational readiness captured with the category model snapshot. Present on category-enriched responses even when the filtered signal list is empty. When true, category_skill_source is degraded and the ranked sports snapshot uses the shorter degraded cache TTL. */
2629
+ /** Whole-model operational readiness captured with the category model snapshot. Present on category-enriched responses even when the filtered signal list is empty. When true, category_skill_source is degraded and Edge Hunter signals uses the shorter degraded cache TTL. */
2392
2630
  category_skill_model_operationally_degraded?: boolean;
2393
2631
  category_skill_status_counts?: {
2394
2632
  live: number;
@@ -2397,9 +2635,9 @@ export type ResponseMeta = {
2397
2635
  unknown: number;
2398
2636
  degraded: number;
2399
2637
  };
2400
- /** SHA-256 of the funded signal membership/order/rank/cursor vector immediately before category-skill enrichment. Sports-edge-signals only. */
2638
+ /** SHA-256 of the funded signal membership/order/rank/cursor vector immediately before category-skill enrichment. Edge Hunter signals view only. */
2401
2639
  category_skill_base_payload_hash?: string;
2402
- /** Independent SHA-256 recomputation over the same base fields immediately after category-skill enrichment. Equality with category_skill_base_payload_hash proves category-skill enrichment did not change funded inputs. Sports-edge-signals only. */
2640
+ /** Independent SHA-256 recomputation over the same base fields immediately after category-skill enrichment. Equality with category_skill_base_payload_hash proves category-skill enrichment did not change funded inputs. Edge Hunter signals view only. */
2403
2641
  category_skill_enriched_base_payload_hash?: string;
2404
2642
  };
2405
2643
  /** An entitled same-day pick selected but not yet released: stable rank and backend-owned release/kickoff instants. No matchup, category, platform, side, price, or holder fields appear before release. Unauthorized scheduled ranks appear only in locked_picks. */
@@ -3505,7 +3743,7 @@ export interface OperationData {
3505
3743
  getCombosSummary: CombosSummary;
3506
3744
  getCoverage: Platforms;
3507
3745
  getDailyReportSnapshot: ReportSnapshot;
3508
- getEdgeHunter: EdgeHunterBoard;
3746
+ getEdgeHunter: EdgeHunterBoard | EdgeHunterRankedSignal[] | EdgeHunterObservation[];
3509
3747
  getEventReplaySince: EventReplayEvent[];
3510
3748
  getGame: Game;
3511
3749
  getHealth: {
@@ -3867,7 +4105,19 @@ export interface OperationQuery {
3867
4105
  date: string;
3868
4106
  };
3869
4107
  getEdgeHunter: {
3870
- /** Kickoff window in hours from the snapshot anchor. Defaults to 48; integer values below 1 or above 48 are clamped to 1 or 48. */
4108
+ /** Response mode. board preserves the full quoted board; signals exposes ranked records and category evidence; observations exposes cohort measurements and accountable funnel evidence. Defaults to board. */
4109
+ view?: "board" | "signals" | "observations";
4110
+ /** Optional canonical sport filter for signals and observations. Raw provider aliases canonicalize; non-sport categories return an empty collection. Rejected in board. */
4111
+ category?: string;
4112
+ /** Required for view=observations; wider_holder, in_play or emerging_pile. Rejected for board and signals. 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. */
4113
+ cohort?: "wider_holder" | "in_play" | "emerging_pile";
4114
+ /** Signals only: S, A or B, default B. Requires at least one piled-side holder at the selected floor or better; it does not remove other holders. Rejected for board and observations. */
4115
+ min_grade?: "S" | "A" | "B";
4116
+ /** Page size for signals and observations: defaults to 20 and clamps integer values to 1..100. Rejected in board. */
4117
+ limit?: number;
4118
+ /** Opaque canonical Edge Hunter cursor from next_cursor. Bound to view, normalized filters, source snapshot and ordering; observation cursors also bind cohort and emerging cutoff. Replaced snapshots return cursor_expired. Restart at page one when migrating from retired route cursors. Rejected in board. */
4119
+ cursor?: string;
4120
+ /** Kickoff window for board (default 48) or signals (default 12). Integer values clamp to 1..48. Rejected for observations, whose pre-game universe is fixed at 48 hours with a 12-hour in-play kickoff lookback. */
3871
4121
  horizon_hours?: number;
3872
4122
  };
3873
4123
  getEventReplaySince: {
@@ -4768,11 +5018,7 @@ export interface OperationResponse {
4768
5018
  data: OperationData["getDailyReportSnapshot"];
4769
5019
  meta: ResponseMeta;
4770
5020
  };
4771
- getEdgeHunter: {
4772
- object: "edge_hunter";
4773
- data: OperationData["getEdgeHunter"];
4774
- meta: ResponseMeta;
4775
- };
5021
+ getEdgeHunter: EdgeHunterBoardResponse | EdgeHunterSignalsResponse | EdgeHunterObservationsResponse;
4776
5022
  getEventReplaySince: {
4777
5023
  object: "event_replay";
4778
5024
  data: OperationData["getEventReplaySince"];