> ## 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.

# Get HIP-4 outcome by slug JSON Schema

> Get HIP-4 outcome by slug JSON Schema contract. Includes route metadata, request parameters, response statuses, examples, and JSON fields for implementation.

Source OpenAPI: 0xArchive API 1.6.1; 147 paths; 128 component schemas.

Look up a HIP-4 outcome aggregate by synthesized outcome slug or side slug, for example `btc-above-78213-may-04-0600` or `btc-above-78213-yes-may-04-0600`. Returns the same aggregate shape as `/outcomes/&#123;outcome_id&#125;` with `aggregated_oi` populated when available.

## Route Metadata

| Field                | Value                                          |
| -------------------- | ---------------------------------------------- |
| Method               | `GET`                                          |
| Path                 | `/v1/hyperliquid/hip4/outcomes/by-slug/{slug}` |
| operationId          | `getHip4OutcomeBySlug`                         |
| Tag                  | HIP-4 Outcomes - Outcomes                      |
| Family               | HIP-4                                          |
| Deprecated or legacy | no                                             |

## Request Parameters

### Path Parameters

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip4OutcomeBySlug path parameters",
  "type": "object",
  "required": [
    "slug"
  ],
  "properties": {
    "slug": {
      "description": "HIP-4 outcome or side slug.",
      "type": "string",
      "example": "btc-above-78213-may-04-0600",
      "x-parameter-location": "path"
    }
  }
}
```

## Response Contracts

### Status 200

HIP-4 outcome aggregate

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip4OutcomeBySlug response 200",
  "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"
        },
        "coverage_from": {
          "description": "Earliest coverage for the requested symbol and data type. Present only when the requested window ends before coverage begins.",
          "type": "string",
          "format": "date-time"
        },
        "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
        },
        "notice": {
          "description": "Human-readable advisory about the response. Currently used when the requested window ends before coverage begins for the symbol; may carry other advisories in future.",
          "type": "string"
        },
        "request_id": {
          "description": "Unique request ID for support",
          "type": "string",
          "format": "uuid"
        }
      }
    },
    "success": {
      "type": "boolean",
      "example": true
    }
  }
}
```

### Status 400

Invalid request

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip4OutcomeBySlug response 400",
  "description": "Error response",
  "type": "object",
  "properties": {
    "code": {
      "description": "HTTP status code",
      "type": "integer"
    },
    "error": {
      "description": "Error message",
      "type": "string"
    },
    "error_code": {
      "description": "Machine-readable error code. Common values: `invalid_query_params` (a query parameter failed to parse or validate) and `invalid_path_params` (a path parameter failed to parse). Other endpoint-specific codes exist; treat unknown codes as generic errors of the given HTTP status.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    }
  }
}
```

##### OpenAPI example

```json theme={"theme":"github-dark"}
{
  "code": 400,
  "error": "Failed to deserialize query string: limit: invalid digit found in string",
  "error_code": "invalid_query_params",
  "request_id": "3f2a9c71-5b0e-4d68-9a4c-7e1d2b6f8a05"
}
```

### Status 401

Authentication required

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip4OutcomeBySlug response 401",
  "description": "Error response",
  "type": "object",
  "properties": {
    "code": {
      "description": "HTTP status code",
      "type": "integer"
    },
    "error": {
      "description": "Error message",
      "type": "string"
    },
    "error_code": {
      "description": "Machine-readable error code. Common values: `invalid_query_params` (a query parameter failed to parse or validate) and `invalid_path_params` (a path parameter failed to parse). Other endpoint-specific codes exist; treat unknown codes as generic errors of the given HTTP status.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    }
  }
}
```

##### OpenAPI example

```json theme={"theme":"github-dark"}
{
  "code": 401,
  "error": "Missing or invalid API key. Provide X-API-Key header."
}
```

### Status 429

Rate limit exceeded

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip4OutcomeBySlug response 429",
  "description": "Error response",
  "type": "object",
  "properties": {
    "code": {
      "description": "HTTP status code",
      "type": "integer"
    },
    "error": {
      "description": "Error message",
      "type": "string"
    },
    "error_code": {
      "description": "Machine-readable error code. Common values: `invalid_query_params` (a query parameter failed to parse or validate) and `invalid_path_params` (a path parameter failed to parse). Other endpoint-specific codes exist; treat unknown codes as generic errors of the given HTTP status.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    }
  }
}
```

##### OpenAPI example

```json theme={"theme":"github-dark"}
{
  "code": 429,
  "error": "Rate limit exceeded"
}
```
