Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.0xarchive.io/llms.txt

Use this file to discover all available pages before exploring further.

Source OpenAPI: 0xArchive API 1.5.0; 116 paths; 90 component schemas. API response wrapping a single HIP-4 outcome aggregate (with aggregated_oi populated on the detail endpoint)

Required Fields

No required fields are declared on this component schema.

JSON Schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "ApiResponseHip4OutcomeAggregate",
  "description": "API response wrapping a single HIP-4 outcome aggregate (with `aggregated_oi` populated on the detail endpoint)",
  "type": "object",
  "properties": {
    "data": {
      "description": "Per-outcome aggregate (both sides combined). Returned by `/outcomes` (list, without `aggregated_oi`) and `/outcomes/{outcome_id}` (detail, with `aggregated_oi` populated).",
      "type": "object",
      "required": [
        "is_settled",
        "outcome_id",
        "side_specs"
      ],
      "properties": {
        "aggregated_oi": {
          "description": "Display/paired/parity OI aggregates. Populated ONLY on the `/outcomes/{outcome_id}` detail response. Omitted (or null) on the `/outcomes` list response.",
          "nullable": true,
          "allOf": [
            {
              "description": "Derived OI display fields combining both sides of a HIP-4 outcome. Currency is always `USDH` (Hyperliquid's stablecoin). Only populated on `/outcomes/{outcome_id}` (detail), NOT on `/outcomes` (list).",
              "type": "object",
              "required": [
                "currency"
              ],
              "properties": {
                "as_of": {
                  "description": "Latest timestamp across both sides",
                  "type": "string",
                  "format": "date-time",
                  "nullable": true,
                  "example": "2026-05-02T20:27:21Z"
                },
                "currency": {
                  "description": "Notional currency. Always `USDH` for HIP-4.",
                  "type": "string",
                  "enum": [
                    "USDH"
                  ],
                  "example": "USDH"
                },
                "outcome_display_open_interest_contracts": {
                  "description": "Display total: sum of side0 + side1 OI contracts. Use this for outcome-level OI dashboards.",
                  "type": "number",
                  "nullable": true,
                  "example": 1136096
                },
                "paired_set_supply_contracts": {
                  "description": "Paired-set supply: minimum of side0 and side1 OI contracts. Represents the count of fully collateralized Yes+No pairs in circulation.",
                  "type": "number",
                  "nullable": true,
                  "example": 568048
                },
                "side0_as_of": {
                  "description": "Timestamp of the side 0 OI sample",
                  "type": "string",
                  "format": "date-time",
                  "nullable": true,
                  "example": "2026-05-02T20:27:21Z"
                },
                "side0_open_interest_contracts": {
                  "description": "Latest open-interest contracts for side 0 (Yes)",
                  "type": "number",
                  "nullable": true,
                  "example": 568048
                },
                "side1_as_of": {
                  "description": "Timestamp of the side 1 OI sample",
                  "type": "string",
                  "format": "date-time",
                  "nullable": true,
                  "example": "2026-05-02T20:27:21Z"
                },
                "side1_open_interest_contracts": {
                  "description": "Latest open-interest contracts for side 1 (No)",
                  "type": "number",
                  "nullable": true,
                  "example": 568048
                },
                "side_supply_parity": {
                  "description": "True when side0 OI equals side1 OI within tolerance. Parity should hold for binary outcomes; a sustained false value indicates ingestion drift.",
                  "type": "boolean",
                  "nullable": true,
                  "example": true
                }
              }
            }
          ]
        },
        "class": {
          "description": "Outcome class (e.g., `priceBinary`)",
          "type": "string",
          "nullable": true,
          "example": "priceBinary"
        },
        "description_raw": {
          "description": "Pipe-delimited recurring-market metadata as emitted upstream",
          "type": "string",
          "nullable": true,
          "example": "class:priceBinary|underlying:BTC|expiry:20260503-0600|targetPrice:78213|period:1d"
        },
        "expiry": {
          "description": "Settlement timestamp (UTC)",
          "type": "string",
          "format": "date-time",
          "nullable": true,
          "example": "2026-05-03T06:00:00Z"
        },
        "is_settled": {
          "description": "Whether the outcome has settled",
          "type": "boolean",
          "example": false
        },
        "name": {
          "description": "Human-readable outcome name (without per-side suffix)",
          "type": "string",
          "nullable": true,
          "example": "BTC ≥ 78213 by 2026-05-03 06:00 UTC"
        },
        "outcome_id": {
          "description": "Numeric outcome identifier",
          "type": "integer",
          "format": "int64",
          "example": 0
        },
        "period": {
          "description": "Cadence of the recurring market (e.g., `1d`, `1h`)",
          "type": "string",
          "nullable": true,
          "example": "1d"
        },
        "side_specs": {
          "description": "Per-side specs. Typically two elements: side 0 (Yes) and side 1 (No).",
          "type": "array",
          "items": {
            "description": "Per-side spec nested in `Hip4OutcomeAggregate.side_specs`. One element per side (typically two: side 0 = Yes, side 1 = No).",
            "type": "object",
            "required": [
              "asset_id",
              "coin",
              "name",
              "side"
            ],
            "properties": {
              "asset_id": {
                "description": "Public asset ID for this side",
                "type": "integer",
                "format": "int64",
                "example": 100000000
              },
              "coin": {
                "description": "Coin identifier for this side. Returned in `#`-prefixed form. REST paths accept either the bare numeric id (e.g. `0`) or the `#`-prefixed form (e.g. `#0`).",
                "type": "string",
                "example": "#0"
              },
              "name": {
                "description": "Human label for this side",
                "type": "string",
                "example": "Yes"
              },
              "side": {
                "description": "Side index: 0 = Yes, 1 = No",
                "type": "integer",
                "enum": [
                  0,
                  1
                ],
                "example": 0
              }
            }
          }
        },
        "source_seen_at": {
          "description": "Last time the outcome was seen upstream",
          "type": "string",
          "format": "date-time",
          "nullable": true,
          "example": "2026-05-02T20:25:00Z"
        },
        "status": {
          "description": "Lifecycle status (`live`, `settled`, ...)",
          "type": "string",
          "nullable": true,
          "example": "live"
        },
        "target_price": {
          "description": "Target price for the binary outcome",
          "type": "number",
          "nullable": true,
          "example": 78213
        },
        "underlying": {
          "description": "Underlying asset for recurring price-binary outcomes",
          "type": "string",
          "nullable": true,
          "example": "BTC"
        }
      }
    },
    "meta": {
      "description": "Response metadata",
      "type": "object",
      "properties": {
        "count": {
          "description": "Number of records returned",
          "type": "integer"
        },
        "next_cursor": {
          "description": "Cursor for pagination (timestamp). Use this value as the `cursor` parameter to fetch the next page of results.",
          "type": "string",
          "nullable": true
        },
        "request_id": {
          "description": "Unique request ID for support",
          "type": "string",
          "format": "uuid"
        }
      }
    },
    "success": {
      "type": "boolean",
      "example": true
    }
  }
}

Referenced By

Last modified on May 18, 2026