> ## 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-3 L4 orderbook diffs JSON Schema

> Get HIP-3 L4 orderbook diffs JSON Schema contract. Includes route metadata, request parameters, response statuses, examples, and JSON fields for implementation.

Source OpenAPI: 0xArchive API 1.8.0; 227 paths; 217 component schemas.

Get per-order diff events for the HIP-3 L4 orderbook. Each diff represents an individual order placement, modification, fill, or cancellation. Diff items may include an optional insert\_before field (order ID or null): for a new ALO order granted queue priority, it names the resting order this one is inserted ahead of within its price level. null or absent means tail append. Present on data from 2026-07-21 onward.

## Route Metadata

| Field | Value |
| - | - |
| Method | `GET` |
| Path | `/v1/hyperliquid/hip3/orderbook/{symbol}/l4/diffs` |
| operationId | `getHip3L4Diffs` |
| Tag | HIP-3 Builder Perps - L4 Order Book |
| Family | HIP-3 |
| Deprecated or legacy | no |

## Human endpoint reference

Open [`GET /v1/hyperliquid/hip3/orderbook/{symbol}/l4/diffs`](/api-reference/hip-3-builder-perps--l4-order-book/get-hip-3-l4-orderbook-diffs) for authentication, parameters, responses, and examples.

## Request Parameters

### Path Parameters

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip3L4Diffs path parameters",
  "type": "object",
  "required": [
    "symbol"
  ],
  "properties": {
    "symbol": {
      "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)",
      "type": "string",
      "example": "hyna:BTC",
      "x-parameter-location": "path"
    }
  }
}
```

### Query Parameters

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip3L4Diffs query parameters",
  "type": "object",
  "properties": {
    "start": {
      "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.",
      "type": "integer",
      "format": "int64",
      "example": 1767225600000,
      "x-parameter-location": "query"
    },
    "end": {
      "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.",
      "type": "integer",
      "format": "int64",
      "example": 1767312000000,
      "x-parameter-location": "query"
    },
    "cursor": {
      "description": "Cursor for pagination (use the value from previous response's `next_cursor`)",
      "type": "string",
      "x-parameter-location": "query"
    },
    "limit": {
      "description": "Maximum number of results (default: 1000, max: 10000)",
      "type": "integer",
      "default": 1000,
      "maximum": 10000,
      "x-parameter-location": "query"
    }
  }
}
```

## Response Contracts

### Status 200

L4 orderbook diff events

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip3L4Diffs response 200",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "description": "A single L4 order book diff event.",
        "type": "object",
        "properties": {
          "block_number": {
            "description": "Hyperliquid block number of the event.",
            "type": "integer",
            "format": "int64"
          },
          "coin": {
            "type": "string"
          },
          "diff_type": {
            "description": "new = order joined the book, update = resting size changed, remove = filled or canceled.",
            "type": "string",
            "enum": [
              "new",
              "update",
              "remove"
            ]
          },
          "insert_before": {
            "description": "ALO queue priority: the resting order ID this new order is inserted ahead of within its price level. null or absent means the order was appended at the queue tail. Populated on data from 2026-07-21 onward; absent on earlier history.",
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "new_size": {
            "description": "Resting size after the event; null on remove.",
            "type": "number",
            "nullable": true
          },
          "oid": {
            "description": "Order ID.",
            "type": "integer",
            "format": "int64"
          },
          "price": {
            "type": "number"
          },
          "seq": {
            "description": "Within-block sequence number.",
            "type": "integer"
          },
          "side": {
            "description": "B = bid, A = ask.",
            "type": "string",
            "enum": [
              "B",
              "A"
            ]
          },
          "timestamp": {
            "description": "Event time in epoch milliseconds.",
            "type": "integer",
            "format": "int64"
          },
          "user_address": {
            "description": "Address that owns the order.",
            "type": "string"
          }
        }
      }
    },
    "meta": {
      "type": "object",
      "properties": {
        "count": {
          "type": "integer"
        },
        "next_cursor": {
          "type": "string"
        },
        "request_id": {
          "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": "getHip3L4Diffs 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"
    },
    "param": {
      "description": "The parameter at fault, when the error is about one parameter.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    },
    "success": {
      "description": "Always false on an error.",
      "type": "boolean",
      "example": false
    }
  }
}
```

##### 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",
  "param": "limit",
  "request_id": "3f2a9c71-5b0e-4d68-9a4c-7e1d2b6f8a05",
  "success": false
}
```

### Status 401

Authentication required

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip3L4Diffs 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"
    },
    "param": {
      "description": "The parameter at fault, when the error is about one parameter.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    },
    "success": {
      "description": "Always false on an error.",
      "type": "boolean",
      "example": false
    }
  }
}
```

##### OpenAPI example

```json theme={"theme":"github-dark"}
{
  "code": 401,
  "error": "Missing authentication credentials. Provide X-API-Key header or Bearer token.",
  "error_code": "unauthorized",
  "request_id": "71ed4b6f-63ef-4ae1-a123-07ffa47c1c14",
  "success": false
}
```

### Status 429

Rate limit exceeded

#### application/json

```json theme={"theme":"github-dark"}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "getHip3L4Diffs 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"
    },
    "param": {
      "description": "The parameter at fault, when the error is about one parameter.",
      "type": "string"
    },
    "request_id": {
      "description": "Unique request ID for support",
      "type": "string",
      "format": "uuid"
    },
    "success": {
      "description": "Always false on an error.",
      "type": "boolean",
      "example": false
    }
  }
}
```

##### OpenAPI example

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


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.