{ "openapi": "3.0.3", "info": { "title": "0xArchive API", "description": "REST API for current and historical market data from Hyperliquid and Lighter. Hyperliquid coverage includes core perpetuals, Spot, HIP-3 builder perpetuals, and HIP-4 outcome markets. Coverage and access requirements vary by route. See https://docs.0xarchive.io/ for authentication, limits, and examples.", "version": "1.6.1", "termsOfService": "https://0xarchive.io/terms", "contact": { "name": "0xArchive Support", "url": "https://0xarchive.io", "email": "support@0xarchive.io" }, "license": { "name": "Proprietary", "url": "https://0xarchive.io/terms" } }, "externalDocs": { "description": "0xArchive Developer Docs", "url": "https://docs.0xarchive.io/" }, "x-0xarchive-docs-language-overlay": { "name": "data-quality-supported-venue-language", "reason": "Public OpenAPI language must describe supported venue-family coverage instead of broad exchange coverage.", "updated_at": "2026-05-24", "remove_when": "Public source OpenAPI uses supported venue-family wording for data-quality coverage and latency descriptions." }, "servers": [ { "url": "https://api.0xarchive.io", "description": "Production API" } ], "security": [ { "ApiKeyAuth": [] } ], "tags": [ { "name": "System", "description": "Health checks and system status" }, { "name": "Hyperliquid - Instruments", "description": "Hyperliquid available trading instruments and their specifications. Authenticated inventory contains 232 core perpetual rows." }, { "name": "Hyperliquid - Order Book", "description": "Hyperliquid venue-native L2 order book snapshots. Native Hyperliquid source snapshots are capped at 20 levels per side; use the full-depth L2 routes for full-depth aggregated L2." }, { "name": "Hyperliquid - Full-Depth L2 Order Book", "description": "Full-depth aggregated L2 order book snapshots, checkpoint history, and diffs for Hyperliquid perpetuals derived from L4 data. Full-depth checkpoints and diffs where available." }, { "name": "Hyperliquid - Trades", "description": "Hyperliquid historical trade/fill data with full execution details. Data from April 2023." }, { "name": "Hyperliquid - Candles", "description": "Hyperliquid OHLCV candle data. Intervals: 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w." }, { "name": "Hyperliquid - Open Interest", "description": "Hyperliquid historical open interest and market context data. Data from May 2023." }, { "name": "Hyperliquid - Funding", "description": "Hyperliquid funding rate history. Data from May 2023." }, { "name": "Hyperliquid - Liquidations", "description": "Hyperliquid liquidation events with user attribution. The observed global floor is July 27, 2025; exact starts vary by symbol." }, { "name": "Hyperliquid - L4 Order Book", "description": "Individual resting-order (L4) book state for Hyperliquid perpetuals, including price, size, order ID, wallet attribution, queue priority, diffs, and checkpoints." }, { "name": "Hyperliquid - Orders", "description": "Order lifecycle events for Hyperliquid perpetuals: placements, cancellations, fills, and TP/SL triggers." }, { "name": "Hyperliquid - Convenience", "description": "Hyperliquid convenience endpoints: freshness, summary, and price history." }, { "name": "HIP-3 Builder Perps - Instruments", "description": "HIP-3 Builder Perps instrument discovery. Use this route with `/v1/symbols` `coverage_by_type` to resolve the current inventory and schema-specific dates." }, { "name": "HIP-3 Builder Perps - Order Book", "description": "HIP-3 Builder Perps venue-native L2 order book snapshots. Native Hyperliquid source snapshots are capped at 20 levels per side; use the full-depth L2 routes for full-depth aggregated L2." }, { "name": "HIP-3 Builder Perps - Full-Depth L2 Order Book", "description": "Full-depth aggregated L2 order book snapshots, checkpoint history, and diffs for HIP-3 builder perps derived from L4 data. Full-depth checkpoints and diffs where available." }, { "name": "HIP-3 Builder Perps - Trades", "description": "HIP-3 Builder Perps historical trade/fill data. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.trades` before choosing a time range." }, { "name": "HIP-3 Builder Perps - Candles", "description": "HIP-3 Builder Perps OHLCV candle data. Intervals: 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w. Coverage is symbol-specific; verify the selected market before choosing a time range." }, { "name": "HIP-3 Builder Perps - Open Interest", "description": "HIP-3 Builder Perps historical open interest data. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.oi` before choosing a time range." }, { "name": "HIP-3 Builder Perps - Funding", "description": "HIP-3 Builder Perps funding rate history. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.funding` before choosing a time range." }, { "name": "HIP-3 Builder Perps - Liquidations", "description": "HIP-3 Builder Perps liquidation-related fills. Coverage is symbol-specific; verify the selected market before choosing a time range." }, { "name": "HIP-3 Builder Perps - L4 Order Book", "description": "Individual order-level (L4) orderbook data for HIP-3 builder perps." }, { "name": "HIP-3 Builder Perps - Orders", "description": "Order lifecycle events for HIP-3 builder perps." }, { "name": "HIP-3 Builder Perps - Convenience", "description": "HIP-3 convenience endpoints: freshness, summary, and price history." }, { "name": "HIP-3 Builder Perps - Breadth", "description": "HIP-3 market breadth snapshots: percentage of eligible instruments trading above their current UTC-session VWAP." }, { "name": "HIP-4 Outcomes - Outcomes", "description": "HIP-4 outcome market discovery (one row per outcome, both sides combined). Use these to enumerate live and settled binary outcome markets. Data from May 2026." }, { "name": "HIP-4 Outcomes - Instruments", "description": "HIP-4 per-side instrument discovery (one row per `#N` coin). Each outcome has two sides: side 0 (Yes) and side 1 (No). Coins are `#`-prefixed. Data from May 2026." }, { "name": "HIP-4 Outcomes - Order Book", "description": "HIP-4 outcome markets L2 and L4 order book snapshots and diffs. Coins are referenced by numeric id (0, 1, 10, 11, ...); the `#`-prefixed form is also accepted. Data from May 2026." }, { "name": "HIP-4 Outcomes - Trades", "description": "HIP-4 outcome markets historical trade/fill data. Data from May 2026." }, { "name": "HIP-4 Outcomes - Open Interest", "description": "HIP-4 outcome markets per-side open interest history. Display/paired/parity aggregates live on the `/outcomes/{outcome_id}` detail endpoint, not here. Data from May 2026." }, { "name": "HIP-4 Outcomes - Orders", "description": "Order lifecycle events for HIP-4 outcome markets: placements, cancellations, fills, and TP/SL triggers." }, { "name": "HIP-4 Outcomes - Convenience", "description": "HIP-4 convenience endpoints: freshness, summary, and price history. `mark_price` for HIP-4 is an implied probability in [0,1], not a USD price." }, { "name": "Lighter - Instruments", "description": "Lighter available trading instruments and their specifications." }, { "name": "Lighter - Order Book", "description": "Lighter L2 order book snapshots with configurable granularity. Checkpoint history starts January 29, 2026; 30s/10s/1s start January 30, 2026; tick reconstruction available." }, { "name": "Lighter - Trades", "description": "Lighter historical fill data across more than 200 markets. Served history begins August 27, 2025, with exact starts varying by market." }, { "name": "Lighter - Candles", "description": "Lighter OHLCV candle data. Intervals: 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w. Data from August 2025." }, { "name": "Lighter - Open Interest", "description": "Lighter historical open interest data. Data from August 2025." }, { "name": "Lighter - Funding", "description": "Lighter funding rate history. Data from August 2025." }, { "name": "Lighter - L3 Order Book", "description": "Individual order-level (L3) orderbook data for Lighter. Data from March 2026." }, { "name": "Lighter - Convenience", "description": "Lighter convenience endpoints: freshness, summary, and price history." }, { "name": "Data Quality", "description": "Data quality monitoring: system status, coverage, incidents, latency, and SLA metrics." }, { "name": "Web3 Authentication", "description": "SIWE authentication for existing wallet accounts and autonomous paid wallet access via x402. Standard Free accounts are created through the browser signup flow." }, { "name": "Legacy", "description": "Deprecated endpoints that default to Hyperliquid. Use the exchange-specific endpoints (`/v1/hyperliquid/*`, `/v1/lighter/*`, `/v1/hyperliquid/hip3/*`) instead." }, { "name": "Hyperliquid Spot", "description": "Hyperliquid Spot pair, order book, trade, reconstruction, TWAP, and freshness routes." }, { "name": "Hyperliquid Spot - Candles", "description": "OHLCV candles for spot pairs (1m base, rolled up on demand)." }, { "name": "HIP-4 Outcomes - Candles", "description": "OHLCV candles for HIP-4 outcome sides. Prices are implied probabilities (0..1); quote_volume in USDH." } ], "paths": { "/health": { "get": { "tags": [ "System" ], "summary": "Health check", "description": "Check API health status. No authentication required.", "operationId": "healthCheck", "security": [], "responses": { "200": { "description": "API is healthy", "content": { "application/json": { "schema": { "type": "object", "properties": { "status": { "type": "string", "example": "ok" } } } } } } } } }, "/v1/orderbook/{symbol}": { "get": { "tags": [ "Legacy" ], "summary": "Get order book (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/orderbook/{symbol}` for the native 20-level Hyperliquid snapshot or `/v1/hyperliquid/orderbook/{symbol}/l2` for full-depth aggregated L2. Use `/v1/lighter/orderbook/{symbol}` for Lighter.\n\nGet the latest deprecated compatibility order book snapshot for a coin, or at a specific timestamp. This Hyperliquid compatibility route is capped at the native 20 price levels per side.", "operationId": "getOrderbook", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns latest snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this deprecated Hyperliquid compatibility route. Native Hyperliquid L2 data is capped at 20 levels per side; values above 20 do not return full depth here. Use /v1/hyperliquid/orderbook/{symbol}/l2 for full-depth aggregated L2.", "schema": { "type": "integer", "example": 20, "maximum": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/orderbook/{symbol}/history": { "get": { "tags": [ "Legacy" ], "summary": "Get order book history (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/orderbook/{symbol}/history` for native 20-level Hyperliquid history or `/v1/hyperliquid/orderbook/{symbol}/l2/history` for full-depth L2 checkpoint history. Use `/v1/lighter/orderbook/{symbol}/history` for Lighter.\n\nGet historical deprecated compatibility order book snapshots within a time range. Historical windows use `start` and `end` Unix-millisecond query parameters. This Hyperliquid compatibility route is capped at 20 levels per side.", "operationId": "getOrderbookHistory", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`). If not provided, starts from the beginning of the range.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this deprecated Hyperliquid compatibility route. Native Hyperliquid L2 data is capped at 20 levels per side; values above 20 do not return full depth here. Use /v1/hyperliquid/orderbook/{symbol}/l2 for full-depth aggregated L2.", "schema": { "type": "integer", "maximum": 20 } } ], "responses": { "200": { "description": "List of order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/trades/{symbol}": { "get": { "tags": [ "Legacy" ], "summary": "Get trades (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/trades/{symbol}` or `/v1/lighter/trades/{symbol}` instead.\n\nGet historical trades (fills) for a coin within a time range. Includes full execution details like fees, PnL, and position direction.\n\n**Pagination:** Use the `cursor` parameter with the timestamp from the previous response's `next_cursor` for efficient pagination through large datasets.", "operationId": "getTrades", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "**Recommended.** Cursor for pagination (use the value from previous response's `next_cursor`). The cursor is an opaque string that should be passed as-is.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" }, "example": { "success": true, "data": [], "meta": { "count": 100, "next_cursor": "1704067200123_456789", "request_id": "550e8400-e29b-41d4-a716-446655440000" } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/trades/{symbol}/cursor": { "get": { "tags": [ "Legacy" ], "summary": "Get trades with cursor pagination (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/trades/{symbol}` or `/v1/lighter/trades/{symbol}` instead.\n\nGet historical trades using cursor-based pagination. This is the same as `/v1/trades/{symbol}` with cursor pagination (which is now the default). This endpoint is maintained for backwards compatibility and explicit cursor-only usage.", "operationId": "getTradesCursor", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`). The cursor is an opaque string that should be passed as-is.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" }, "example": { "success": true, "data": [], "meta": { "count": 100, "next_cursor": "1704067200123_456789", "request_id": "550e8400-e29b-41d4-a716-446655440000" } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/instruments": { "get": { "tags": [ "Legacy" ], "summary": "List instruments (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/instruments` or `/v1/lighter/instruments` instead.\n\nGet all available trading instruments with their specifications.", "operationId": "listInstruments", "deprecated": true, "responses": { "200": { "description": "List of instruments", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseInstrumentArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/instruments/{symbol}": { "get": { "tags": [ "Legacy" ], "summary": "Get instrument (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/instruments/{symbol}` or `/v1/lighter/instruments/{symbol}` instead.\n\nGet details for a specific trading instrument.", "operationId": "getInstrument", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Instrument details", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseInstrument" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/openinterest/{symbol}": { "get": { "tags": [ "Legacy" ], "summary": "Get open interest history (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/openinterest/{symbol}` or `/v1/lighter/openinterest/{symbol}` instead.\n\nGet historical open interest data with associated market context (mark price, oracle price, volume, etc.).", "operationId": "getOpenInterest", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`). If not provided, starts from the beginning of the range.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Open interest data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterestArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/openinterest/{symbol}/current": { "get": { "tags": [ "Legacy" ], "summary": "Get current open interest (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/openinterest/{symbol}/current` or `/v1/lighter/openinterest/{symbol}/current` instead.\n\nGet the latest open interest value and market context.", "operationId": "getCurrentOpenInterest", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Current open interest", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterest" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/funding/{symbol}": { "get": { "tags": [ "Legacy" ], "summary": "Get funding rate history (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/funding/{symbol}` or `/v1/lighter/funding/{symbol}` instead.\n\nGet historical funding rates. Funding is settled every 8 hours on Hyperliquid.", "operationId": "getFundingHistory", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`). If not provided, starts from the beginning of the range.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Funding rate history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRateArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/funding/{symbol}/current": { "get": { "tags": [ "Legacy" ], "summary": "Get current funding rate (Deprecated)", "description": "**Deprecated:** Use `/v1/hyperliquid/funding/{symbol}/current` or `/v1/lighter/funding/{symbol}/current` instead.\n\nGet the latest funding rate for a coin.", "operationId": "getCurrentFunding", "deprecated": true, "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Current funding rate", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/instruments": { "get": { "tags": [ "Hyperliquid - Instruments" ], "summary": "List Hyperliquid instruments", "description": "Get all available Hyperliquid trading instruments with their specifications.", "operationId": "listHyperliquidInstruments", "responses": { "200": { "description": "List of instruments", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseInstrumentArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/instruments/{symbol}": { "get": { "tags": [ "Hyperliquid - Instruments" ], "summary": "Get Hyperliquid instrument", "description": "Get details for a specific Hyperliquid trading instrument.", "operationId": "getHyperliquidInstrument", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Instrument details", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseInstrument" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}": { "get": { "tags": [ "Hyperliquid - Order Book" ], "summary": "Get Hyperliquid native L2 order book (20 levels)", "description": "Get the latest venue-native Hyperliquid L2 order book snapshot, or a snapshot at a specific timestamp. This native route is capped at the 20 price levels per side provided by Hyperliquid source snapshots. Use `/v1/hyperliquid/orderbook/{symbol}/l2` for full-depth aggregated L2 derived from L4.", "operationId": "getHyperliquidOrderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns latest snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this native venue snapshot. Hyperliquid native L2 data is capped at 20 levels per side; values above 20 do not return full depth on this route. Use the /l2 routes for full-depth aggregated L2.", "schema": { "type": "integer", "example": 20, "maximum": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/history": { "get": { "tags": [ "Hyperliquid - Order Book" ], "summary": "Get Hyperliquid native L2 order book history (20 levels)", "description": "Get historical venue-native Hyperliquid L2 order book snapshots within a time range. Historical windows use `start` and `end` Unix-millisecond query parameters. This native route is capped at 20 price levels per side; use `/v1/hyperliquid/orderbook/{symbol}/l2/history` for full-depth checkpoint history derived from L4.", "operationId": "getHyperliquidOrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`)", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this native venue snapshot. Hyperliquid native L2 data is capped at 20 levels per side; values above 20 do not return full depth on this route. Use the /l2 routes for full-depth aggregated L2.", "schema": { "type": "integer", "maximum": 20 } } ], "responses": { "200": { "description": "List of order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l2": { "get": { "tags": [ "Hyperliquid - Full-Depth L2 Order Book" ], "summary": "Get Hyperliquid full-depth L2 order book", "description": "Get a full-depth aggregated L2 order book snapshot derived from L4 data for Hyperliquid. Use this route when you need full-depth aggregated L2 from March 10, 2026 onward. The native /orderbook route remains capped at 20 venue-native levels.", "operationId": "getHyperliquidFullDepthL2Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns the latest full-depth L2 snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "depth", "in": "query", "description": "Requested aggregated L2 levels per side. This dedicated route returns all available aggregated levels for the selected symbol and checkpoint.", "schema": { "type": "integer", "example": 200 } } ], "responses": { "200": { "description": "Full-depth L2 order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFullDepthL2OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l2/history": { "get": { "tags": [ "Hyperliquid - Full-Depth L2 Order Book" ], "summary": "Get Hyperliquid full-depth L2 order book history", "description": "Get paginated full-depth L2 checkpoint snapshots derived from L4 data for Hyperliquid from March 10, 2026 onward. The route returns full checkpoint depth; it does not currently accept a per-request depth override.", "operationId": "getHyperliquidFullDepthL2History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64", "example": 1767229200000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`)", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of checkpoint snapshots (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Full-depth L2 checkpoint snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFullDepthL2OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l2/diffs": { "get": { "tags": [ "Hyperliquid - Full-Depth L2 Order Book" ], "summary": "Get Hyperliquid full-depth L2 order book diffs", "description": "Get tick-level aggregate L2 diffs derived from L4 deltas for Hyperliquid.", "operationId": "getHyperliquidFullDepthL2Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64", "example": 1767229200000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination in `timestamp_ms_block_number` form from the previous response's `next_cursor`.", "schema": { "type": "string", "example": "1767225600000_1023882395" } }, { "name": "limit", "in": "query", "description": "Maximum number of diff events (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Full-depth L2 diff events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL2OrderBookDiffArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/trades/{symbol}": { "get": { "tags": [ "Hyperliquid - Trades" ], "summary": "Get Hyperliquid trades", "description": "Get historical trades (fills) for a coin within a time range. Includes full execution details like fees, PnL, and position direction. Data available from April 2023. History before 2025-03-22 comes from a capped per-user API backfill and is incomplete, especially for maker-side and high-volume activity.\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getHyperliquidTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/candles/{symbol}": { "get": { "tags": [ "Hyperliquid - Candles" ], "summary": "Get Hyperliquid OHLCV candles", "description": "Get historical OHLCV candle data. Data available from March 2025.\n\n**Available Intervals:** 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getHyperliquidCandles", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Candle interval (default: 1h)", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "30m", "1h", "4h", "1d", "1w" ], "default": "1h" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 10000)", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "List of OHLCV candles with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCandleArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/openinterest/{symbol}": { "get": { "tags": [ "Hyperliquid - Open Interest" ], "summary": "Get Hyperliquid open interest history", "description": "Get historical open interest data with associated market context (mark price, oracle price, volume, etc.). Data available from May 2023.", "operationId": "getHyperliquidOpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~1 min updates." } ], "responses": { "200": { "description": "Open interest data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterestArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/openinterest/{symbol}/current": { "get": { "tags": [ "Hyperliquid - Open Interest" ], "summary": "Get current Hyperliquid open interest", "description": "Get the latest open interest value and market context.", "operationId": "getCurrentHyperliquidOpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Current open interest", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterest" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/funding/{symbol}": { "get": { "tags": [ "Hyperliquid - Funding" ], "summary": "Get Hyperliquid funding rate history", "description": "Get historical funding rates. Funding is settled every 8 hours on Hyperliquid. Data available from May 2023.", "operationId": "getHyperliquidFundingHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~1 min updates." } ], "responses": { "200": { "description": "Funding rate history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRateArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/funding/{symbol}/current": { "get": { "tags": [ "Hyperliquid - Funding" ], "summary": "Get current Hyperliquid funding rate", "description": "Get the latest funding rate for a coin.", "operationId": "getCurrentHyperliquidFunding", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "BTC" }, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "example": "BTC" } ], "responses": { "200": { "description": "Current funding rate", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/liquidations/{symbol}": { "get": { "tags": [ "Hyperliquid - Liquidations" ], "summary": "Get Hyperliquid liquidation events", "description": "Get historical liquidation events for a coin. The observed global floor is July 27, 2025; exact starts vary by symbol.", "operationId": "getHyperliquidLiquidations", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (format: timestamp_tradeId)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Liquidation events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/liquidations/user/{user}": { "get": { "tags": [ "Hyperliquid - Liquidations" ], "summary": "Get liquidations by user address", "description": "Get historical liquidation events for a specific user address. Returns liquidations where the user was the liquidated party. The observed global floor is July 27, 2025; exact starts vary by symbol.", "operationId": "getHyperliquidLiquidationsByUser", "parameters": [ { "name": "user", "in": "path", "required": true, "description": "User wallet address (e.g., 0x...)", "schema": { "type": "string", "example": "0x84eec0068b37919cc8f13d7454073ac167374cc0" } }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "symbol", "in": "query", "description": "Optional symbol filter (e.g., BTC, ETH)", "schema": { "type": "string" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp in milliseconds)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "User liquidation events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/liquidations/{symbol}/volume": { "get": { "tags": [ "Hyperliquid - Convenience" ], "summary": "Get aggregated liquidation volume", "description": "Get pre-aggregated liquidation volumes in time-bucketed intervals. Returns total, long, and short USD volumes with counts.", "operationId": "getHyperliquidLiquidationVolume", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Aggregated liquidation volume data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationVolumeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/freshness/{symbol}": { "get": { "tags": [ "Hyperliquid - Convenience" ], "summary": "Get data freshness", "description": "Check when data was last updated for each data type for a specific coin.", "operationId": "getHyperliquidFreshness", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" } ], "responses": { "200": { "description": "Data freshness for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinFreshness" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/summary/{symbol}": { "get": { "tags": [ "Hyperliquid - Convenience" ], "summary": "Get market summary", "description": "Get a combined market summary including price, funding, OI, volume, and liquidation data in a single call.", "operationId": "getHyperliquidSummary", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" } ], "responses": { "200": { "description": "Market summary for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinSummary" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/prices/{symbol}": { "get": { "tags": [ "Hyperliquid - Convenience" ], "summary": "Get price history", "description": "Get mark/oracle price history. Lightweight projection of open interest data returning only price fields.", "operationId": "getHyperliquidPriceHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Price history data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponsePriceSnapshotArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/instruments": { "get": { "tags": [ "Lighter - Instruments" ], "summary": "List Lighter instruments", "description": "Get all available Lighter trading instruments with their specifications. Returns `LighterInstrument` objects which include fees, market IDs, and minimum order amounts.", "operationId": "listLighterInstruments", "responses": { "200": { "description": "List of Lighter instruments", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLighterInstrumentArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/instruments/{symbol}": { "get": { "tags": [ "Lighter - Instruments" ], "summary": "Get Lighter instrument", "description": "Get details for a specific Lighter trading instrument. Returns a `LighterInstrument` object which includes fees, market ID, and minimum order amounts.", "operationId": "getLighterInstrument", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" } ], "responses": { "200": { "description": "Lighter instrument details", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLighterInstrument" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/orderbook/{symbol}": { "get": { "tags": [ "Lighter - Order Book" ], "summary": "Get Lighter order book", "description": "Get the latest order book snapshot for a coin, or at a specific timestamp. Returns L2 depth with price, size, and order count at each level. Tick-level resolution.", "operationId": "getLighterOrderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "ETH" }, "example": "ETH" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns latest snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side. The Lighter native L2 route includes all served levels.", "schema": { "type": "integer", "example": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/orderbook/{symbol}/history": { "get": { "tags": [ "Lighter - Order Book" ], "summary": "Get Lighter order book history", "description": "Get historical order book snapshots within a time range with configurable resolution. Checkpoint history starts January 29, 2026; 30s/10s/1s start January 30, 2026. Use 'granularity' parameter to control data resolution.\n\n**Tick-Level Data:**\nWhen `granularity=tick`, the response format changes. Instead of returning snapshots in the `data` array, it returns:\n- `checkpoint`: Full orderbook state at the start of the time range\n- `deltas`: Array of incremental changes to apply to the checkpoint\n\nThis is the most efficient format for reconstructing high-frequency orderbook states. Use the SDK's `OrderBookReconstructor` class for client-side reconstruction.", "operationId": "getLighterOrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side. The Lighter native L2 route includes all served levels.", "schema": { "type": "integer" } }, { "name": "granularity", "in": "query", "description": "Data resolution: checkpoint (1min, default), 30s, 10s, 1s, tick. Checkpoint history starts January 29, 2026; 30s/10s/1s start January 30, 2026. Billed per row returned (about 1 credit per 1,000 rows, minimum 1 credit per request). Higher resolutions return more rows. **Note:** When granularity=tick, the response format changes to return `checkpoint` and `deltas` instead of a `data` array.", "schema": { "type": "string", "enum": [ "checkpoint", "30s", "10s", "1s", "tick" ], "default": "checkpoint" } } ], "responses": { "200": { "description": "List of order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/trades/{symbol}": { "get": { "tags": [ "Lighter - Trades" ], "summary": "Get Lighter trades", "description": "Get historical trades (fills) for a coin within a time range. Served fill history begins August 27, 2025; exact starts vary by market.\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getLighterTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLighterTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/trades/{symbol}/recent": { "get": { "tags": [ "Lighter - Trades" ], "summary": "Get recent Lighter trades", "description": "Get the most recent trades for a coin, ordered by timestamp descending.", "operationId": "getLighterRecentTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "limit", "in": "query", "description": "Number of trades to return (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of recent trades", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLighterTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/candles/{symbol}": { "get": { "tags": [ "Lighter - Candles" ], "summary": "Get Lighter OHLCV candles", "description": "Get historical OHLCV candle data. Supports multiple intervals from 1 minute to 1 week. Data available from August 2025.\n\n**Available Intervals:** 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getLighterCandles", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Candle interval (default: 1h)", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "30m", "1h", "4h", "1d", "1w" ], "default": "1h" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 10000)", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "List of OHLCV candles with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCandleArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/openinterest/{symbol}": { "get": { "tags": [ "Lighter - Open Interest" ], "summary": "Get Lighter open interest history", "description": "Get historical open interest data. Data available from August 2025.", "operationId": "getLighterOpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~10 sec updates." } ], "responses": { "200": { "description": "Open interest data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterestArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/openinterest/{symbol}/current": { "get": { "tags": [ "Lighter - Open Interest" ], "summary": "Get current Lighter open interest", "description": "Get the latest open interest value.", "operationId": "getCurrentLighterOpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" } ], "responses": { "200": { "description": "Current open interest", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterest" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/funding/{symbol}": { "get": { "tags": [ "Lighter - Funding" ], "summary": "Get Lighter funding rate history", "description": "Get historical Lighter funding rates. `funding_rate` is a fractional, non-annualized decimal, not percentage points. Data available from August 2025.", "operationId": "getLighterFundingHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~10 sec updates." } ], "responses": { "200": { "description": "Funding rate history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRateArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/funding/{symbol}/current": { "get": { "tags": [ "Lighter - Funding" ], "summary": "Get current Lighter funding rate", "description": "Get the latest Lighter funding rate for a coin. `funding_rate` is a fractional, non-annualized decimal, not percentage points.", "operationId": "getCurrentLighterFunding", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "ETH" }, "description": "Trading pair symbol (e.g., ETH, BTC)", "example": "ETH" } ], "responses": { "200": { "description": "Current funding rate", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/freshness/{symbol}": { "get": { "tags": [ "Lighter - Convenience" ], "summary": "Get Lighter data freshness", "description": "Check when data was last updated for each data type for a specific Lighter coin.", "operationId": "getLighterFreshness", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "ETH" } ], "responses": { "200": { "description": "Data freshness for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinFreshness" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/summary/{symbol}": { "get": { "tags": [ "Lighter - Convenience" ], "summary": "Get Lighter market summary", "description": "Get a combined market summary including price, funding, and open interest in a single call.", "operationId": "getLighterSummary", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "ETH" } ], "responses": { "200": { "description": "Market summary for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinSummary" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/prices/{symbol}": { "get": { "tags": [ "Lighter - Convenience" ], "summary": "Get Lighter price history", "description": "Get mark/oracle price history. Lightweight projection of open interest data returning only price fields.", "operationId": "getLighterPriceHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Coin symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Price history data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponsePriceSnapshotArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/instruments": { "get": { "tags": [ "HIP-3 Builder Perps - Instruments" ], "summary": "List HIP-3 instruments", "description": "List currently available HIP-3 builder-deployed perpetuals with latest market data (mark price, open interest, mid price). Use this route for discovery before selecting a symbol-specific data route.", "operationId": "listHip3Instruments", "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of HIP-3 instruments", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip3InstrumentArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/breadth/above-vwap/current": { "get": { "tags": [ "HIP-3 Builder Perps - Breadth" ], "summary": "Get current HIP-3 breadth above session VWAP", "description": "Get the latest aggregate percentage of eligible HIP-3 instruments trading above their current UTC-session VWAP. Each instrument contributes one vote; VWAP uses candle quote volume divided by base volume and compares the last completed 1-minute candle close. The session resets at 00:00 UTC. Instruments with no session volume or a last completed candle older than 5 minutes are excluded, so coverage varies by market hours. `value_pct` is null when no instruments are eligible, never 0. This route is aggregate-only and does not expose per-symbol VWAPs. Snapshots are written every minute. Data collection begins August 28, 2026.", "operationId": "getHip3BreadthAboveVwapCurrent", "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "Current HIP-3 breadth snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseBreadthSnapshot" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/breadth/above-vwap": { "get": { "tags": [ "HIP-3 Builder Perps - Breadth" ], "summary": "Get HIP-3 breadth above session VWAP history", "description": "Get historical aggregate HIP-3 breadth snapshots. Each row reports the percentage of eligible instruments above their current UTC-session VWAP and its auditable counts. Eligibility excludes instruments with no session volume or a last completed candle older than 5 minutes, so coverage varies by market hours. `start` and `end` are Unix timestamps in milliseconds and default to the last 24 hours. The optional `interval` downsamples by selecting the last stored snapshot in each bucket; percentages are never averaged because the denominator can vary. The optional `cursor` is an epoch-millisecond timestamp from `meta.next_cursor` and is exclusive. Snapshots are written every minute. Data collection begins August 28, 2026.", "operationId": "getHip3BreadthAboveVwap", "parameters": [ { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor timestamp in Unix milliseconds. Pass `meta.next_cursor` from the prior response; results after this timestamp are returned.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of snapshots (default: 100, max: 1000).", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "description": "Optional aggregation interval. Downsampled intervals select the last stored snapshot in each bucket; percentages are never averaged.", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "Historical HIP-3 breadth snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseBreadthSnapshotArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/instruments/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Instruments" ], "summary": "Get HIP-3 instrument", "description": "Get a specific HIP-3 instrument by coin name with latest market data. Coin names are case-sensitive (e.g., km:US500, xyz:XYZ100).", "operationId": "getHip3Instrument", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string" }, "description": "HIP-3 symbol name (e.g., km:US500, xyz:XYZ100). Case-sensitive.", "example": "km:US500" } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "HIP-3 instrument details", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip3Instrument" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Order Book" ], "summary": "Get HIP-3 native L2 order book (20 levels)", "description": "Get the latest venue-native HIP-3 L2 order book snapshot, or a snapshot at a specific timestamp. This native route is capped at the 20 price levels per side provided by Hyperliquid source snapshots. Use `/v1/hyperliquid/hip3/orderbook/{symbol}/l2` for full-depth aggregated L2 derived from L4. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.orderbook` before relying on historical availability.", "operationId": "getHip3Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol name (e.g., xyz:XYZ100)", "schema": { "type": "string", "example": "xyz:XYZ100" }, "example": "km:US500" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns latest snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1739750400000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this native venue snapshot. Hyperliquid native L2 data is capped at 20 levels per side; values above 20 do not return full depth on this route. Use the /l2 routes for full-depth aggregated L2.", "schema": { "type": "integer", "example": 20, "maximum": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/history": { "get": { "tags": [ "HIP-3 Builder Perps - Order Book" ], "summary": "Get HIP-3 native L2 order book history (20 levels)", "description": "Get historical venue-native HIP-3 L2 order book snapshots within a time range. Historical windows use `start` and `end` Unix-millisecond query parameters. This native route is capped at 20 price levels per side; use `/v1/hyperliquid/hip3/orderbook/{symbol}/l2/history` for full-depth checkpoint history derived from L4.", "operationId": "getHip3OrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side for this native venue snapshot. Hyperliquid native L2 data is capped at 20 levels per side; values above 20 do not return full depth on this route. Use the /l2 routes for full-depth aggregated L2.", "schema": { "type": "integer", "maximum": 20 } } ], "responses": { "200": { "description": "List of order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l2": { "get": { "tags": [ "HIP-3 Builder Perps - Full-Depth L2 Order Book" ], "summary": "Get HIP-3 full-depth L2 order book", "description": "Get a full-depth aggregated L2 order book snapshot derived from L4 data for HIP-3. Use this route when you need full-depth aggregated L2 from March 10, 2026 onward. The native /orderbook route remains capped at 20 venue-native levels.", "operationId": "getHip3FullDepthL2Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns the latest full-depth L2 snapshot.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "depth", "in": "query", "description": "Requested aggregated L2 levels per side. This dedicated route returns all available aggregated levels for the selected symbol and checkpoint.", "schema": { "type": "integer", "example": 200 } } ], "responses": { "200": { "description": "Full-depth L2 order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFullDepthL2OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l2/history": { "get": { "tags": [ "HIP-3 Builder Perps - Full-Depth L2 Order Book" ], "summary": "Get HIP-3 full-depth L2 order book history", "description": "Get paginated full-depth L2 checkpoint snapshots derived from L4 data for HIP-3 from March 10, 2026 onward. The route returns full checkpoint depth; it does not currently accept a per-request depth override.", "operationId": "getHip3FullDepthL2History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64", "example": 1767229200000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (timestamp from previous response's `next_cursor`)", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of checkpoint snapshots (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Full-depth L2 checkpoint snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFullDepthL2OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l2/diffs": { "get": { "tags": [ "HIP-3 Builder Perps - Full-Depth L2 Order Book" ], "summary": "Get HIP-3 full-depth L2 order book diffs", "description": "Get tick-level aggregate L2 diffs derived from L4 deltas for HIP-3.", "operationId": "getHip3FullDepthL2Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64", "example": 1767229200000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination in `timestamp_ms_block_number` form from the previous response's `next_cursor`.", "schema": { "type": "string", "example": "1767225600000_1023882395" } }, { "name": "limit", "in": "query", "description": "Maximum number of diff events (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Full-depth L2 diff events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL2OrderBookDiffArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/trades/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Trades" ], "summary": "Get HIP-3 trades", "description": "Get historical trades (fills) for a HIP-3 Builder Perps coin within a time range. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.trades` before choosing a time range.\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getHip3Trades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/trades/{symbol}/recent": { "get": { "tags": [ "HIP-3 Builder Perps - Trades" ], "summary": "Get recent HIP-3 trades", "description": "Get the most recent trades for a HIP-3 Builder Perps coin, ordered by timestamp descending. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.trades` before relying on availability.", "operationId": "getHip3RecentTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "limit", "in": "query", "description": "Number of trades to return (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of recent trades", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/candles/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Candles" ], "summary": "Get HIP-3 OHLCV candles", "description": "Get historical OHLCV candle data aggregated from HIP-3 trades. Coverage is symbol-specific; verify the selected market before choosing a time range.\n\n**Available Intervals:** 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getHip3Candles", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "km:US500" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Candle interval (default: 1h)", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "30m", "1h", "4h", "1d", "1w" ], "default": "1h" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 10000)", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "List of OHLCV candles with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCandleArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/openinterest/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Open Interest" ], "summary": "Get HIP-3 open interest history", "description": "Get historical open interest data for a HIP-3 Builder Perps coin. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.oi` before choosing a time range.", "operationId": "getHip3OpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~10 sec updates." } ], "responses": { "200": { "description": "Open interest data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterestArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/openinterest/{symbol}/current": { "get": { "tags": [ "HIP-3 Builder Perps - Open Interest" ], "summary": "Get current HIP-3 open interest", "description": "Get the latest open interest value for a HIP-3 Builder Perps coin. Availability is symbol-specific; inspect `/v1/symbols` `coverage_by_type.oi` before relying on the route.", "operationId": "getCurrentHip3OpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" } ], "responses": { "200": { "description": "Current open interest", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOpenInterest" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/funding/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Funding" ], "summary": "Get HIP-3 funding rate history", "description": "Get historical funding rates for a HIP-3 Builder Perps coin. Coverage is symbol-specific; inspect `/v1/symbols` `coverage_by_type.funding` before choosing a time range.", "operationId": "getHip3FundingHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~10 sec updates." } ], "responses": { "200": { "description": "Funding rate history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRateArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/funding/{symbol}/current": { "get": { "tags": [ "HIP-3 Builder Perps - Funding" ], "summary": "Get current HIP-3 funding rate", "description": "Get the latest funding rate for a HIP-3 Builder Perps coin. Availability is symbol-specific; inspect `/v1/symbols` `coverage_by_type.funding` before relying on the route.", "operationId": "getCurrentHip3Funding", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "xyz:XYZ100" }, "description": "Trading pair symbol (e.g., km:US500, xyz:XYZ100). HIP-3 symbols are case-sensitive.", "example": "km:US500" } ], "responses": { "200": { "description": "Current funding rate", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseFundingRate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/liquidations/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Liquidations" ], "summary": "Get HIP-3 liquidation events", "description": "Get liquidation-related fills for a HIP-3 symbol. Results can include liquidated-user rows plus counterparty/open-side rows. Coverage is symbol-specific; verify the selected market before choosing a time range.", "operationId": "getHip3Liquidations", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 trading pair symbol (e.g., hyna:BTC, km:US500). Case-sensitive.", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "hyna:BTC" }, { "name": "start", "in": "query", "required": true, "description": "Start timestamp (Unix milliseconds)", "schema": { "type": "integer", "format": "int64", "example": 1769922000000 } }, { "name": "end", "in": "query", "description": "End timestamp (Unix milliseconds). Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Pagination cursor (format: {timestamp_ms}_{trade_id})", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum records to return (1-1000)", "schema": { "type": "integer", "default": 1000, "maximum": 1000 } } ], "responses": { "200": { "description": "Liquidation events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/liquidations/{symbol}/volume": { "get": { "tags": [ "HIP-3 Builder Perps - Liquidations" ], "summary": "Get HIP-3 aggregated liquidation volume", "description": "Get aggregated liquidation-related volume in time-bucketed intervals for a HIP-3 symbol. total_* covers all liquidation rows; long_* and short_* are directional-family subtotals and may not sum to total when upstream emits unclassified directions. Coverage is symbol-specific; verify the selected market before choosing a time range.", "operationId": "getHip3LiquidationVolume", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 trading pair symbol (e.g., hyna:BTC, km:US500). Case-sensitive.", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "hyna:BTC" }, { "name": "start", "in": "query", "required": true, "description": "Start timestamp (Unix milliseconds)", "schema": { "type": "integer", "format": "int64", "example": 1769922000000 } }, { "name": "end", "in": "query", "description": "End timestamp (Unix milliseconds). Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Pagination cursor (timestamp in milliseconds)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum buckets to return (1-1000)", "schema": { "type": "integer", "default": 1000, "maximum": 1000 } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ], "default": "1h" } } ], "responses": { "200": { "description": "Aggregated liquidation volume data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationVolumeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/freshness/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Convenience" ], "summary": "Get HIP-3 data freshness", "description": "Check when data was last updated for each data type for a specific HIP-3 coin. Coin names are case-sensitive.", "operationId": "getHip3Freshness", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" } ], "responses": { "200": { "description": "Data freshness for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinFreshness" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/summary/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Convenience" ], "summary": "Get HIP-3 market summary", "description": "Get a combined market summary including price, mid price, funding, and open interest in a single call.", "operationId": "getHip3Summary", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" } ], "responses": { "200": { "description": "Market summary for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinSummary" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/prices/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Convenience" ], "summary": "Get HIP-3 price history", "description": "Get mark/oracle/mid price history. Lightweight projection of open interest data. Coin names are case-sensitive.", "operationId": "getHip3PriceHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., km:US500)", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Price history data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponsePriceSnapshotArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/data-quality/status": { "get": { "tags": [ "Data Quality" ], "summary": "Get system status", "description": "Get overall system health status including per-exchange and per-data-type status.", "operationId": "getDataQualityStatus", "responses": { "200": { "description": "System status", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StatusResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" } } } }, "/v1/data-quality/coverage": { "get": { "tags": [ "Data Quality" ], "summary": "Get coverage summary", "description": "Get data coverage summary for supported venue families, including earliest/latest data, record counts, and completeness. Note: May take 30-60 seconds on first request (results are cached server-side for 5 minutes).", "operationId": "getDataQualityCoverage", "responses": { "200": { "description": "Coverage summary", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CoverageResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" } } } }, "/v1/data-quality/coverage/{exchange}": { "get": { "tags": [ "Data Quality" ], "summary": "Get exchange coverage", "description": "Get data coverage for a specific exchange. Note: May take 30-60 seconds on first request (results are cached server-side for 5 minutes).", "operationId": "getExchangeCoverage", "parameters": [ { "name": "exchange", "in": "path", "required": true, "description": "Exchange name", "schema": { "type": "string", "enum": [ "hyperliquid", "lighter", "hip3", "spot", "hip4" ], "example": "hyperliquid" } } ], "responses": { "200": { "description": "Exchange coverage", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ExchangeCoverageResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" } } } }, "/v1/data-quality/coverage/{exchange}/{symbol}": { "get": { "tags": [ "Data Quality" ], "summary": "Get symbol coverage with gaps", "description": "Get data coverage for a specific symbol on an exchange, including gap detection showing periods where data may be missing. Supports optional `from`/`to` query params (Unix ms) to bound the gap detection window (default: last 30 days). Returns empirical data cadence when sufficient data is available. Historical coverage uses hour-level granularity. Note: May take 30-60 seconds on first request (gap detection results are cached server-side for 1 hour).", "operationId": "getSymbolCoverage", "parameters": [ { "name": "exchange", "in": "path", "required": true, "description": "Exchange name", "schema": { "type": "string", "enum": [ "hyperliquid", "lighter", "hip3", "spot", "hip4" ], "example": "hyperliquid" } }, { "name": "symbol", "in": "path", "required": true, "description": "Symbol name (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "from", "in": "query", "required": false, "description": "Start of gap detection window (Unix milliseconds). Default: now - 30 days.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "to", "in": "query", "required": false, "description": "End of gap detection window (Unix milliseconds). Default: now.", "schema": { "type": "integer", "format": "int64", "example": 1706745600000 } } ], "responses": { "200": { "description": "Symbol coverage with gaps", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SymbolCoverageResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" } } } }, "/v1/data-quality/incidents": { "get": { "tags": [ "Data Quality" ], "summary": "List incidents", "description": "List data quality incidents with filtering and pagination.", "operationId": "listIncidents", "parameters": [ { "name": "status", "in": "query", "description": "Filter by incident status", "schema": { "type": "string", "enum": [ "open", "investigating", "identified", "monitoring", "resolved" ] } }, { "name": "exchange", "in": "query", "description": "Filter by exchange", "schema": { "type": "string" } }, { "name": "since", "in": "query", "description": "Only show incidents starting after this timestamp (Unix ms)", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum results per page (default: 20, max: 100)", "schema": { "type": "integer", "default": 20, "maximum": 100 } }, { "name": "offset", "in": "query", "description": "Pagination offset", "schema": { "type": "integer", "default": 0 } } ], "responses": { "200": { "description": "List of incidents", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/IncidentsResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" } } } }, "/v1/data-quality/incidents/{id}": { "get": { "tags": [ "Data Quality" ], "summary": "Get incident", "description": "Get a specific incident by ID.", "operationId": "getIncident", "parameters": [ { "name": "id", "in": "path", "required": true, "description": "Incident ID", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Incident details", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Incident" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" } } } }, "/v1/data-quality/latency": { "get": { "tags": [ "Data Quality" ], "summary": "Get latency metrics", "description": "Get current latency metrics for supported venue families including WebSocket, REST API, and data freshness.", "operationId": "getLatencyMetrics", "responses": { "200": { "description": "Latency metrics", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/LatencyResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" } } } }, "/v1/data-quality/sla": { "get": { "tags": [ "Data Quality" ], "summary": "Get SLA metrics", "description": "Get SLA compliance metrics for a specific month including uptime, completeness, and latency targets vs actuals.", "operationId": "getSlaMetrics", "parameters": [ { "name": "year", "in": "query", "description": "Year (defaults to current year)", "schema": { "type": "integer", "example": 2026 } }, { "name": "month", "in": "query", "description": "Month 1-12 (defaults to current month)", "schema": { "type": "integer", "minimum": 1, "maximum": 12, "example": 1 } } ], "responses": { "200": { "description": "SLA metrics", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SlaResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" } } } }, "/v1/auth/web3/challenge": { "post": { "tags": [ "Web3 Authentication" ], "summary": "Get SIWE challenge message", "description": "Get a single-use SIWE (Sign-In with Ethereum) challenge message for existing-wallet sign-in, wallet key management, or paid x402 access. The nonce expires after 10 minutes. A challenge does not create a Free account.", "operationId": "web3Challenge", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3ChallengeRequest" } } } }, "responses": { "200": { "description": "SIWE challenge message", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3ChallengeResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/web3/signup": { "post": { "tags": [ "Web3 Authentication" ], "summary": "Wallet free signup retired", "description": "Compatibility tombstone for the retired wallet-only Free signup flow. This endpoint never creates an account or API key and always returns HTTP 410 with `wallet_free_signup_retired`. Create a standard Free account at https://0xarchive.io/signup, or use `/v1/web3/subscribe` for paid wallet access.", "operationId": "web3Signup", "security": [], "responses": { "410": { "description": "Wallet-only Free signup is retired.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3ErrorResponse" }, "example": { "code": 410, "error": "Free wallet signup has been retired. Use standard signup for Free access or purchase paid wallet access.", "error_code": "wallet_free_signup_retired", "request_id": "00000000-0000-0000-0000-000000000000" } } } } }, "deprecated": true } }, "/v1/web3/keys": { "post": { "tags": [ "Web3 Authentication" ], "summary": "List API keys for wallet", "description": "List all API keys belonging to the authenticated wallet. Requires a fresh SIWE challenge signed with `personal_sign` (EIP-191).", "operationId": "web3ListKeys", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3KeysRequest" } } } }, "responses": { "200": { "description": "List of API keys", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3KeysResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/web3/keys/revoke": { "post": { "tags": [ "Web3 Authentication" ], "summary": "Revoke an API key", "description": "Revoke a specific API key by its ID. Requires a fresh SIWE challenge signed with `personal_sign` (EIP-191).", "operationId": "web3RevokeKey", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3RevokeRequest" } } } }, "responses": { "200": { "description": "Key revoked successfully", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3RevokeResponse" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/web3/subscribe": { "post": { "tags": [ "Web3 Authentication" ], "summary": "Start Build or Pro access via x402 USDC payment", "description": "x402-protected endpoint for purchasing 30-day Build or Pro access with USDC on Base. Unknown wallets receive an account and API key only after successful payment settlement. Existing disabled wallets are rejected before facilitator verification or settlement.\n\n**Flow:**\n1. POST with `{ \"tier\": \"build\" }` (no payment header) → Server returns 402 with payment details (amount, pay_to address, network)\n2. Sign an EIP-712 `TransferWithAuthorization` (EIP-3009) on USDC Base for the specified amount\n3. Build x402 v2 payment payload, base64-encode it, and retry with `payment-signature` header\n4. Server verifies and settles payment via the facilitator → grants access → returns API key\n\nNo API key required. Payment establishes paid wallet access.", "operationId": "web3Subscribe", "security": [], "parameters": [ { "name": "payment-signature", "in": "header", "description": "Base64-encoded x402 v2 payment payload containing the EIP-3009 signed USDC transfer authorization. Omit on first request to receive payment details.", "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3SubscribeRequest" } } } }, "responses": { "200": { "description": "Subscription created successfully (returned when valid payment-signature header is provided)", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3SubscribeResponse" } } } }, "402": { "description": "Payment required. Response includes payment details: amount (micro-USDC), pay_to address, and network. Sign and retry with payment-signature header.", "content": { "application/json": { "schema": { "type": "object", "properties": { "payment": { "type": "object", "properties": { "amount": { "type": "string", "description": "Amount in micro-USDC (6 decimals)", "example": "49000000" }, "pay_to": { "type": "string", "description": "Treasury address to send USDC to", "example": "0x..." }, "network": { "type": "string", "description": "Blockchain network", "example": "base" } } } } } } } }, "403": { "description": "The existing wallet account is disabled. No facilitator verification or settlement is attempted.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3ErrorResponse" }, "example": { "code": 403, "error": "Account is disabled", "error_code": "account_disabled", "request_id": "00000000-0000-0000-0000-000000000000" } } } }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orders/{symbol}/history": { "get": { "tags": [ "Hyperliquid - Orders" ], "summary": "Get Hyperliquid order history", "description": "Get order lifecycle events for a symbol. Includes order placements, modifications, fills, cancellations, and triggers.", "operationId": "getHyperliquidOrderHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "status", "in": "query", "description": "Filter by order status", "schema": { "type": "string", "enum": [ "open", "filled", "canceled", "triggered", "force_canceled" ] } }, { "name": "order_type", "in": "query", "description": "Filter by order type", "schema": { "type": "string", "enum": [ "limit", "trigger", "tpsl" ] } }, { "name": "triggered", "in": "query", "description": "Filter by whether order was triggered", "schema": { "type": "boolean" } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Order lifecycle events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orders/{symbol}/flow": { "get": { "tags": [ "Hyperliquid - Orders" ], "summary": "Get Hyperliquid order flow", "description": "Get per-minute order flow aggregation for a symbol. Shows order placement and cancellation rates over time.", "operationId": "getHyperliquidOrderFlow", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "granularity", "in": "query", "description": "Aggregation granularity", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "1h" ] } } ], "responses": { "200": { "description": "Order flow aggregation data", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orders/{symbol}/tpsl": { "get": { "tags": [ "Hyperliquid - Orders" ], "summary": "Get Hyperliquid TP/SL orders", "description": "Get take-profit and stop-loss order events for a symbol. Shows TP/SL placements, triggers, and cancellations.", "operationId": "getHyperliquidTpsl", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "TP/SL order events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l4": { "get": { "tags": [ "Hyperliquid - L4 Order Book" ], "summary": "Get Hyperliquid L4 orderbook", "description": "Get the all-level L4 (individual order-level) orderbook reconstruction for a symbol. Shows resting orders across all served levels with price, size, and order ID. Returns the latest snapshot if no timestamp is provided. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHyperliquidL4Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds for the Hyperliquid snapshot. If omitted, returns the latest snapshot. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "depth", "in": "query", "description": "Maximum number of resting orders retained per side for this Hyperliquid L4 snapshot. Omit for the full stored depth.", "schema": { "type": "integer", "format": "int64", "example": 20 } } ], "responses": { "200": { "description": "Typed L4 orderbook snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l4/diffs": { "get": { "tags": [ "Hyperliquid - L4 Order Book" ], "summary": "Get Hyperliquid L4 orderbook diffs", "description": "Get per-order diff events for the 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.", "operationId": "getHyperliquidL4Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767312000000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } } ], "responses": { "200": { "description": "L4 orderbook diff events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object", "description": "A single L4 order book diff event.", "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Event time in epoch milliseconds." }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block number of the event." }, "seq": { "type": "integer", "description": "Within-block sequence number." }, "oid": { "type": "integer", "format": "int64", "description": "Order ID." }, "user_address": { "type": "string", "description": "Address that owns the order." }, "coin": { "type": "string" }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "B = bid, A = ask." }, "price": { "type": "number" }, "diff_type": { "type": "string", "enum": [ "new", "update", "remove" ], "description": "new = order joined the book, update = resting size changed, remove = filled or canceled." }, "new_size": { "type": "number", "nullable": true, "description": "Resting size after the event; null on remove." }, "insert_before": { "type": "integer", "format": "int64", "nullable": true, "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." } } } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orderbook/{symbol}/l4/history": { "get": { "tags": [ "Hyperliquid - L4 Order Book" ], "summary": "Get Hyperliquid L4 orderbook history", "description": "Get historical L4 orderbook checkpoint list. Each checkpoint is a full L4 snapshot that can be used as a starting point for replay. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHyperliquidL4History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767312000000 } }, { "name": "cursor", "in": "query", "description": "Timestamp cursor in Unix milliseconds from the previous response metadata.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000, "format": "int64" } } ], "responses": { "200": { "description": "Typed L4 orderbook checkpoint array", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orders/{symbol}/history": { "get": { "tags": [ "HIP-3 Builder Perps - Orders" ], "summary": "Get HIP-3 order history", "description": "Get order lifecycle events for a HIP-3 symbol. Includes order placements, modifications, fills, cancellations, and triggers.", "operationId": "getHip3OrderHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "status", "in": "query", "description": "Filter by order status", "schema": { "type": "string", "enum": [ "open", "filled", "canceled", "triggered", "force_canceled" ] } }, { "name": "order_type", "in": "query", "description": "Filter by order type", "schema": { "type": "string", "enum": [ "limit", "trigger", "tpsl" ] } }, { "name": "triggered", "in": "query", "description": "Filter by whether order was triggered", "schema": { "type": "boolean" } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Order lifecycle events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orders/{symbol}/flow": { "get": { "tags": [ "HIP-3 Builder Perps - Orders" ], "summary": "Get HIP-3 order flow", "description": "Get per-minute order flow aggregation for a HIP-3 symbol. Shows order placement and cancellation rates over time.", "operationId": "getHip3OrderFlow", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "granularity", "in": "query", "description": "Aggregation granularity", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "1h" ] } } ], "responses": { "200": { "description": "Order flow aggregation data", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orders/{symbol}/tpsl": { "get": { "tags": [ "HIP-3 Builder Perps - Orders" ], "summary": "Get HIP-3 TP/SL orders", "description": "Get take-profit and stop-loss order events for a HIP-3 symbol. Shows TP/SL placements, triggers, and cancellations.", "operationId": "getHip3Tpsl", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "TP/SL order events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l4": { "get": { "tags": [ "HIP-3 Builder Perps - L4 Order Book" ], "summary": "Get HIP-3 L4 orderbook", "description": "Get the all-level L4 (individual order-level) orderbook reconstruction for a HIP-3 symbol. Shows resting orders across all served levels with price, size, and order ID. Returns the latest snapshot if no timestamp is provided. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHip3L4Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds for the HIP-3 snapshot. If omitted, returns the latest snapshot. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "depth", "in": "query", "description": "Maximum number of resting orders retained per side for this HIP-3 L4 snapshot. Omit for the full stored depth.", "schema": { "type": "integer", "format": "int64", "example": 20 } } ], "responses": { "200": { "description": "Typed L4 orderbook snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l4/diffs": { "get": { "tags": [ "HIP-3 Builder Perps - L4 Order Book" ], "summary": "Get HIP-3 L4 orderbook diffs", "description": "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.", "operationId": "getHip3L4Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767312000000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } } ], "responses": { "200": { "description": "L4 orderbook diff events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object", "description": "A single L4 order book diff event.", "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Event time in epoch milliseconds." }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block number of the event." }, "seq": { "type": "integer", "description": "Within-block sequence number." }, "oid": { "type": "integer", "format": "int64", "description": "Order ID." }, "user_address": { "type": "string", "description": "Address that owns the order." }, "coin": { "type": "string" }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "B = bid, A = ask." }, "price": { "type": "number" }, "diff_type": { "type": "string", "enum": [ "new", "update", "remove" ], "description": "new = order joined the book, update = resting size changed, remove = filled or canceled." }, "new_size": { "type": "number", "nullable": true, "description": "Resting size after the event; null on remove." }, "insert_before": { "type": "integer", "format": "int64", "nullable": true, "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." } } } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orderbook/{symbol}/l4/history": { "get": { "tags": [ "HIP-3 Builder Perps - L4 Order Book" ], "summary": "Get HIP-3 L4 orderbook history", "description": "Get historical L4 orderbook checkpoint list for a HIP-3 symbol. Each checkpoint is a full L4 snapshot that can be used as a starting point for replay. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHip3L4History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol (case-sensitive, e.g., hyna:BTC, km:US500)", "schema": { "type": "string", "example": "hyna:BTC" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767312000000 } }, { "name": "cursor", "in": "query", "description": "Timestamp cursor in Unix milliseconds from the previous response metadata.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000, "format": "int64" } } ], "responses": { "200": { "description": "Typed L4 orderbook checkpoint array", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/outcomes": { "get": { "tags": [ "HIP-4 Outcomes - Outcomes" ], "summary": "List HIP-4 outcomes", "description": "List HIP-4 outcome markets (one row per outcome, both sides combined). Optional `is_settled` filter. Cursor pagination. Response uses `Hip4OutcomeAggregate` and OMITS the `aggregated_oi` field. Use `/outcomes/{outcome_id}` to fetch a single outcome with `aggregated_oi` populated. Data available from May 2026.", "operationId": "listHip4Outcomes", "parameters": [ { "name": "is_settled", "in": "query", "description": "Filter by settlement status. Omit to return both live and settled outcomes.", "schema": { "type": "boolean" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of HIP-4 outcomes (without `aggregated_oi`)", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OutcomeAggregateArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/outcomes/{outcome_id}": { "get": { "tags": [ "HIP-4 Outcomes - Outcomes" ], "summary": "Get HIP-4 outcome detail", "description": "Get a single HIP-4 outcome by `outcome_id`. Response uses `Hip4OutcomeAggregate` WITH `aggregated_oi` populated: latest both-sides OI snapshot including `outcome_display_open_interest_contracts` (sum of side0 + side1), `paired_set_supply_contracts` (paired-set notional), and `side_supply_parity` (whether side0 == side1 within tolerance). Currency is always `USDH`. Data available from May 2026.", "operationId": "getHip4Outcome", "parameters": [ { "name": "outcome_id", "in": "path", "required": true, "description": "Numeric outcome ID (integer >= 0). Each outcome has two sides: side 0 (Yes) and side 1 (No).", "schema": { "type": "integer", "format": "int64", "example": 0 }, "example": 0 } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "HIP-4 outcome detail (with `aggregated_oi`)", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OutcomeAggregate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/instruments": { "get": { "tags": [ "HIP-4 Outcomes - Instruments" ], "summary": "List HIP-4 instruments", "description": "List all HIP-4 outcome-market per-side instruments (one row per `#N` coin). Each outcome has two sides: side 0 (Yes) and side 1 (No). Coins are `#`-prefixed.", "operationId": "listHip4Instruments", "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of HIP-4 per-side instruments", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OutcomeArray" } } } }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/instruments/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Instruments" ], "summary": "Get HIP-4 instrument", "description": "Get a single HIP-4 per-side instrument by coin id (e.g., `0`, `1`). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "operationId": "getHip4Instrument", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "HIP-4 instrument detail", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4Outcome" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orderbook/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Order Book" ], "summary": "Get HIP-4 order book", "description": "Get the latest L2 order book snapshot for a HIP-4 outcome side, or at a specific timestamp. Returns L2 depth with price, size, and order count at each level. Data available from May 2026.", "operationId": "getHip4Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds. If not provided, returns latest snapshot.", "schema": { "type": "integer", "format": "int64" } }, { "name": "depth", "in": "query", "description": "Requested price levels per side. The HIP-4 native L2 route is capped at 20 levels per side.", "schema": { "type": "integer", "example": 20, "maximum": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orderbook/{symbol}/history": { "get": { "tags": [ "HIP-4 Outcomes - Order Book" ], "summary": "Get HIP-4 order book history", "description": "Get historical L2 order book snapshots within a time range with cursor pagination. Data available from May 2026.", "operationId": "getHip4OrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Requested price levels per side. The HIP-4 native L2 route is capped at 20 levels per side.", "schema": { "type": "integer", "maximum": 20 } } ], "responses": { "200": { "description": "List of order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orderbook/{symbol}/l4": { "get": { "tags": [ "HIP-4 Outcomes - Order Book" ], "summary": "Get HIP-4 L4 orderbook", "description": "Get the full L4 (individual order-level) orderbook reconstruction for a HIP-4 outcome side. Returns the latest snapshot if no timestamp is provided. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHip4L4Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds for the HIP-4 snapshot. If omitted, returns the latest snapshot. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1777680000000 } }, { "name": "depth", "in": "query", "description": "Maximum number of resting orders retained per side for this HIP-4 L4 snapshot. Omit for the full stored depth.", "schema": { "type": "integer", "format": "int64", "example": 20 } } ], "responses": { "200": { "description": "Typed L4 orderbook snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orderbook/{symbol}/l4/diffs": { "get": { "tags": [ "HIP-4 Outcomes - Order Book" ], "summary": "Get HIP-4 L4 orderbook diffs", "description": "Get per-order diff events for the HIP-4 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.", "operationId": "getHip4L4Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1777680000000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1777766400000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } } ], "responses": { "200": { "description": "L4 orderbook diff events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object", "description": "A single L4 order book diff event.", "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Event time in epoch milliseconds." }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block number of the event." }, "seq": { "type": "integer", "description": "Within-block sequence number." }, "oid": { "type": "integer", "format": "int64", "description": "Order ID." }, "user_address": { "type": "string", "description": "Address that owns the order." }, "coin": { "type": "string" }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "B = bid, A = ask." }, "price": { "type": "number" }, "diff_type": { "type": "string", "enum": [ "new", "update", "remove" ], "description": "new = order joined the book, update = resting size changed, remove = filled or canceled." }, "new_size": { "type": "number", "nullable": true, "description": "Resting size after the event; null on remove." }, "insert_before": { "type": "integer", "format": "int64", "nullable": true, "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." } } } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orderbook/{symbol}/l4/history": { "get": { "tags": [ "HIP-4 Outcomes - Order Book" ], "summary": "Get HIP-4 L4 orderbook history", "description": "Get historical L4 orderbook checkpoint list for a HIP-4 outcome side. Each checkpoint is a full L4 snapshot that can be used as a starting point for replay. The `limit` parameter defaults to 100 and is capped at 1000. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHip4L4History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1777680000000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1777766400000 } }, { "name": "cursor", "in": "query", "description": "Timestamp cursor in Unix milliseconds from the previous response metadata.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000, "format": "int64" } } ], "responses": { "200": { "description": "Typed L4 orderbook checkpoint array", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/trades/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Trades" ], "summary": "Get HIP-4 trades", "description": "Get historical trades (fills) for a HIP-4 outcome side within a time range. Data available from May 2026.\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor` for efficient pagination.", "operationId": "getHip4Trades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/trades/{symbol}/recent": { "get": { "tags": [ "HIP-4 Outcomes - Trades" ], "summary": "Get recent HIP-4 trades", "description": "Get the most recent trades for a HIP-4 outcome side, ordered by timestamp descending. Data available from May 2026.", "operationId": "getHip4RecentTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "limit", "in": "query", "description": "Number of trades to return (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "List of recent trades", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/openinterest/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Open Interest" ], "summary": "Get HIP-4 open interest history", "description": "Get historical per-side open interest data for a HIP-4 outcome side. Mirrors HIP-3 OI shape plus `outcome_id` and `side` fields. Display/paired/parity aggregates (sum across both sides, paired-set supply, side-supply parity check) live on `/outcomes/{outcome_id}.aggregated_oi`, NOT on this endpoint. Note: `mark_price` for HIP-4 outcomes is an implied probability in [0,1], not a USD price; same field name as perps because Hyperliquid upstream uses `markPx` for both. Data available from May 2026.", "operationId": "getHip4OpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] }, "description": "Aggregation interval. When omitted, returns raw ~10 sec outcome-side open-interest updates." } ], "responses": { "200": { "description": "Open interest data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OpenInterestArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/openinterest/{symbol}/current": { "get": { "tags": [ "HIP-4 Outcomes - Open Interest" ], "summary": "Get current HIP-4 open interest", "description": "Get the latest per-side open interest value for a HIP-4 outcome side. Mirrors HIP-3 OI shape plus `outcome_id` and `side` fields. Note: `mark_price` for HIP-4 outcomes is an implied probability in [0,1], not a USD price; same field name as perps because Hyperliquid upstream uses `markPx` for both.", "operationId": "getCurrentHip4OpenInterest", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" } ], "responses": { "200": { "description": "Current open interest", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OpenInterest" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/freshness/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Convenience" ], "summary": "Get HIP-4 data freshness", "description": "Check when HIP-4 order book, trade, and outcome-side open-interest data was last updated. The shared freshness envelope can describe funding and liquidations for other families; those buckets are omitted for HIP-4 because HIP-4 has no funding dataset or liquidation endpoint.", "operationId": "getHip4Freshness", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" } ], "responses": { "200": { "description": "Data freshness for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinFreshness" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/summary/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Convenience" ], "summary": "Get HIP-4 market summary", "description": "Get a combined market summary for a HIP-4 outcome side: latest mark price (implied probability in [0,1] for HIP-4, NOT USD), mid price, outcome-side open interest, and 24h volume. The shared summary schema retains optional funding, premium, oracle-price, and liquidation fields for compatibility across venue families; those fields are omitted for HIP-4 because they are not applicable. HIP-4 has no funding dataset or liquidation endpoint.", "operationId": "getHip4Summary", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" } ], "responses": { "200": { "description": "Market summary for the coin", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCoinSummary" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/prices/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Convenience" ], "summary": "Get HIP-4 price history", "description": "Get mark/mid price history for a HIP-4 outcome side. Lightweight projection of open interest data. Note: `mark_price` for HIP-4 outcomes is an implied probability in [0,1], not a USD price; same field name as perps because Hyperliquid upstream uses `markPx` for both. `oracle_price` is omitted for HIP-4 (outcomes have no oracle feed).", "operationId": "getHip4PriceHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in milliseconds", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ] } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Price history data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponsePriceSnapshotArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orders/{symbol}/history": { "get": { "tags": [ "HIP-4 Outcomes - Orders" ], "summary": "Get HIP-4 order history", "description": "Get order lifecycle events for a HIP-4 outcome side. Includes order placements, modifications, fills, cancellations, and triggers.", "operationId": "getHip4OrderHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "status", "in": "query", "description": "Filter by order status", "schema": { "type": "string", "enum": [ "open", "filled", "canceled", "triggered", "force_canceled" ] } }, { "name": "order_type", "in": "query", "description": "Filter by order type", "schema": { "type": "string", "enum": [ "limit", "trigger", "tpsl" ] } }, { "name": "triggered", "in": "query", "description": "Filter by whether order was triggered", "schema": { "type": "boolean" } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Order lifecycle events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orders/{symbol}/flow": { "get": { "tags": [ "HIP-4 Outcomes - Orders" ], "summary": "Get HIP-4 order flow", "description": "Get per-minute order flow aggregation for a HIP-4 outcome side. Shows order placement and cancellation rates over time.", "operationId": "getHip4OrderFlow", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "granularity", "in": "query", "description": "Aggregation granularity", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "1h" ] } } ], "responses": { "200": { "description": "Order flow aggregation data", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/orders/{symbol}/tpsl": { "get": { "tags": [ "HIP-4 Outcomes - Orders" ], "summary": "Get HIP-4 TP/SL orders", "description": "Get take-profit and stop-loss order events for a HIP-4 outcome side. Shows TP/SL placements, triggers, and cancellations.", "operationId": "getHip4Tpsl", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (e.g., `0` for outcome 0 Yes side, `1` for No side). The `#`-prefixed form (`#0`, `#1`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 1000, max: 10000)", "schema": { "type": "integer", "default": 1000, "maximum": 10000 } }, { "name": "user", "in": "query", "description": "Filter by user wallet address", "schema": { "type": "string" } } ], "responses": { "200": { "description": "TP/SL order events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/l3orderbook/{symbol}": { "get": { "tags": [ "Lighter - L3 Order Book" ], "summary": "Get Lighter L3 orderbook", "description": "Get the current Lighter L3 order-level snapshot with price, remaining size, order_index, and owner_account_index. Returns up to 250 resting orders per side.", "operationId": "getLighterL3Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "ETH" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds for the requested Lighter snapshot. If omitted, returns the latest snapshot. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1773273600000 } }, { "name": "account", "in": "query", "description": "Optional numeric Lighter account index filter.", "schema": { "type": "integer", "format": "int64", "example": 281474976710654 } }, { "name": "depth", "in": "query", "description": "Optional maximum number of resting orders returned per side. Values are clamped to the 1–250 ingestion cap.", "schema": { "type": "integer", "format": "int64", "example": 50 } } ], "responses": { "200": { "description": "Typed L3 orderbook snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL3OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/l3orderbook/{symbol}/history": { "get": { "tags": [ "Lighter - L3 Order Book" ], "summary": "Get Lighter L3 orderbook history", "description": "Get historical Lighter L3 order-level snapshots with price, remaining size, order_index, and owner_account_index. The public checkpoint-history response is an array of snapshots; each snapshot returns up to 250 resting orders per side. Optional `granularity` selects checkpoint, 30s, 10s, 1s, or tick resolution (checkpoint default); optional `account` filters by numeric account index. Data available from March 2026.", "operationId": "getLighterL3OrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH, SOL)", "schema": { "type": "string", "example": "BTC" }, "example": "ETH" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24 hours before the request. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1773273600000 } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1773273900000 } }, { "name": "cursor", "in": "query", "description": "Timestamp cursor in Unix milliseconds from the previous response metadata.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of snapshots per response; effective values are clamped to 1–1000 (default: 100).", "schema": { "type": "integer", "format": "int64", "default": 100, "maximum": 1000 } }, { "name": "granularity", "in": "query", "description": "Optional history resolution. Canonical values are checkpoint (default), 30s, 10s, 1s, and tick.", "schema": { "type": "string", "enum": [ "checkpoint", "30s", "10s", "1s", "tick" ], "default": "checkpoint" } }, { "name": "account", "in": "query", "description": "Optional numeric Lighter account index filter.", "schema": { "type": "integer", "format": "int64", "example": 281474976710654 } } ], "responses": { "200": { "description": "Typed historical L3 orderbook snapshot array", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL3OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/pairs": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "List Hyperliquid Spot pairs", "description": "List Hyperliquid Spot pairs available through 0xArchive.", "operationId": "getHyperliquidSpotPairs", "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of Hyperliquid Spot pairs", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseSpotPairArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/pairs/{symbol}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot pair metadata", "description": "Get metadata for one Hyperliquid Spot pair.", "operationId": "getHyperliquidSpotPair", "security": [ { "ApiKeyAuth": [] } ], "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" } ], "responses": { "200": { "description": "Hyperliquid Spot pair metadata", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseSpotPair" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/orderbook/{symbol}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot order book", "description": "Get the latest Hyperliquid Spot order book snapshot for a pair, or a historical snapshot when timestamp is supplied.", "operationId": "getHyperliquidSpotOrderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "timestamp", "in": "query", "description": "Timestamp for historical lookup. Supports the timestamp format used by the route family.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704067200000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T00:00:00Z" } ] } }, { "name": "depth", "in": "query", "description": "Number of price levels per side.", "schema": { "type": "integer", "example": 20 } } ], "responses": { "200": { "description": "Order book snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/trades/{symbol}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot trades", "description": "Get bounded historical trades for a Hyperliquid Spot pair.", "operationId": "getHyperliquidSpotTrades", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704067200000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T00:00:00Z" } ] } }, { "name": "end", "in": "query", "description": "End timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704070800000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T01:00:00Z" } ] } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return.", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "List of trades with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/trades/{symbol}/recent": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get recent Hyperliquid spot trades", "description": "Get the most recent trades for a Hyperliquid spot pair, ordered by timestamp descending.", "operationId": "getSpotTradesRecent", "parameters": [ { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string", "example": "HYPE-USDC" }, "description": "Spot trading pair symbol in dashed form (e.g., HYPE-USDC, PURR-USDC)", "example": "HYPE-USDC" }, { "name": "limit", "in": "query", "description": "Number of trades to return (default: 100, max: 10000)", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "List of recent trades", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTradeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/orderbook/{symbol}/l4": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot L4 order book", "description": "Get the L4 order-level reconstruction checkpoint for a Hyperliquid Spot pair. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHyperliquidSpotL4Orderbook", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "timestamp", "in": "query", "description": "Unix timestamp in milliseconds for the Hyperliquid Spot snapshot. If omitted, returns the latest snapshot. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "depth", "in": "query", "description": "Maximum number of resting orders retained per side for this Hyperliquid Spot L4 snapshot. Omit for the full stored depth.", "schema": { "type": "integer", "format": "int64", "example": 20 } } ], "responses": { "200": { "description": "Typed L4 orderbook snapshot", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBook" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/orderbook/{symbol}/l4/diffs": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot L4 order book diffs", "description": "Get per-order diff events for Hyperliquid Spot L4 reconstruction. 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.", "operationId": "getHyperliquidSpotL4Diffs", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1704070800000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return.", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "L4 orderbook diff events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object", "description": "A single L4 order book diff event.", "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Event time in epoch milliseconds." }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block number of the event." }, "seq": { "type": "integer", "description": "Within-block sequence number." }, "oid": { "type": "integer", "format": "int64", "description": "Order ID." }, "user_address": { "type": "string", "description": "Address that owns the order." }, "coin": { "type": "string" }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "B = bid, A = ask." }, "price": { "type": "number" }, "diff_type": { "type": "string", "enum": [ "new", "update", "remove" ], "description": "new = order joined the book, update = resting size changed, remove = filled or canceled." }, "new_size": { "type": "number", "nullable": true, "description": "Resting size after the event; null on remove." }, "insert_before": { "type": "integer", "format": "int64", "nullable": true, "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." } } } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/orderbook/{symbol}/l4/history": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot L4 order book history", "description": "Get historical Hyperliquid Spot L4 order book reconstruction windows. Within each price level, bids and asks are ordered by true queue priority (ALO priority insertions included), not by placement time. Depth truncation is by order count, so the orders at a depth cut can differ from responses served before 2026-07-21.", "operationId": "getHyperliquidSpotL4History", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1704067200000 } }, { "name": "end", "in": "query", "description": "End of the requested window as a Unix timestamp in milliseconds. ISO 8601 strings are rejected.", "schema": { "type": "integer", "format": "int64", "example": 1704070800000 } }, { "name": "cursor", "in": "query", "description": "Timestamp cursor in Unix milliseconds from the previous response metadata.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return (default: 10, hard cap: 10).", "schema": { "type": "integer", "default": 10, "maximum": 10, "format": "int64" } } ], "responses": { "200": { "description": "Typed L4 orderbook checkpoint array", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseL4OrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/orders/{symbol}/history": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot order history", "description": "Get historical order events for a Hyperliquid Spot pair.", "operationId": "getHyperliquidSpotOrderHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start timestamp, Unix milliseconds (e.g. 1767225600000)", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "end", "in": "query", "description": "End timestamp, Unix milliseconds", "schema": { "type": "integer", "format": "int64", "example": 1767225600000 } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return.", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "Order lifecycle events", "content": { "application/json": { "schema": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer" }, "next_cursor": { "type": "string" }, "request_id": { "type": "string", "format": "uuid" } } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/twap/{symbol}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot TWAP", "description": "Get TWAP data for a Hyperliquid Spot pair.", "operationId": "getHyperliquidSpotTwap", "security": [ { "ApiKeyAuth": [] } ], "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704067200000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T00:00:00Z" } ] } }, { "name": "end", "in": "query", "description": "End timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704070800000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T01:00:00Z" } ] } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return.", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "Hyperliquid Spot TWAP data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseSpotTwapArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/twap/user/{user}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot user TWAP", "description": "Get TWAP data scoped to a Hyperliquid user address.", "operationId": "getHyperliquidSpotUserTwap", "security": [ { "ApiKeyAuth": [] } ], "parameters": [ { "name": "user", "in": "path", "required": true, "description": "Hyperliquid user address.", "schema": { "type": "string", "example": "0x0000000000000000000000000000000000000000" }, "example": "0x0000000000000000000000000000000000000000" }, { "name": "start", "in": "query", "description": "Start timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704067200000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T00:00:00Z" } ] } }, { "name": "end", "in": "query", "description": "End timestamp for bounded historical queries.", "schema": { "oneOf": [ { "type": "integer", "format": "int64", "example": 1704070800000 }, { "type": "string", "format": "date-time", "example": "2026-01-01T01:00:00Z" } ] } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of records to return.", "schema": { "type": "integer", "default": 100, "maximum": 10000 } } ], "responses": { "200": { "description": "Hyperliquid Spot user TWAP data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseSpotTwapArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/freshness/{symbol}": { "get": { "tags": [ "Hyperliquid Spot" ], "summary": "Get Hyperliquid Spot freshness", "description": "Check when Spot order book, trade, L4, orders, and TWAP data was last updated for a Hyperliquid Spot pair.", "operationId": "getHyperliquidSpotFreshness", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" } ], "responses": { "200": { "description": "Hyperliquid Spot freshness data", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseSpotFreshness" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "404": { "$ref": "#/components/responses/NotFound" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/hyperliquid/spot/candles/{symbol}": { "get": { "tags": [ "Hyperliquid Spot - Candles" ], "summary": "Get spot OHLCV candles", "description": "Historical OHLCV candle data for a Hyperliquid spot pair, aggregated from archived spot trade data. Coverage matches archived spot trade history, beginning 2025-03-22.\n\n**Available Intervals:** 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor`.", "operationId": "getSpotCandles", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Spot pair symbol. Accepts dashed canonical (`PURR-USDC`, `HYPE-USDC`), the wire-format coin (`@107`), or a bare base-token name (`HFUN`).", "schema": { "type": "string", "example": "PURR-USDC" }, "example": "PURR-USDC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Candle interval (default: 1h)", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "30m", "1h", "4h", "1d", "1w" ], "default": "1h" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of OHLCV candles with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCandleArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/candles/{symbol}": { "get": { "tags": [ "HIP-4 Outcomes - Candles" ], "summary": "Get HIP-4 OHLCV candles", "description": "Historical OHLCV candle data for a HIP-4 outcome side, aggregated from archived HIP-4 trade data. Coverage begins 2026-05-02 (HIP-4 mainnet launch).\n\n**Note on HIP-4 prices:** HIP-4 prices are implied probabilities (0..1), not USD. `quote_volume` is denominated in USDH (the collateral). The OHLCV shape is identical to perp candles so SDKs work unchanged.\n\n**Available Intervals:** 1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w\n\n**Pagination:** Use the `cursor` parameter with the value from the previous response's `next_cursor`.", "operationId": "getHip4Candles", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-4 coin id (numeric `0`, `1`, `10`, `11`, ...) where id = `10*outcome_id + side`. The `#`-prefixed form (`#0`, `#10`) is also accepted.", "schema": { "type": "string", "example": "0" }, "example": "0" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults to 24h ago.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Candle interval (default: 1h)", "schema": { "type": "string", "enum": [ "1m", "5m", "15m", "30m", "1h", "4h", "1d", "1w" ], "default": "1h" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination (use the value from previous response's `next_cursor`)", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "security": [ { "ApiKeyAuth": [] } ], "responses": { "200": { "description": "List of OHLCV candles with cursor for next page", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCandleArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/cvd/{symbol}": { "get": { "tags": [ "Hyperliquid - Convenience" ], "summary": "Get Hyperliquid cumulative volume delta", "description": "Get hourly cumulative volume delta buckets for a Hyperliquid core symbol. Live responses currently meter this route at 1 credit per request. Use `start`, `end`, and `interval` to bound the returned window.", "operationId": "getHyperliquidCvd", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol (e.g., BTC, ETH)", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults depend on the route family.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval. Supported public buckets are 1h, 4h, 1d, and 1w.", "schema": { "type": "string", "enum": [ "1h", "4h", "1d", "1w" ], "default": "1h" } } ], "responses": { "200": { "description": "CVD buckets", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCvdBucketArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/cvd/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Convenience" ], "summary": "Get HIP-3 cumulative volume delta", "description": "Get hourly cumulative volume delta buckets for a HIP-3 builder-perp symbol. Live responses currently meter this route at 1 credit per request. Preserve the builder prefix and symbol case.", "operationId": "getHip3Cvd", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol with builder prefix. Case-sensitive.", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults depend on the route family.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "interval", "in": "query", "description": "Aggregation interval. Supported public buckets are 1h, 4h, 1d, and 1w.", "schema": { "type": "string", "enum": [ "1h", "4h", "1d", "1w" ], "default": "1h" } } ], "responses": { "200": { "description": "HIP-3 CVD buckets", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseCvdBucketArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/liquidations/{symbol}/levels": { "get": { "tags": [ "Hyperliquid - Liquidations" ], "summary": "Get Hyperliquid liquidation levels", "description": "Projected forced-liquidation levels computed from clearinghouse positions and margin state, aggregated into price buckets around the snapshot mark price. Snapshots are computed roughly every 5 minutes; the response's snapshot_ts identifies the snapshot served. Historical snapshots are retained from 2026-07-27: use the at parameter for a point-in-time read, or the /history variant to enumerate snapshots with cursor pagination. Available on every plan; the endpoint carries a premium per-request credit cost. Note: before 2026-07-23 this path served a pending trigger-order map; that data now lives at /orders/{symbol}/trigger-levels.", "operationId": "getHyperliquidLiquidationLevels", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } }, { "name": "at", "in": "query", "description": "Point-in-time read: epoch milliseconds (UTC). Serves the newest snapshot at or before this instant. Omit for the latest snapshot. History begins 2026-07-27; earlier instants return 404.", "schema": { "type": "integer", "format": "int64" } } ], "responses": { "200": { "description": "Get Hyperliquid liquidation levels", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationLevels" }, "examples": { "raw": { "summary": "Representative current response sourced from raw liquidation levels", "value": { "success": true, "data": { "mid_price": 64234, "snapshot_ts": "2026-08-06 13:20:14.000", "block_number": 1100170000, "total_long": 826442891, "total_short": 940536199.24, "flagged_notional": 121607711.81, "levels": [ { "price": 63655.89, "long_notional": 7411401.14, "short_notional": 0, "long_count": 190, "short_count": 0 }, { "price": 63784.36, "long_notional": 6715249.11, "short_notional": 0, "long_count": 458, "short_count": 0 }, { "price": 63912.83, "long_notional": 4028699.95, "short_notional": 0, "long_count": 344, "short_count": 0 }, { "price": 64041.3, "long_notional": 1387884.13, "short_notional": 0, "long_count": 171, "short_count": 0 }, { "price": 64169.77, "long_notional": 742482.09, "short_notional": 0, "long_count": 86, "short_count": 0 }, { "price": 64298.23, "long_notional": 0, "short_notional": 64234, "long_count": 0, "short_count": 1 }, { "price": 64426.7, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 64555.17, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 64683.64, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 64812.11, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 } ], "source": "raw" }, "meta": { "count": 10, "request_id": "a1b2c3d4-e5f6-4789-8abc-def012345678" } } }, "histogram": { "summary": "Representative current response sourced from a stored histogram", "value": { "success": true, "data": { "mid_price": 63871, "snapshot_ts": "2026-08-02 16:25:06.000", "block_number": 1095490000, "total_long": 785802121.2, "total_short": 834739310.48, "flagged_notional": 0, "levels": [ { "price": 58122.61, "long_notional": 83958706.7, "short_notional": 18054.42, "long_count": 1231, "short_count": 2 }, { "price": 59400.03, "long_notional": 73999154.77, "short_notional": 50.46, "long_count": 753, "short_count": 1 }, { "price": 60677.45, "long_notional": 47854533.03, "short_notional": 0, "long_count": 935, "short_count": 0 }, { "price": 61954.87, "long_notional": 39840093.21, "short_notional": 24801.11, "long_count": 2402, "short_count": 2 }, { "price": 63232.29, "long_notional": 1919748.29, "short_notional": 7224430.93, "long_count": 457, "short_count": 556 }, { "price": 64509.71, "long_notional": 90958.69, "short_notional": 57214522.14, "long_count": 4, "short_count": 1311 }, { "price": 65787.13, "long_notional": 5074713.82, "short_notional": 31458405.35, "long_count": 3, "short_count": 558 }, { "price": 67064.55, "long_notional": 1156673.15, "short_notional": 66646595.42, "long_count": 4, "short_count": 454 }, { "price": 68341.97, "long_notional": 434765.43, "short_notional": 107401882.13, "long_count": 10, "short_count": 992 }, { "price": 69619.39, "long_notional": 110833.43, "short_notional": 69719137.34, "long_count": 6, "short_count": 582 } ], "source": "histogram", "source_bin_width": 319.355 }, "meta": { "count": 10, "request_id": "b2c3d4e5-f6a7-4890-9bcd-ef0123456789" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/liquidations/{symbol}/levels": { "get": { "tags": [ "HIP-3 - Liquidations" ], "summary": "Get HIP-3 liquidation levels", "description": "Projected forced-liquidation levels computed from clearinghouse positions and margin state, aggregated into price buckets around the snapshot mark price. Snapshots are computed roughly every 5 minutes; the response's snapshot_ts identifies the snapshot served. Historical snapshots are retained from 2026-07-27: use the at parameter for a point-in-time read, or the /history variant to enumerate snapshots with cursor pagination. Available on every plan; the endpoint carries a premium per-request credit cost. Note: before 2026-07-27 this path served a pending trigger-order map; that data now lives at /orders/{symbol}/trigger-levels. For HIP-3, cross-margined exposure is reported in flagged_notional and excluded from buckets.", "operationId": "getHip3LiquidationLevels", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "xyz:TSLA" }, "example": "xyz:TSLA" }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } }, { "name": "at", "in": "query", "description": "Point-in-time read: epoch milliseconds (UTC). Serves the newest snapshot at or before this instant. Omit for the latest snapshot. History begins 2026-07-27; earlier instants return 404.", "schema": { "type": "integer", "format": "int64" } } ], "responses": { "200": { "description": "Get HIP-3 liquidation levels", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationLevels" }, "examples": { "raw": { "summary": "Representative current response sourced from raw liquidation levels", "value": { "success": true, "data": { "mid_price": 318.98, "snapshot_ts": "2026-08-06 13:20:14.000", "block_number": 1100170000, "total_long": 9439936.86, "total_short": 12457314.46, "flagged_notional": 15437186.38, "levels": [ { "price": 316.1092, "long_notional": 2947.38, "short_notional": 0, "long_count": 4, "short_count": 0 }, { "price": 316.7471, "long_notional": 5528.56, "short_notional": 0, "long_count": 6, "short_count": 0 }, { "price": 317.3851, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 318.0231, "long_notional": 2001.92, "short_notional": 0, "long_count": 4, "short_count": 0 }, { "price": 318.661, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 319.299, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 319.9369, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 320.5749, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 321.2129, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 }, { "price": 321.8508, "long_notional": 0, "short_notional": 0, "long_count": 0, "short_count": 0 } ], "source": "raw" }, "meta": { "count": 10, "request_id": "c3d4e5f6-a7b8-4901-abcd-f0123456789a" } } }, "histogram": { "summary": "Representative current response sourced from a stored histogram", "value": { "success": true, "data": { "mid_price": 322.86, "snapshot_ts": "2026-08-02 18:46:43.000", "block_number": 1095610000, "total_long": 9707806.14, "total_short": 13189198.41, "flagged_notional": 15254536.42, "levels": [ { "price": 293.8026, "long_notional": 221368.31, "short_notional": 0, "long_count": 64, "short_count": 0 }, { "price": 300.2598, "long_notional": 120836.17, "short_notional": 0, "long_count": 35, "short_count": 0 }, { "price": 306.717, "long_notional": 6712.26, "short_notional": 0, "long_count": 15, "short_count": 0 }, { "price": 313.1742, "long_notional": 0, "short_notional": 48.75, "long_count": 0, "short_count": 1 }, { "price": 319.6314, "long_notional": 0, "short_notional": 327341.3, "long_count": 0, "short_count": 10 }, { "price": 326.0886, "long_notional": 0, "short_notional": 3690.61, "long_count": 0, "short_count": 4 }, { "price": 332.5458, "long_notional": 0, "short_notional": 59987.71, "long_count": 0, "short_count": 10 }, { "price": 339.003, "long_notional": 0, "short_notional": 55121.89, "long_count": 0, "short_count": 3 }, { "price": 345.4602, "long_notional": 0, "short_notional": 461.37, "long_count": 0, "short_count": 3 }, { "price": 351.9174, "long_notional": 0, "short_notional": 374.52, "long_count": 0, "short_count": 4 } ], "source": "histogram", "source_bin_width": 1.6143 }, "meta": { "count": 10, "request_id": "d4e5f6a7-b8c9-4012-bcde-0123456789ab" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/oracle/external-price/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Oracle" ], "summary": "Get HIP-3 oracle external price", "description": "Get the latest deployer-pushed external reference price and mark price for a HIP-3 market. Live responses currently meter this route at 1 credit per request.", "operationId": "getHip3OracleExternalPrice", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol with builder prefix. Case-sensitive.", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" } ], "responses": { "200": { "description": "HIP-3 oracle external price", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip3OracleExternalPrice" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/oracle/discovery-bounds/{symbol}": { "get": { "tags": [ "HIP-3 Builder Perps - Oracle" ], "summary": "Get HIP-3 oracle discovery bounds", "description": "Get the instantaneous discovery bounds for a HIP-3 market using the current reference price and max leverage. The full ratcheted range can be wider when deployer-specific reset config applies. Live responses currently meter this route at 1 credit per request.", "operationId": "getHip3OracleDiscoveryBounds", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "HIP-3 symbol with builder prefix. Case-sensitive.", "schema": { "type": "string", "example": "km:US500" }, "example": "km:US500" } ], "responses": { "200": { "description": "HIP-3 oracle discovery bounds", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip3OracleDiscoveryBounds" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/outcomes/by-slug/{slug}": { "get": { "tags": [ "HIP-4 Outcomes - Outcomes" ], "summary": "Get HIP-4 outcome by slug", "description": "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/{outcome_id}` with `aggregated_oi` populated when available.", "operationId": "getHip4OutcomeBySlug", "parameters": [ { "name": "slug", "in": "path", "required": true, "description": "HIP-4 outcome or side slug.", "schema": { "type": "string", "example": "btc-above-78213-may-04-0600" }, "example": "btc-above-78213-may-04-0600" } ], "responses": { "200": { "description": "HIP-4 outcome aggregate", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4OutcomeAggregate" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/questions": { "get": { "tags": [ "HIP-4 Outcomes - Questions" ], "summary": "List HIP-4 questions", "description": "List HIP-4 question groupings. A question groups one or more binary outcome markets. Use cursor pagination for full crawls.", "operationId": "listHip4Questions", "parameters": [ { "name": "cursor", "in": "query", "description": "Question ID cursor for pagination.", "schema": { "type": "integer", "format": "int64" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "HIP-4 questions", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4QuestionArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip4/questions/{question_id}": { "get": { "tags": [ "HIP-4 Outcomes - Questions" ], "summary": "Get a single HIP-4 question", "description": "Get one HIP-4 question grouping by question ID.", "operationId": "getHip4Question", "parameters": [ { "name": "question_id", "in": "path", "required": true, "description": "Numeric HIP-4 question ID.", "schema": { "type": "integer", "format": "int64", "example": 0 }, "example": 0 } ], "responses": { "200": { "description": "HIP-4 question", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseHip4Question" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/spot/orderbook/{symbol}/history": { "get": { "tags": [ "Hyperliquid Spot - Order Book" ], "summary": "Get Hyperliquid Spot order book history", "description": "Get historical Hyperliquid Spot L2 order book snapshots for a pair. The route is scoped to Spot pair symbols such as `HYPE-USDC`; do not use core perp symbols or HIP identifiers. Explicit endpoint cost is 5 credits per request.", "operationId": "getHyperliquidSpotOrderbookHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Hyperliquid Spot pair symbol, for example HYPE-USDC.", "schema": { "type": "string", "example": "HYPE-USDC" }, "example": "HYPE-USDC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults depend on the route family.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "depth", "in": "query", "description": "Number of price levels per side.", "schema": { "type": "integer", "example": 20 } } ], "responses": { "200": { "description": "Spot order book snapshots", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseOrderBookArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } }, "security": [ { "ApiKeyAuth": [] } ] } }, "/v1/lighter/liquidations/{symbol}": { "get": { "tags": [ "Lighter - Liquidations" ], "summary": "Get Lighter liquidation events", "description": "Get Lighter liquidation events in a bounded time range using cursor pagination. Lighter liquidations are available only from the start of live capture; no public historical backfill is available before that window. Explicit endpoint cost is 3 credits per request.", "operationId": "getLighterLiquidations", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Lighter market symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults depend on the route family.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } } ], "responses": { "200": { "description": "Lighter liquidation events", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLighterLiquidationArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/lighter/liquidations/{symbol}/volume": { "get": { "tags": [ "Lighter - Liquidations" ], "summary": "Get Lighter liquidation volume", "description": "Get aggregated Lighter liquidation volume in time-bucketed intervals. Long/short classification follows Lighter liquidation trade semantics. Explicit endpoint cost is 3 credits per request.", "operationId": "getLighterLiquidationVolume", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Lighter market symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Start timestamp in Unix milliseconds. Defaults depend on the route family.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "End timestamp in Unix milliseconds. Defaults to now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor for pagination. Use the value from the previous response metadata.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Maximum number of results (default: 100, max: 1000)", "schema": { "type": "integer", "default": 100, "maximum": 1000 } }, { "name": "interval", "in": "query", "description": "Aggregation interval. Defaults to 1h.", "schema": { "type": "string", "enum": [ "5m", "15m", "30m", "1h", "4h", "1d" ], "default": "1h" } } ], "responses": { "200": { "description": "Lighter liquidation volume buckets", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationVolumeArray" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/wallets/classify": { "get": { "tags": [ "Hyperliquid - Wallets" ], "summary": "Classify Hyperliquid wallets", "description": "Return precomputed daily behavioral metrics for active Hyperliquid wallets with filtering, sorting, and pagination. Explicit endpoint cost is 10 credits per request, with row-based metering applied to returned wallet count where enabled.", "operationId": "classifyHyperliquidWallets", "parameters": [ { "name": "min_orders", "in": "query", "description": "Minimum order count. Default 100.", "schema": { "type": "integer", "format": "int64", "default": 100 } }, { "name": "min_volume_usd", "in": "query", "description": "Minimum fill volume in USD.", "schema": { "type": "number", "default": 0 } }, { "name": "sort", "in": "query", "description": "Metric to sort by.", "schema": { "type": "string", "default": "total_orders", "enum": [ "total_orders", "total_fills", "total_volume", "total_volume_usd", "cancel_rate", "fill_rate", "maker_ratio", "avg_order_size_usd", "avg_order_notional", "max_order_size_usd", "max_order_notional", "active_hours", "unique_coins", "total_fees", "total_fees_usd", "realized_pnl", "realized_pnl_usd", "median_cancel_speed_ms", "twap_fills", "total_priority_gas", "total_priority_gas_paid", "total_builder_fees", "total_builder_fees_paid" ] } }, { "name": "order", "in": "query", "description": "Sort order.", "schema": { "type": "string", "default": "desc", "enum": [ "asc", "desc" ] } }, { "name": "limit", "in": "query", "description": "Maximum wallets to return (default: 100, max: 1000).", "schema": { "type": "integer", "default": 100, "minimum": 1, "maximum": 1000 } }, { "name": "offset", "in": "query", "description": "Pagination offset. Capped at 100000.", "schema": { "type": "integer", "default": 0, "maximum": 100000 } }, { "name": "uses_twap", "in": "query", "description": "Filter wallets by TWAP usage.", "schema": { "type": "boolean" } }, { "name": "uses_priority_gas", "in": "query", "description": "Filter wallets by priority-gas usage.", "schema": { "type": "boolean" } }, { "name": "min_cancel_rate", "in": "query", "description": "Minimum cancel rate, from 0.0 to 1.0.", "schema": { "type": "number", "minimum": 0, "maximum": 1 } }, { "name": "max_cancel_rate", "in": "query", "description": "Maximum cancel rate, from 0.0 to 1.0.", "schema": { "type": "number", "minimum": 0, "maximum": 1 } }, { "name": "date", "in": "query", "description": "Daily snapshot date (YYYY-MM-DD). Defaults to yesterday.", "schema": { "type": "string", "format": "date", "example": "2026-06-16" } } ], "responses": { "200": { "description": "Wallet classification results", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseWalletClassifyData" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/wallets/classify": { "get": { "tags": [ "HIP-3 Builder Perps - Wallets" ], "summary": "Classify HIP-3 wallets", "description": "Return precomputed daily behavioral metrics for active HIP-3 wallets with filtering, sorting, and pagination. Explicit endpoint cost is 10 credits per request, with row-based metering applied to returned wallet count where enabled.", "operationId": "classifyHip3Wallets", "parameters": [ { "name": "min_orders", "in": "query", "description": "Minimum order count. Default 100.", "schema": { "type": "integer", "format": "int64", "default": 100 } }, { "name": "min_volume_usd", "in": "query", "description": "Minimum fill volume in USD.", "schema": { "type": "number", "default": 0 } }, { "name": "sort", "in": "query", "description": "Metric to sort by.", "schema": { "type": "string", "default": "total_orders", "enum": [ "total_orders", "total_fills", "total_volume", "total_volume_usd", "cancel_rate", "fill_rate", "maker_ratio", "avg_order_size_usd", "avg_order_notional", "max_order_size_usd", "max_order_notional", "active_hours", "unique_coins", "total_fees", "total_fees_usd", "realized_pnl", "realized_pnl_usd", "median_cancel_speed_ms", "twap_fills", "total_priority_gas", "total_priority_gas_paid", "total_builder_fees", "total_builder_fees_paid" ] } }, { "name": "order", "in": "query", "description": "Sort order.", "schema": { "type": "string", "default": "desc", "enum": [ "asc", "desc" ] } }, { "name": "limit", "in": "query", "description": "Maximum wallets to return (default: 100, max: 1000).", "schema": { "type": "integer", "default": 100, "minimum": 1, "maximum": 1000 } }, { "name": "offset", "in": "query", "description": "Pagination offset. Capped at 100000.", "schema": { "type": "integer", "default": 0, "maximum": 100000 } }, { "name": "uses_twap", "in": "query", "description": "Filter wallets by TWAP usage.", "schema": { "type": "boolean" } }, { "name": "uses_priority_gas", "in": "query", "description": "Filter wallets by priority-gas usage.", "schema": { "type": "boolean" } }, { "name": "min_cancel_rate", "in": "query", "description": "Minimum cancel rate, from 0.0 to 1.0.", "schema": { "type": "number", "minimum": 0, "maximum": 1 } }, { "name": "max_cancel_rate", "in": "query", "description": "Maximum cancel rate, from 0.0 to 1.0.", "schema": { "type": "number", "minimum": 0, "maximum": 1 } }, { "name": "date", "in": "query", "description": "Daily snapshot date (YYYY-MM-DD). Defaults to yesterday.", "schema": { "type": "string", "format": "date", "example": "2026-06-16" } } ], "responses": { "200": { "description": "HIP-3 wallet classification results", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseWalletClassifyData" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/symbols": { "get": { "tags": [ "System" ], "summary": "List public symbols", "description": "List the public market symbol universe across supported 0xArchive venue families. This no-auth feed powers website discovery and can be used before choosing a venue-specific route. It is a public utility route, not a legacy alias.", "operationId": "listSymbols", "security": [], "parameters": [], "responses": { "200": { "description": "Public symbol universe", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SymbolsResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/stats": { "get": { "tags": [ "System" ], "summary": "Get public API stats", "description": "Get lightweight public statistics used by website/product surfaces. This is a no-auth public utility route, not a legacy alias.", "operationId": "getPublicStats", "security": [], "parameters": [], "responses": { "200": { "description": "Public statistics", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/StatsResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/status/coverage": { "get": { "tags": [ "System" ], "summary": "Get public coverage status", "description": "Get the public coverage summary used by status and discovery surfaces. Response is cached by the API for five minutes. This no-auth public utility route reuses the data-quality coverage shape and is not a legacy alias.", "operationId": "getPublicCoverageStatus", "security": [], "parameters": [], "responses": { "200": { "description": "Public coverage status", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CoverageResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/auth/web3/verify": { "post": { "tags": [ "Web3 Authentication" ], "summary": "Verify SIWE signature", "description": "Verify a signed SIWE message for an existing active wallet account, consume the single-use nonce, and set auth cookies for browser/session flows. Unknown wallets receive HTTP 403 with `wallet_account_required`; verification never creates a Free account. Standard Free signup is available at https://0xarchive.io/signup and paid wallet access at `/v1/web3/subscribe`.", "operationId": "web3Verify", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3VerifyRequest" } } } }, "responses": { "200": { "description": "SIWE verification succeeded and session cookies were set.", "headers": { "Set-Cookie": { "schema": { "type": "string" }, "description": "Authentication cookies for browser/session clients." } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3AuthResponse" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "403": { "description": "The wallet does not have an existing account.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Web3ErrorResponse" }, "example": { "code": 403, "error": "This wallet does not have an existing account. Use standard signup for Free access or purchase paid wallet access.", "error_code": "wallet_account_required", "request_id": "00000000-0000-0000-0000-000000000000" } } } }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/liquidations/{symbol}/levels/history": { "get": { "tags": [ "Hyperliquid - Liquidations" ], "summary": "Get Hyperliquid liquidation levels history", "description": "Historical liquidation-levels snapshots (about every 5 minutes, retained from 2026-07-27), ascending by `snapshot_ts`. Cursor pagination: pass `start`/`end`/`limit` and follow `meta.next_cursor` as the `cursor` parameter. `summary=true` omits only `levels` while retaining `snapshot_ts`, `block_number`, `mid_price`, `total_long`, `total_short`, and `flagged_notional`.", "operationId": "getHyperliquidLiquidationLevelsHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Range start, epoch milliseconds inclusive. Default: 24 hours before end.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "Range end, epoch milliseconds inclusive. Default: now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor from meta.next_cursor of the previous page (a snapshot_ts in epoch milliseconds, exclusive). The page continues strictly after it.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Snapshots per page. Default 24, maximum 100. When a page is full, meta.next_cursor carries the cursor for the next page.", "schema": { "type": "integer", "default": 24, "minimum": 1, "maximum": 100 } }, { "name": "summary", "in": "query", "description": "When true, omits only `levels` while retaining `snapshot_ts`, `block_number`, `mid_price`, `total_long`, `total_short`, and `flagged_notional`. Cheap way to discover which snapshots exist before fetching full histograms.", "schema": { "type": "boolean", "default": false } }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get Hyperliquid liquidation levels history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationLevelsHistory" }, "examples": { "historical": { "summary": "Representative historical response after proportional re-binning", "value": { "success": true, "data": [ { "snapshot_ts": "2026-08-05 14:03:07.000", "block_number": 1099000000, "mid_price": 64281, "total_long": 792122474.4, "total_short": 875697280.92, "flagged_notional": 137629962.54, "levels": [ { "price": 58495.71, "long_notional": 89531699.15, "short_notional": 0, "long_count": 1328, "short_count": 0 }, { "price": 59781.33, "long_notional": 25152539.49, "short_notional": 0, "long_count": 624, "short_count": 0 }, { "price": 61066.95, "long_notional": 37926175.04, "short_notional": 0, "long_count": 795, "short_count": 0 }, { "price": 62352.57, "long_notional": 26595035.98, "short_notional": 0, "long_count": 1019, "short_count": 0 }, { "price": 63638.19, "long_notional": 26376652.21, "short_notional": 0, "long_count": 1143, "short_count": 0 }, { "price": 64923.81, "long_notional": 0, "short_notional": 158162269.8, "long_count": 0, "short_count": 3049 }, { "price": 66209.43, "long_notional": 0, "short_notional": 42138204.92, "long_count": 0, "short_count": 1201 }, { "price": 67495.05, "long_notional": 0, "short_notional": 98948611.74, "long_count": 0, "short_count": 641 }, { "price": 68780.67, "long_notional": 0, "short_notional": 46481321.12, "long_count": 0, "short_count": 750 }, { "price": 70066.29, "long_notional": 0, "short_notional": 134790633.49, "long_count": 0, "short_count": 1031 } ] } ], "meta": { "count": 1, "next_cursor": null, "request_id": "e5f6a7b8-c9d0-4123-8def-123456789abc" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/liquidations/{symbol}/levels/history": { "get": { "tags": [ "HIP-3 - Liquidations" ], "summary": "Get HIP-3 liquidation levels history", "description": "Historical liquidation-levels snapshots (about every 5 minutes, retained from 2026-07-27), ascending by `snapshot_ts`. Cursor pagination: pass `start`/`end`/`limit` and follow `meta.next_cursor` as the `cursor` parameter. `summary=true` omits only `levels` while retaining `snapshot_ts`, `block_number`, `mid_price`, `total_long`, `total_short`, and `flagged_notional`.", "operationId": "getHip3LiquidationLevelsHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "xyz:TSLA" }, "example": "xyz:TSLA" }, { "name": "start", "in": "query", "description": "Range start, epoch milliseconds inclusive. Default: 24 hours before end.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "Range end, epoch milliseconds inclusive. Default: now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor from meta.next_cursor of the previous page (a snapshot_ts in epoch milliseconds, exclusive). The page continues strictly after it.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Snapshots per page. Default 24, maximum 100. When a page is full, meta.next_cursor carries the cursor for the next page.", "schema": { "type": "integer", "default": 24, "minimum": 1, "maximum": 100 } }, { "name": "summary", "in": "query", "description": "When true, omits only `levels` while retaining `snapshot_ts`, `block_number`, `mid_price`, `total_long`, `total_short`, and `flagged_notional`. Cheap way to discover which snapshots exist before fetching full histograms.", "schema": { "type": "boolean", "default": false } }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get HIP-3 liquidation levels history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseLiquidationLevelsHistory" }, "examples": { "historical": { "summary": "Representative historical response after proportional re-binning", "value": { "success": true, "data": [ { "snapshot_ts": "2026-08-05 14:03:07.000", "block_number": 1099000000, "mid_price": 325.07, "total_long": 9851910.14, "total_short": 12394193.54, "flagged_notional": 15392787.78, "levels": [ { "price": 295.8137, "long_notional": 124883.12, "short_notional": 0, "long_count": 33, "short_count": 0 }, { "price": 302.3151, "long_notional": 106188.67, "short_notional": 0, "long_count": 51, "short_count": 0 }, { "price": 308.8165, "long_notional": 76139.52, "short_notional": 0, "long_count": 14, "short_count": 0 }, { "price": 315.3179, "long_notional": 48138.32, "short_notional": 0, "long_count": 47, "short_count": 0 }, { "price": 321.8193, "long_notional": 1856.47, "short_notional": 0, "long_count": 5, "short_count": 0 }, { "price": 328.3207, "long_notional": 0, "short_notional": 870.54, "long_count": 0, "short_count": 2 }, { "price": 334.8221, "long_notional": 0, "short_notional": 32169.58, "long_count": 0, "short_count": 11 }, { "price": 341.3235, "long_notional": 0, "short_notional": 17878.85, "long_count": 0, "short_count": 1 }, { "price": 347.8249, "long_notional": 0, "short_notional": 25706.21, "long_count": 0, "short_count": 9 }, { "price": 354.3263, "long_notional": 0, "short_notional": 1654.61, "long_count": 0, "short_count": 10 } ] } ], "meta": { "count": 1, "next_cursor": null, "request_id": "f6a7b8c9-d0e1-4234-9efa-23456789abcd" } } } } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orders/{symbol}/trigger-levels": { "get": { "tags": [ "Hyperliquid - Orders" ], "summary": "Get Hyperliquid trigger levels", "description": "Currently pending stop-loss and take-profit trigger orders grouped into price buckets near the current mid/mark price. These are voluntary trigger orders, not projected forced liquidations; for forced-liquidation levels use /liquidations/{symbol}/levels. Current-state map with an as_of freshness timestamp. Historical snapshots (15-minute cadence, retained from 2026-07-27) are at the /history variant.", "operationId": "getHyperliquidTriggerLevels", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get Hyperliquid trigger levels", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTriggerLevels" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orders/{symbol}/trigger-levels": { "get": { "tags": [ "HIP-3 - Orders" ], "summary": "Get HIP-3 trigger levels", "description": "Currently pending stop-loss and take-profit trigger orders grouped into price buckets near the current mid/mark price. These are voluntary trigger orders, not projected forced liquidations; for forced-liquidation levels use /liquidations/{symbol}/levels. Current-state map with an as_of freshness timestamp. Historical snapshots (15-minute cadence, retained from 2026-07-27) are at the /history variant.", "operationId": "getHip3TriggerLevels", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "xyz:TSLA" }, "example": "xyz:TSLA" }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get HIP-3 trigger levels", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTriggerLevels" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/orders/{symbol}/trigger-levels/history": { "get": { "tags": [ "Hyperliquid - Orders" ], "summary": "Get Hyperliquid trigger levels history", "description": "Historical trigger-levels snapshots (15-minute cadence, retained from 2026-07-27), ascending by snapshot_ts. Cursor pagination: pass start/end/limit and follow meta.next_cursor as the cursor parameter. summary=true lists snapshots cheaply without histograms.", "operationId": "getHyperliquidTriggerLevelsHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "BTC" }, "example": "BTC" }, { "name": "start", "in": "query", "description": "Range start, epoch milliseconds inclusive. Default: 24 hours before end.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "Range end, epoch milliseconds inclusive. Default: now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor from meta.next_cursor of the previous page (a snapshot_ts in epoch milliseconds, exclusive). The page continues strictly after it.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Snapshots per page. Default 24, maximum 100. When a page is full, meta.next_cursor carries the cursor for the next page.", "schema": { "type": "integer", "default": 24, "minimum": 1, "maximum": 100 } }, { "name": "summary", "in": "query", "description": "When true, items contain snapshot_ts, mid price and totals only (no levels array). Cheap way to discover which snapshots exist before fetching full histograms.", "schema": { "type": "boolean", "default": false } }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get Hyperliquid trigger levels history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTriggerLevelsHistory" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } }, "/v1/hyperliquid/hip3/orders/{symbol}/trigger-levels/history": { "get": { "tags": [ "HIP-3 - Orders" ], "summary": "Get HIP-3 trigger levels history", "description": "Historical trigger-levels snapshots (15-minute cadence, retained from 2026-07-27), ascending by snapshot_ts. Cursor pagination: pass start/end/limit and follow meta.next_cursor as the cursor parameter. summary=true lists snapshots cheaply without histograms.", "operationId": "getHip3TriggerLevelsHistory", "parameters": [ { "name": "symbol", "in": "path", "required": true, "description": "Trading pair symbol.", "schema": { "type": "string", "example": "xyz:TSLA" }, "example": "xyz:TSLA" }, { "name": "start", "in": "query", "description": "Range start, epoch milliseconds inclusive. Default: 24 hours before end.", "schema": { "type": "integer", "format": "int64" } }, { "name": "end", "in": "query", "description": "Range end, epoch milliseconds inclusive. Default: now.", "schema": { "type": "integer", "format": "int64" } }, { "name": "cursor", "in": "query", "description": "Cursor from meta.next_cursor of the previous page (a snapshot_ts in epoch milliseconds, exclusive). The page continues strictly after it.", "schema": { "type": "string" } }, { "name": "limit", "in": "query", "description": "Snapshots per page. Default 24, maximum 100. When a page is full, meta.next_cursor carries the cursor for the next page.", "schema": { "type": "integer", "default": 24, "minimum": 1, "maximum": 100 } }, { "name": "summary", "in": "query", "description": "When true, items contain snapshot_ts, mid price and totals only (no levels array). Cheap way to discover which snapshots exist before fetching full histograms.", "schema": { "type": "boolean", "default": false } }, { "name": "range_pct", "in": "query", "description": "Percentage range around the snapshot mid/mark price. Clamped between 1 and 50. Default 10.", "schema": { "type": "number", "default": 10, "minimum": 1, "maximum": 50 } }, { "name": "buckets", "in": "query", "description": "Number of price buckets. Clamped between 10 and 200. Default 50.", "schema": { "type": "integer", "default": 50, "minimum": 10, "maximum": 200 } }, { "name": "side", "in": "query", "description": "Optional side filter. bid/buy/B keeps the long (or bid) side, ask/sell/A keeps the short (or ask) side; the other side is zeroed.", "schema": { "type": "string", "enum": [ "bid", "ask", "buy", "sell", "B", "A" ] } } ], "responses": { "200": { "description": "Get HIP-3 trigger levels history", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ApiResponseTriggerLevelsHistory" } } } }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/Unauthorized" }, "429": { "$ref": "#/components/responses/RateLimited" } } } } }, "components": { "securitySchemes": { "ApiKeyAuth": { "type": "apiKey", "in": "header", "name": "X-API-Key", "description": "API key for authentication. Get yours at https://0xarchive.io/dashboard" } }, "schemas": { "ApiMeta": { "type": "object", "description": "Response metadata", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination (timestamp). Use this value as the `cursor` parameter to fetch the next page of results." }, "request_id": { "type": "string", "format": "uuid", "description": "Unique request ID for support" }, "coverage_from": { "type": "string", "format": "date-time", "description": "Earliest coverage for the requested symbol and data type. Present only when the requested window ends before coverage begins." }, "notice": { "type": "string", "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." } } }, "ApiResponseOrderBook": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/OrderBook" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseOrderBookArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/OrderBook" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseTradeArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Trade" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseInstrument": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Instrument" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseInstrumentArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Instrument" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseLighterInstrument": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/LighterInstrument" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseLighterInstrumentArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/LighterInstrument" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseOpenInterest": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/OpenInterest" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseOpenInterestArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/OpenInterest" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseFundingRate": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/FundingRate" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseFundingRateArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/FundingRate" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "BreadthCounts": { "type": "object", "description": "Auditable counts behind an aggregate HIP-3 breadth snapshot.", "required": [ "candidates", "eligible", "above", "at", "below", "excluded_no_session_volume", "excluded_stale_price" ], "properties": { "candidates": { "type": "integer", "format": "int32", "minimum": 0, "description": "Candidate instruments considered for the snapshot." }, "eligible": { "type": "integer", "format": "int32", "minimum": 0, "description": "Eligible instruments included in the headline percentage." }, "above": { "type": "integer", "format": "int32", "minimum": 0, "description": "Eligible instruments trading above their current UTC-session VWAP." }, "at": { "type": "integer", "format": "int32", "minimum": 0, "description": "Eligible instruments at their current UTC-session VWAP." }, "below": { "type": "integer", "format": "int32", "minimum": 0, "description": "Eligible instruments trading below their current UTC-session VWAP." }, "excluded_no_session_volume": { "type": "integer", "format": "int32", "minimum": 0, "description": "Candidates excluded because the current UTC session has no qualifying volume." }, "excluded_stale_price": { "type": "integer", "format": "int32", "minimum": 0, "description": "Candidates excluded because their price was stale." } } }, "BreadthNamespaceCounts": { "type": "object", "description": "Per-builder-namespace count breakdowns keyed by namespace.", "required": [ "eligible", "above", "at", "below" ], "properties": { "eligible": { "type": "object", "additionalProperties": { "type": "integer", "format": "int32", "minimum": 0 }, "description": "Eligible instrument counts by builder namespace." }, "above": { "type": "object", "additionalProperties": { "type": "integer", "format": "int32", "minimum": 0 }, "description": "Above-VWAP counts by builder namespace." }, "at": { "type": "object", "additionalProperties": { "type": "integer", "format": "int32", "minimum": 0 }, "description": "At-VWAP counts by builder namespace." }, "below": { "type": "object", "additionalProperties": { "type": "integer", "format": "int32", "minimum": 0 }, "description": "Below-VWAP counts by builder namespace." } } }, "BreadthSnapshot": { "type": "object", "description": "Aggregate percentage of eligible HIP-3 instruments trading above their current UTC-session VWAP. Per-symbol VWAPs are not served.", "required": [ "session_date", "calculated_at", "value_pct", "coverage_ratio", "counts", "namespaces" ], "properties": { "session_date": { "type": "string", "format": "date", "description": "UTC session date." }, "calculated_at": { "type": "string", "format": "date-time", "description": "Timestamp when this snapshot was calculated." }, "value_pct": { "type": "number", "format": "double", "nullable": true, "description": "100 times above divided by eligible; null when eligible is zero." }, "coverage_ratio": { "type": "number", "format": "double", "minimum": 0, "maximum": 1, "description": "Eligible divided by candidates, constrained to the range 0..1." }, "counts": { "$ref": "#/components/schemas/BreadthCounts" }, "namespaces": { "$ref": "#/components/schemas/BreadthNamespaceCounts" } } }, "ApiResponseBreadthSnapshot": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/BreadthSnapshot" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseBreadthSnapshotArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/BreadthSnapshot" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "OrderBook": { "type": "object", "description": "L2 order book snapshot", "required": [ "symbol", "coin", "timestamp", "bids", "asks" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp (UTC)", "example": "2025-01-21T10:30:45.123Z" }, "bids": { "type": "array", "description": "Bid price levels (best bid first)", "items": { "$ref": "#/components/schemas/PriceLevel" } }, "asks": { "type": "array", "description": "Ask price levels (best ask first)", "items": { "$ref": "#/components/schemas/PriceLevel" } }, "mid_price": { "type": "string", "description": "Mid price (best bid + best ask) / 2", "example": "42150.50" }, "spread": { "type": "string", "description": "Spread in absolute terms (best ask - best bid)", "example": "1.00" }, "spread_bps": { "type": "string", "description": "Spread in basis points", "example": "2.37" } } }, "PriceLevel": { "type": "object", "description": "Single price level in the order book", "required": [ "px", "sz", "n" ], "properties": { "px": { "type": "string", "description": "Price", "example": "42150.00" }, "sz": { "type": "string", "description": "Total size at this price level", "example": "1.5" }, "n": { "type": "integer", "description": "Number of orders at this level", "example": 15 } } }, "OrderbookDelta": { "type": "object", "description": "Incremental orderbook change (used with tick-level data)", "required": [ "timestamp", "side", "price", "size", "sequence" ], "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Timestamp in milliseconds", "example": 1704067201000 }, "side": { "type": "string", "enum": [ "bid", "ask" ], "description": "Side of the orderbook (bid or ask)", "example": "bid" }, "price": { "type": "number", "description": "Price level", "example": 50000 }, "size": { "type": "number", "description": "New size at this price level (0 = level removed)", "example": 1.5 }, "sequence": { "type": "integer", "description": "Sequence number for ordering deltas", "example": 12345 } } }, "Trade": { "type": "object", "description": "Trade/fill record with full execution details", "required": [ "symbol", "coin", "side", "price", "size", "timestamp" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "side": { "type": "string", "description": "Trade side: 'B' (buy) or 'A' (sell/ask)", "enum": [ "A", "B" ], "example": "B" }, "price": { "type": "string", "description": "Execution price", "example": "42150.50" }, "size": { "type": "string", "description": "Trade size", "example": "0.5" }, "timestamp": { "type": "string", "format": "date-time", "description": "Execution timestamp (UTC)", "example": "2025-01-21T10:30:45.123Z" }, "tx_hash": { "type": "string", "nullable": true, "description": "Blockchain transaction hash" }, "trade_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Unique trade ID" }, "order_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Associated order ID" }, "crossed": { "type": "boolean", "nullable": true, "description": "True if taker (crossed the spread), false if maker" }, "fee": { "type": "string", "nullable": true, "description": "Trading fee amount" }, "fee_token": { "type": "string", "nullable": true, "description": "Fee denomination (e.g., USDC)" }, "closed_pnl": { "type": "string", "nullable": true, "description": "Realized PnL if closing a position" }, "direction": { "type": "string", "nullable": true, "description": "Position direction (e.g., 'Open Long', 'Close Short', 'Long > Short')" }, "start_position": { "type": "string", "nullable": true, "description": "Position size before this trade" }, "user_address": { "type": "string", "nullable": true, "description": "User's wallet address" }, "maker_address": { "type": "string", "nullable": true, "description": "Maker's wallet address (the resting order)" }, "taker_address": { "type": "string", "nullable": true, "description": "Taker's wallet address (crossed the spread)" }, "builder_address": { "type": "string", "nullable": true, "description": "Builder address that routed this order. Present only when the order was placed through a builder." }, "builder_fee": { "type": "string", "nullable": true, "description": "Builder fee charged on this fill, paid to the builder (in quote currency, typically USDC). Present only when builder_address is set." }, "deployer_fee": { "type": "string", "nullable": true, "description": "HIP-3 deployer fee share on this fill (in quote currency). Negative for the maker side (rebate), positive for the taker side. Present only on HIP-3 fills." }, "priority_gas": { "type": "number", "nullable": true, "description": "Priority fee burned in HYPE (not USDC) for write priority on the Hyperliquid validator queue. Independent of builder_fee and deployer_fee — paid to the network, not to a builder or deployer. Present only when the order paid for priority." }, "cloid": { "type": "string", "nullable": true, "description": "Client order ID" }, "twap_id": { "type": "integer", "nullable": true, "description": "TWAP execution ID" } } }, "Instrument": { "type": "object", "description": "Trading instrument specification (Hyperliquid)", "required": [ "name", "sz_decimals", "is_active" ], "properties": { "name": { "type": "string", "description": "Instrument symbol", "example": "BTC" }, "sz_decimals": { "type": "integer", "description": "Size decimal precision", "example": 4 }, "max_leverage": { "type": "integer", "nullable": true, "description": "Maximum leverage allowed", "example": 50 }, "only_isolated": { "type": "boolean", "nullable": true, "description": "If true, only isolated margin mode is allowed" }, "instrument_type": { "type": "string", "nullable": true, "description": "Type of instrument", "enum": [ "perp", "spot" ], "example": "perp" }, "is_active": { "type": "boolean", "description": "Whether the instrument is currently tradeable", "example": true } } }, "LighterInstrument": { "type": "object", "description": "Trading instrument specification (Lighter). Different schema from Hyperliquid Instrument.", "required": [ "symbol", "market_id", "market_type", "status", "taker_fee", "maker_fee", "liquidation_fee", "min_base_amount", "min_quote_amount", "size_decimals", "price_decimals", "quote_decimals", "is_active" ], "properties": { "symbol": { "type": "string", "description": "Instrument symbol", "example": "ETH" }, "market_id": { "type": "integer", "description": "Unique market identifier", "example": 0 }, "market_type": { "type": "string", "description": "Type of market", "enum": [ "perp", "spot" ], "example": "perp" }, "status": { "type": "string", "description": "Market status", "enum": [ "active", "inactive", "delisted" ], "example": "active" }, "taker_fee": { "type": "number", "description": "Taker fee rate (e.g., 0.0004 = 0.04%)", "example": 0.0004 }, "maker_fee": { "type": "number", "description": "Maker fee rate (can be negative for rebates)", "example": 0.0001 }, "liquidation_fee": { "type": "number", "description": "Liquidation fee rate", "example": 0.005 }, "min_base_amount": { "type": "number", "description": "Minimum order size in base currency", "example": 0.001 }, "min_quote_amount": { "type": "number", "description": "Minimum order value in quote currency", "example": 1 }, "size_decimals": { "type": "integer", "description": "Size decimal precision", "example": 4 }, "price_decimals": { "type": "integer", "description": "Price decimal precision", "example": 2 }, "quote_decimals": { "type": "integer", "description": "Quote currency decimal precision", "example": 6 }, "is_active": { "type": "boolean", "description": "Whether the instrument is currently tradeable", "example": true } } }, "Hip3Instrument": { "type": "object", "description": "HIP-3 Builder Perps instrument with latest market data. Derived from live open interest data.", "required": [ "symbol", "coin", "namespace", "ticker" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "km:US500" }, "coin": { "type": "string", "description": "Full coin name (e.g., km:US500, xyz:XYZ100) (deprecated, use symbol instead)", "example": "km:US500", "deprecated": true }, "namespace": { "type": "string", "description": "Builder namespace (e.g., km, xyz)", "example": "km" }, "ticker": { "type": "string", "description": "Ticker within the namespace (e.g., US500, XYZ100)", "example": "US500" }, "mark_price": { "type": "number", "nullable": true, "description": "Latest mark price", "example": 5432.1 }, "open_interest": { "type": "number", "nullable": true, "description": "Latest open interest", "example": 1234567.89 }, "mid_price": { "type": "number", "nullable": true, "description": "Latest mid price", "example": 5432.05 }, "latest_timestamp": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp of latest data point", "example": "2026-02-18T12:00:00.000Z" } } }, "ApiResponseHip3Instrument": { "type": "object", "description": "API response wrapping a single HIP-3 instrument", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip3Instrument" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip3InstrumentArray": { "type": "object", "description": "API response wrapping an array of HIP-3 instruments", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Hip3Instrument" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "Hip4Outcome": { "type": "object", "description": "HIP-4 per-side instrument metadata. One row per `#N` coin. Each outcome has two sides: side 0 (Yes) and side 1 (No). Public asset_id formula: `100_000_000 + 10*outcome_id + side`. Coin format: `#<10*outcome_id + side>`.", "required": [ "outcome_id", "side", "asset_id", "coin", "symbol" ], "properties": { "outcome_id": { "type": "integer", "format": "int64", "description": "Numeric outcome identifier", "example": 0 }, "side": { "type": "integer", "description": "Side index: 0 = Yes, 1 = No", "enum": [ 0, 1 ], "example": 0 }, "asset_id": { "type": "integer", "format": "int64", "description": "Public asset ID. Formula: `100_000_000 + 10*outcome_id + side`.", "example": 100000000 }, "coin": { "type": "string", "description": "Coin identifier. Returned in `#`-prefixed form. REST paths accept either the bare numeric id (e.g. `0`) or the `#`-prefixed form (e.g. `#0`). Format: `10*outcome_id + side`.", "example": "#0" }, "symbol": { "type": "string", "description": "Same value as `coin`. Provided for consistency with other venues.", "example": "#0" }, "name": { "type": "string", "nullable": true, "description": "Human-readable per-side market name", "example": "BTC ≥ 78213 by 2026-05-03 06:00 UTC — Yes" }, "description": { "type": "string", "nullable": true, "description": "Pipe-delimited recurring-market metadata", "example": "class:priceBinary|underlying:BTC|expiry:20260503-0600|targetPrice:78213|period:1d" }, "side_name": { "type": "string", "nullable": true, "description": "Human label for this side (typically `Yes` or `No`)", "example": "Yes" }, "recurring_class": { "type": "string", "nullable": true, "description": "Recurring market class (e.g., `priceBinary`)", "example": "priceBinary" }, "recurring_underlying": { "type": "string", "nullable": true, "description": "Underlying asset for recurring price-binary outcomes", "example": "BTC" }, "recurring_expiry": { "type": "string", "format": "date-time", "nullable": true, "description": "Settlement timestamp (UTC)", "example": "2026-05-03T06:00:00Z" }, "recurring_target_px": { "type": "number", "nullable": true, "description": "Target price for the binary outcome", "example": 78213 }, "recurring_period": { "type": "string", "nullable": true, "description": "Cadence of the recurring market (e.g., `1d`, `1h`)", "example": "1d" }, "builder_address": { "type": "string", "nullable": true, "description": "Builder wallet address that deployed the outcome", "example": "0x0000000000000000000000000000000000000000" }, "is_settled": { "type": "boolean", "description": "Whether the outcome has settled. Once settled, live tracking ends for the market, but historical data remains queryable.", "example": false }, "settlement_value": { "type": "number", "nullable": true, "description": "Settlement value once the outcome settles (0.0 or 1.0 for binary outcomes). Omitted while unsettled.", "example": 0 }, "settlement_at": { "type": "string", "format": "date-time", "nullable": true, "description": "Settlement timestamp (UTC). Omitted while unsettled.", "example": "2026-05-03T06:00:05.149Z" }, "first_seen_at": { "type": "string", "format": "date-time", "nullable": true, "description": "When this outcome side was first observed by 0xArchive (UTC)", "example": "2026-05-02T07:47:00Z" }, "last_updated_at": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp when the side metadata was last updated", "example": "2026-05-02T20:25:00Z" }, "display_title": { "type": "string", "nullable": true, "description": "Per-side human-readable title, deterministic from parsed metadata.", "example": "BTC above 78,213 on May 3 at 06:00 UTC? — Yes" }, "slug": { "type": "string", "nullable": true, "description": "Per-side URL slug mirroring Hyperliquid's pattern.", "example": "btc-above-78213-yes-may-03-0600" } } }, "Hip4SideSpec": { "type": "object", "description": "Per-side spec nested in `Hip4OutcomeAggregate.side_specs`. One element per side (typically two: side 0 = Yes, side 1 = No).", "required": [ "side", "name", "coin", "asset_id" ], "properties": { "side": { "type": "integer", "description": "Side index: 0 = Yes, 1 = No", "enum": [ 0, 1 ], "example": 0 }, "name": { "type": "string", "description": "Human label for this side", "example": "Yes" }, "coin": { "type": "string", "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`).", "example": "#0" }, "asset_id": { "type": "integer", "format": "int64", "description": "Public asset ID for this side", "example": 100000000 } } }, "Hip4AggregatedOi": { "type": "object", "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).", "required": [ "currency" ], "properties": { "side0_open_interest_contracts": { "type": "number", "nullable": true, "description": "Latest open-interest contracts for side 0 (Yes)", "example": 568048 }, "side1_open_interest_contracts": { "type": "number", "nullable": true, "description": "Latest open-interest contracts for side 1 (No)", "example": 568048 }, "outcome_display_open_interest_contracts": { "type": "number", "nullable": true, "description": "Display total: sum of side0 + side1 OI contracts. Use this for outcome-level OI dashboards.", "example": 1136096 }, "paired_set_supply_contracts": { "type": "number", "nullable": true, "description": "Paired-set supply: minimum of side0 and side1 OI contracts. Represents the count of fully collateralized Yes+No pairs in circulation.", "example": 568048 }, "side_supply_parity": { "type": "boolean", "nullable": true, "description": "True when side0 OI equals side1 OI within tolerance. Parity should hold for binary outcomes; a sustained false value indicates ingestion drift.", "example": true }, "currency": { "type": "string", "description": "Notional currency. Always `USDH` for HIP-4.", "enum": [ "USDH" ], "example": "USDH" }, "as_of": { "type": "string", "format": "date-time", "nullable": true, "description": "Latest timestamp across both sides", "example": "2026-05-02T20:27:21Z" }, "side0_as_of": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp of the side 0 OI sample", "example": "2026-05-02T20:27:21Z" }, "side1_as_of": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp of the side 1 OI sample", "example": "2026-05-02T20:27:21Z" } } }, "Hip4OutcomeAggregate": { "type": "object", "description": "Per-outcome aggregate (both sides combined). Returned by `/outcomes` (list, without `aggregated_oi`) and `/outcomes/{outcome_id}` (detail, with `aggregated_oi` populated).", "required": [ "outcome_id", "side_specs", "is_settled" ], "properties": { "outcome_id": { "type": "integer", "format": "int64", "description": "Numeric outcome identifier", "example": 0 }, "name": { "type": "string", "nullable": true, "description": "Human-readable outcome name (without per-side suffix)", "example": "BTC ≥ 78213 by 2026-05-03 06:00 UTC" }, "description_raw": { "type": "string", "nullable": true, "description": "Pipe-delimited recurring-market metadata as emitted upstream", "example": "class:priceBinary|underlying:BTC|expiry:20260503-0600|targetPrice:78213|period:1d" }, "class": { "type": "string", "nullable": true, "description": "Outcome class (e.g., `priceBinary`)", "example": "priceBinary" }, "underlying": { "type": "string", "nullable": true, "description": "Underlying asset for recurring price-binary outcomes", "example": "BTC" }, "expiry": { "type": "string", "format": "date-time", "nullable": true, "description": "Settlement timestamp (UTC)", "example": "2026-05-03T06:00:00Z" }, "target_price": { "type": "number", "nullable": true, "description": "Target price for the binary outcome", "example": 78213 }, "period": { "type": "string", "nullable": true, "description": "Cadence of the recurring market (e.g., `1d`, `1h`)", "example": "1d" }, "side_specs": { "type": "array", "description": "Per-side specs. Typically two elements: side 0 (Yes) and side 1 (No).", "items": { "$ref": "#/components/schemas/Hip4SideSpec" } }, "is_settled": { "type": "boolean", "description": "Whether the outcome has settled", "example": false }, "status": { "type": "string", "nullable": true, "description": "Lifecycle status (`live`, `settled`, ...)", "example": "live" }, "source_seen_at": { "type": "string", "format": "date-time", "nullable": true, "description": "Last time the outcome was seen upstream", "example": "2026-05-02T20:25:00Z" }, "aggregated_oi": { "allOf": [ { "$ref": "#/components/schemas/Hip4AggregatedOi" } ], "nullable": true, "description": "Display/paired/parity OI aggregates. Populated ONLY on the `/outcomes/{outcome_id}` detail response. Omitted (or null) on the `/outcomes` list response." } } }, "Hip4OpenInterestRecord": { "type": "object", "description": "HIP-4 per-side open-interest record. Mirrors the HIP-3 OI shape and adds `outcome_id` and `side`. `oracle_price` is omitted for HIP-4 (outcomes have no oracle feed). Note: `mark_price` is an implied probability in [0,1], not a USD price; same field name as perps because Hyperliquid upstream uses `markPx` for both.", "required": [ "coin", "symbol", "outcome_id", "side", "timestamp", "open_interest" ], "properties": { "coin": { "type": "string", "description": "`#`-prefixed per-side coin identifier", "example": "#0" }, "symbol": { "type": "string", "description": "Same value as `coin`. Provided for consistency with other venues.", "example": "#0" }, "outcome_id": { "type": "integer", "format": "int64", "description": "Numeric outcome identifier", "example": 0 }, "side": { "type": "integer", "description": "Side index: 0 = Yes, 1 = No", "enum": [ 0, 1 ], "example": 0 }, "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp (UTC)", "example": "2026-05-02T20:27:21Z" }, "open_interest": { "type": "string", "description": "Open interest in contracts (notional currency: USDH)", "example": "568048" }, "mark_price": { "type": "string", "nullable": true, "description": "Implied probability in [0,1], NOT a USD price. Same field name as perps because Hyperliquid upstream uses `markPx` for both.", "example": "0.6502" }, "mid_price": { "type": "string", "nullable": true, "description": "Mid price (probability in [0,1])", "example": "0.65038" } } }, "ApiResponseHip4Outcome": { "type": "object", "description": "API response wrapping a single HIP-4 per-side instrument", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip4Outcome" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4OutcomeArray": { "type": "object", "description": "API response wrapping an array of HIP-4 per-side instruments", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Hip4Outcome" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4OutcomeAggregate": { "type": "object", "description": "API response wrapping a single HIP-4 outcome aggregate (with `aggregated_oi` populated on the detail endpoint)", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip4OutcomeAggregate" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4OutcomeAggregateArray": { "type": "object", "description": "API response wrapping an array of HIP-4 outcome aggregates (without `aggregated_oi`; use `/outcomes/{outcome_id}` for the detail variant)", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Hip4OutcomeAggregate" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4OpenInterest": { "type": "object", "description": "API response wrapping a single HIP-4 per-side open-interest record", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip4OpenInterestRecord" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4OpenInterestArray": { "type": "object", "description": "API response wrapping an array of HIP-4 per-side open-interest records", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Hip4OpenInterestRecord" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "OpenInterest": { "type": "object", "description": "Open interest snapshot with market context", "required": [ "symbol", "coin", "timestamp", "open_interest" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp (UTC)", "example": "2025-01-21T10:30:00.000Z" }, "open_interest": { "type": "string", "description": "Total open interest in contracts", "example": "500000.00" }, "mark_price": { "type": "string", "nullable": true, "description": "Mark price used for liquidations", "example": "42500.50" }, "oracle_price": { "type": "string", "nullable": true, "description": "Oracle price from external feed", "example": "42498.25" }, "day_ntl_volume": { "type": "string", "nullable": true, "description": "24-hour notional volume", "example": "10000000.00" }, "prev_day_price": { "type": "string", "nullable": true, "description": "Price 24 hours ago", "example": "42000.00" }, "mid_price": { "type": "string", "nullable": true, "description": "Current mid price", "example": "42500.75" }, "impact_bid_price": { "type": "string", "nullable": true, "description": "Impact bid price for liquidations" }, "impact_ask_price": { "type": "string", "nullable": true, "description": "Impact ask price for liquidations" } } }, "FundingRate": { "type": "object", "description": "Funding rate record", "required": [ "symbol", "coin", "timestamp", "funding_rate" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Funding timestamp (UTC)", "example": "2025-01-21T08:00:00.000Z" }, "funding_rate": { "type": "string", "description": "Funding rate as a fractional, non-annualized decimal (e.g., 0.0001 = 0.01%)", "example": "0.00025" }, "premium": { "type": "string", "nullable": true, "description": "Premium component of funding rate", "example": "0.0005" } } }, "Candle": { "type": "object", "description": "OHLCV candle data", "required": [ "timestamp", "open", "high", "low", "close", "volume" ], "properties": { "timestamp": { "type": "string", "format": "date-time", "description": "Candle start timestamp (ISO 8601 UTC)", "example": "2026-01-01T12:00:00Z" }, "open": { "type": "number", "format": "double", "description": "Opening price", "example": 42500.5 }, "high": { "type": "number", "format": "double", "description": "Highest price during interval", "example": 42750 }, "low": { "type": "number", "format": "double", "description": "Lowest price during interval", "example": 42300.25 }, "close": { "type": "number", "format": "double", "description": "Closing price", "example": 42650.75 }, "volume": { "type": "number", "format": "double", "description": "Trading volume in base asset", "example": 1250.5 }, "quote_volume": { "type": "number", "format": "double", "description": "Trading volume in quote asset (USD)", "example": 53187500 }, "trade_count": { "type": "integer", "description": "Number of trades in interval", "example": 4520 } } }, "ApiResponseCandleArray": { "type": "object", "description": "API response containing an array of candle data", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Candle" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination" } } } } }, "Liquidation": { "type": "object", "description": "Liquidation event", "required": [ "symbol", "coin", "timestamp", "liquidated_user", "liquidator_user", "price", "size", "side" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Liquidation timestamp (UTC)", "example": "2025-05-21T10:30:00.000Z" }, "liquidated_user": { "type": "string", "description": "Address of the user who was liquidated", "example": "0x84eec0068b37919cc8f13d7454073ac167374cc0" }, "liquidator_user": { "type": "string", "description": "Address of the liquidator (counterparty)", "example": "0x4d969e59b312970cc07af266938a4433ccae0b4c" }, "price": { "type": "string", "description": "Price at which the liquidation was executed", "example": "42500.50" }, "size": { "type": "string", "description": "Size of the liquidated position", "example": "1.5" }, "side": { "type": "string", "description": "Exchange side code for the liquidation-related fill (`A`/`B`). Use `direction` for close/open interpretation, especially on HIP-3.", "example": "B" }, "mark_price": { "type": "string", "nullable": true, "description": "Mark price at time of liquidation", "example": "42480.25" }, "closed_pnl": { "type": "string", "nullable": true, "description": "Realized PnL from the liquidation (usually negative)", "example": "-1250.50" }, "direction": { "type": "string", "nullable": true, "description": "Upstream direction label (for example `Close Long`, `Close Short`; HIP-3 can also emit `Open Long`, `Open Short`, or rare unclassified values such as `Long > Short`)", "example": "Close Long" }, "trade_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Trade ID for this liquidation", "example": 1234567890 }, "tx_hash": { "type": "string", "nullable": true, "description": "Blockchain transaction hash", "example": "0xe266d353038e679c5d7e042433054f0000e1d8e52f7860ecda84573b9b5a02ca" } } }, "ApiResponseLiquidationArray": { "type": "object", "description": "API response containing an array of liquidation events", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Liquidation" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination (format: timestamp_tradeId)" } } } } }, "LiquidationVolume": { "type": "object", "description": "Aggregated liquidation volume for a time bucket", "required": [ "symbol", "coin", "timestamp", "total_usd", "long_usd", "short_usd", "count", "long_count", "short_count" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Bucket start timestamp (UTC)", "example": "2025-05-21T10:00:00.000Z" }, "total_usd": { "type": "number", "description": "Total liquidation volume in USD", "example": 1250000.5 }, "long_usd": { "type": "number", "description": "Long liquidation volume in USD", "example": 750000.25 }, "short_usd": { "type": "number", "description": "Short liquidation volume in USD", "example": 500000.25 }, "count": { "type": "integer", "description": "Total number of liquidations", "example": 42 }, "long_count": { "type": "integer", "description": "Number of long liquidations", "example": 25 }, "short_count": { "type": "integer", "description": "Number of short liquidations", "example": 17 } } }, "ApiResponseLiquidationVolumeArray": { "type": "object", "description": "API response containing an array of aggregated liquidation volumes", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/LiquidationVolume" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination" } } } } }, "DataTypeFreshness": { "type": "object", "description": "Freshness information for a single data type", "properties": { "last_updated": { "type": "string", "format": "date-time", "nullable": true, "description": "When this data type was last updated for the coin", "example": "2026-02-23T12:00:00.000Z" }, "lag_ms": { "type": "integer", "nullable": true, "description": "Current lag in milliseconds between now and last update", "example": 1200 } } }, "CoinFreshness": { "type": "object", "description": "Shared route-family freshness shape. Unsupported data-type buckets may be omitted; consult the operation description for each family.", "required": [ "symbol", "coin", "exchange", "measured_at" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "exchange": { "type": "string", "description": "Exchange name", "example": "hyperliquid" }, "measured_at": { "type": "string", "format": "date-time", "description": "When the freshness was measured", "example": "2026-02-23T12:00:00.000Z" }, "orderbook": { "$ref": "#/components/schemas/DataTypeFreshness" }, "trades": { "$ref": "#/components/schemas/DataTypeFreshness" }, "funding": { "$ref": "#/components/schemas/DataTypeFreshness" }, "open_interest": { "$ref": "#/components/schemas/DataTypeFreshness" }, "liquidations": { "$ref": "#/components/schemas/DataTypeFreshness" } } }, "ApiResponseCoinFreshness": { "type": "object", "description": "API response wrapping coin freshness data", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/CoinFreshness" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "CoinSummary": { "type": "object", "description": "Shared market-summary shape. Route families omit unsupported optional fields; consult the operation description for family-specific applicability.", "required": [ "symbol", "coin", "timestamp" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "timestamp": { "type": "string", "format": "date-time", "description": "Summary timestamp (UTC)", "example": "2026-02-23T12:00:00.000Z" }, "mark_price": { "type": "string", "nullable": true, "description": "Current mark price", "example": "95000.50" }, "oracle_price": { "type": "string", "nullable": true, "description": "Current oracle price", "example": "94998.25" }, "mid_price": { "type": "string", "nullable": true, "description": "Current mid price", "example": "95000.00" }, "funding_rate": { "type": "string", "nullable": true, "description": "Current funding rate", "example": "0.00025" }, "premium": { "type": "string", "nullable": true, "description": "Current premium", "example": "0.0005" }, "open_interest": { "type": "string", "nullable": true, "description": "Current open interest", "example": "500000.00" }, "volume_24h": { "type": "string", "nullable": true, "description": "24-hour notional volume", "example": "10000000.00" }, "liquidation_volume_24h": { "type": "number", "nullable": true, "description": "Total 24h liquidation volume in USD", "example": 2500000 }, "long_liquidation_volume_24h": { "type": "number", "nullable": true, "description": "Long 24h liquidation volume in USD", "example": 1500000 }, "short_liquidation_volume_24h": { "type": "number", "nullable": true, "description": "Short 24h liquidation volume in USD", "example": 1000000 } } }, "ApiResponseCoinSummary": { "type": "object", "description": "API response wrapping a market summary", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/CoinSummary" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "PriceSnapshot": { "type": "object", "description": "Price snapshot with family-applicable price fields. Optional mark, oracle, or mid fields may be omitted when that route family does not supply them.", "required": [ "timestamp" ], "properties": { "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp (UTC)", "example": "2026-02-23T12:00:00.000Z" }, "mark_price": { "type": "string", "nullable": true, "description": "Mark price", "example": "95000.50" }, "oracle_price": { "type": "string", "nullable": true, "description": "Oracle price", "example": "94998.25" }, "mid_price": { "type": "string", "nullable": true, "description": "Mid price", "example": "95000.00" } } }, "ApiResponsePriceSnapshotArray": { "type": "object", "description": "API response containing an array of price snapshots", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/PriceSnapshot" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination" } } } } }, "StatusResponse": { "type": "object", "description": "Overall system status", "properties": { "status": { "type": "string", "enum": [ "operational", "degraded", "outage", "maintenance" ], "description": "Overall system status" }, "updated_at": { "type": "string", "format": "date-time", "description": "When this status was computed" }, "exchanges": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/ExchangeStatus" }, "description": "Per-exchange status" }, "data_types": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/DataTypeStatus" }, "description": "Per-data-type status" }, "active_incidents": { "type": "integer", "description": "Number of active incidents" } } }, "ExchangeStatus": { "type": "object", "description": "Status of a single exchange", "properties": { "status": { "type": "string", "enum": [ "operational", "degraded", "outage", "maintenance" ] }, "last_data_at": { "type": "string", "format": "date-time", "nullable": true, "description": "Timestamp of last received data" }, "latency_ms": { "type": "integer", "nullable": true, "description": "Current latency in milliseconds" } } }, "DataTypeStatus": { "type": "object", "description": "Status of a data type", "properties": { "status": { "type": "string", "enum": [ "operational", "degraded", "outage", "maintenance" ] }, "completeness_24h": { "type": "number", "description": "Data completeness over last 24 hours (0-100)" } } }, "CoverageResponse": { "type": "object", "description": "Overall coverage response", "properties": { "exchanges": { "type": "array", "items": { "$ref": "#/components/schemas/ExchangeCoverageResponse" } } } }, "ExchangeCoverageResponse": { "type": "object", "description": "Coverage for a single exchange", "properties": { "exchange": { "type": "string", "description": "Exchange name" }, "data_types": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/DataTypeCoverage" } } } }, "DataTypeCoverage": { "type": "object", "description": "Coverage for a data type", "properties": { "earliest": { "type": "string", "format": "date-time", "description": "Earliest available data timestamp" }, "latest": { "type": "string", "format": "date-time", "description": "Latest available data timestamp" }, "total_records": { "type": "integer", "format": "int64", "description": "Total number of records" }, "symbols": { "type": "integer", "description": "Number of symbols with data" }, "resolution": { "type": "string", "nullable": true, "description": "Data resolution (e.g., '1.2s', '1m')" }, "lag": { "type": "string", "nullable": true, "description": "Current data lag" }, "completeness": { "type": "number", "description": "Completeness percentage (0-100)" } } }, "SymbolCoverageResponse": { "type": "object", "description": "Per-symbol coverage response with gap detection", "required": [ "exchange", "symbol", "data_types" ], "properties": { "exchange": { "type": "string", "description": "Exchange name" }, "symbol": { "type": "string", "description": "Symbol name" }, "data_types": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/SymbolDataTypeCoverage" } } } }, "SymbolDataTypeCoverage": { "type": "object", "description": "Coverage for a symbol and data type", "required": [ "earliest", "latest", "total_records", "completeness", "gaps" ], "properties": { "earliest": { "type": "string", "format": "date-time" }, "latest": { "type": "string", "format": "date-time" }, "total_records": { "type": "integer", "format": "int64" }, "completeness": { "type": "number", "description": "24-hour completeness percentage (0-100)" }, "historical_coverage": { "type": "number", "description": "Historical coverage percentage (0-100) based on hours with data / total hours in range", "nullable": true }, "gaps": { "type": "array", "items": { "$ref": "#/components/schemas/CoverageGap" }, "description": "Detected data gaps within the requested time window" }, "cadence": { "allOf": [ { "$ref": "#/components/schemas/DataCadence" } ], "nullable": true, "description": "Empirical data cadence measurement (present when sufficient data exists)" } } }, "DataCadence": { "type": "object", "description": "Empirical data cadence measurement based on last 7 days of data", "required": [ "median_interval_seconds", "p95_interval_seconds", "sample_count" ], "properties": { "median_interval_seconds": { "type": "number", "description": "Median interval between consecutive records in seconds" }, "p95_interval_seconds": { "type": "number", "description": "95th percentile interval between consecutive records in seconds" }, "sample_count": { "type": "integer", "format": "int64", "description": "Number of intervals sampled for this measurement" } } }, "CoverageGap": { "type": "object", "description": "A gap in data coverage", "required": [ "start", "end", "duration_minutes" ], "properties": { "start": { "type": "string", "format": "date-time", "description": "Start of gap (last data before gap)" }, "end": { "type": "string", "format": "date-time", "description": "End of gap (first data after gap)" }, "duration_minutes": { "type": "integer", "description": "Gap duration in minutes" } } }, "IncidentsResponse": { "type": "object", "description": "Incidents list response", "properties": { "incidents": { "type": "array", "items": { "$ref": "#/components/schemas/Incident" } }, "pagination": { "$ref": "#/components/schemas/Pagination" } } }, "Incident": { "type": "object", "description": "Data quality incident", "properties": { "id": { "type": "string", "description": "Unique incident ID" }, "status": { "type": "string", "enum": [ "open", "investigating", "identified", "monitoring", "resolved" ] }, "severity": { "type": "string", "enum": [ "minor", "major", "critical" ] }, "exchange": { "type": "string", "nullable": true, "description": "Affected exchange" }, "data_types": { "type": "array", "items": { "type": "string" }, "description": "Affected data types" }, "symbols_affected": { "type": "array", "items": { "type": "string" }, "description": "Affected symbols" }, "started_at": { "type": "string", "format": "date-time" }, "resolved_at": { "type": "string", "format": "date-time", "nullable": true }, "duration_minutes": { "type": "integer", "nullable": true }, "title": { "type": "string" }, "description": { "type": "string", "nullable": true }, "root_cause": { "type": "string", "nullable": true }, "resolution": { "type": "string", "nullable": true }, "records_affected": { "type": "integer", "format": "int64", "nullable": true }, "records_recovered": { "type": "integer", "format": "int64", "nullable": true } } }, "Pagination": { "type": "object", "description": "Pagination info", "properties": { "total": { "type": "integer", "description": "Total number of items" }, "limit": { "type": "integer", "description": "Page size limit" }, "offset": { "type": "integer", "description": "Current offset" } } }, "LatencyResponse": { "type": "object", "description": "Latency metrics response", "properties": { "measured_at": { "type": "string", "format": "date-time" }, "exchanges": { "type": "object", "additionalProperties": { "$ref": "#/components/schemas/ExchangeLatency" } } } }, "ExchangeLatency": { "type": "object", "description": "Latency metrics for an exchange", "properties": { "websocket": { "allOf": [ { "$ref": "#/components/schemas/WebSocketLatency" } ], "nullable": true }, "rest_api": { "allOf": [ { "$ref": "#/components/schemas/ApiLatency" } ], "nullable": true }, "data_freshness": { "$ref": "#/components/schemas/DataFreshness" } } }, "WebSocketLatency": { "type": "object", "properties": { "current_ms": { "type": "integer" }, "avg_1h_ms": { "type": "integer" }, "avg_24h_ms": { "type": "integer" }, "p99_24h_ms": { "type": "integer", "nullable": true } } }, "ApiLatency": { "type": "object", "properties": { "current_ms": { "type": "integer" }, "avg_1h_ms": { "type": "integer" }, "avg_24h_ms": { "type": "integer" } } }, "DataFreshness": { "type": "object", "description": "Data freshness metrics", "properties": { "orderbook_lag_ms": { "type": "integer", "nullable": true }, "fills_lag_ms": { "type": "integer", "nullable": true }, "funding_lag_ms": { "type": "integer", "nullable": true }, "oi_lag_ms": { "type": "integer", "nullable": true } } }, "SlaResponse": { "type": "object", "description": "SLA compliance response", "properties": { "period": { "type": "string", "description": "Period covered (e.g., '2026-01')" }, "sla_targets": { "$ref": "#/components/schemas/SlaTargets" }, "actual": { "$ref": "#/components/schemas/SlaActual" }, "incidents_this_period": { "type": "integer" }, "total_downtime_minutes": { "type": "integer" } } }, "SlaTargets": { "type": "object", "properties": { "uptime": { "type": "number", "description": "Uptime target percentage" }, "data_completeness": { "type": "number", "description": "Data completeness target percentage" }, "api_latency_p99_ms": { "type": "integer", "description": "API P99 latency target in ms" } } }, "SlaActual": { "type": "object", "properties": { "uptime": { "type": "number" }, "uptime_status": { "type": "string", "enum": [ "met", "missed" ] }, "data_completeness": { "$ref": "#/components/schemas/CompletenessMetrics" }, "completeness_status": { "type": "string", "enum": [ "met", "missed" ] }, "api_latency_p99_ms": { "type": "integer" }, "latency_status": { "type": "string", "enum": [ "met", "missed" ] } } }, "CompletenessMetrics": { "type": "object", "properties": { "orderbook": { "type": "number" }, "fills": { "type": "number" }, "funding": { "type": "number" }, "overall": { "type": "number" } } }, "Web3ChallengeRequest": { "type": "object", "required": [ "address" ], "properties": { "address": { "type": "string", "description": "Ethereum wallet address", "example": "0x742d35Cc6634C0532925a3b844Bc9e7595f2bD18" } } }, "Web3ChallengeResponse": { "type": "object", "properties": { "message": { "type": "string", "description": "SIWE message to sign with personal_sign (EIP-191)" }, "nonce": { "type": "string", "description": "Single-use nonce (expires after 10 minutes)" } } }, "Web3KeysRequest": { "type": "object", "required": [ "message", "signature" ], "properties": { "message": { "type": "string", "description": "The SIWE message from the challenge endpoint" }, "signature": { "type": "string", "description": "Hex-encoded signature from personal_sign (0x-prefixed)" } } }, "Web3KeysResponse": { "type": "object", "properties": { "keys": { "type": "array", "items": { "$ref": "#/components/schemas/Web3ApiKey" } }, "wallet_address": { "type": "string", "description": "The wallet address" } } }, "Web3ApiKey": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "description": "Unique key ID" }, "name": { "type": "string", "description": "Key name" }, "key_prefix": { "type": "string", "description": "First characters of the key for identification", "example": "0xa_live_abc1" }, "is_active": { "type": "boolean", "description": "Whether the key is currently active" }, "last_used_at": { "type": "string", "format": "date-time", "nullable": true, "description": "Last usage timestamp" }, "created_at": { "type": "string", "format": "date-time", "description": "Creation timestamp" } } }, "Web3RevokeRequest": { "type": "object", "required": [ "message", "signature", "key_id" ], "properties": { "message": { "type": "string", "description": "The SIWE message from the challenge endpoint" }, "signature": { "type": "string", "description": "Hex-encoded signature from personal_sign (0x-prefixed)" }, "key_id": { "type": "string", "format": "uuid", "description": "UUID of the key to revoke" } } }, "Web3RevokeResponse": { "type": "object", "properties": { "message": { "type": "string", "description": "Confirmation message", "example": "API key revoked successfully" }, "wallet_address": { "type": "string", "description": "The wallet address that owned the key" } } }, "Web3SubscribeRequest": { "type": "object", "required": [ "tier" ], "properties": { "tier": { "type": "string", "enum": [ "build", "pro" ], "description": "Subscription tier to purchase", "example": "build" } } }, "Web3SubscribeResponse": { "type": "object", "properties": { "api_key": { "type": "string", "description": "The generated API key for the new subscription", "example": "0xa_..." }, "tier": { "type": "string", "description": "The subscription tier activated", "example": "build" }, "expires_at": { "type": "string", "format": "date-time", "description": "Subscription expiration date (30 days from purchase)" }, "wallet_address": { "type": "string", "description": "The wallet address associated with the subscription" }, "tx_hash": { "type": "string", "description": "On-chain transaction hash for the USDC transfer (if settled)", "nullable": true } } }, "Error": { "type": "object", "description": "Error response", "properties": { "code": { "type": "integer", "description": "HTTP status code" }, "error": { "type": "string", "description": "Error message" }, "error_code": { "type": "string", "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." }, "request_id": { "type": "string", "format": "uuid", "description": "Unique request ID for support" } } }, "SpotPair": { "type": "object", "description": "Hyperliquid Spot pair metadata.", "additionalProperties": true, "properties": { "symbol": { "type": "string", "example": "HYPE-USDC" }, "base": { "type": "string", "example": "HYPE" }, "quote": { "type": "string", "example": "USDC" } } }, "ApiResponseSpotPair": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/SpotPair" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseSpotPairArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/SpotPair" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "SpotFreshnessBucket": { "type": "object", "description": "Freshness state for one Hyperliquid Spot data type.", "additionalProperties": true, "properties": { "lag_ms": { "type": "integer", "nullable": true, "description": "Measured lag in milliseconds when available.", "example": 440 }, "last_updated": { "type": "string", "nullable": true, "format": "date-time", "description": "Most recent update timestamp when available.", "example": "2026-05-08T21:20:34.837Z" } } }, "SpotFreshness": { "type": "object", "description": "Freshness state for a Hyperliquid Spot pair.", "additionalProperties": true, "required": [ "symbol", "coin", "exchange", "measured_at" ], "properties": { "symbol": { "type": "string", "example": "HYPE-USDC" }, "coin": { "type": "string", "example": "HYPE-USDC" }, "exchange": { "type": "string", "example": "spot" }, "measured_at": { "type": "string", "format": "date-time", "example": "2026-05-08T21:20:35.277945340Z" }, "orderbook": { "$ref": "#/components/schemas/SpotFreshnessBucket" }, "trades": { "$ref": "#/components/schemas/SpotFreshnessBucket" }, "l4_checkpoints": { "$ref": "#/components/schemas/SpotFreshnessBucket" }, "l4_diffs": { "$ref": "#/components/schemas/SpotFreshnessBucket" }, "orders": { "$ref": "#/components/schemas/SpotFreshnessBucket" }, "twap": { "$ref": "#/components/schemas/SpotFreshnessBucket" } } }, "ApiResponseSpotFreshness": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/SpotFreshness" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "SpotTwapRecord": { "type": "object", "description": "Hyperliquid Spot TWAP record. Fields may expand as TWAP coverage fills in for a pair.", "additionalProperties": true }, "ApiResponseSpotTwapArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/SpotTwapRecord" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseGenericArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "type": "object", "additionalProperties": true } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "L2OrderBookDiff": { "type": "object", "description": "Full-depth L2 aggregate diff event derived from L4 deltas", "required": [ "timestamp", "block_number", "side", "price", "size", "count" ], "properties": { "timestamp": { "type": "string", "format": "date-time", "description": "Diff timestamp (UTC)", "example": "2026-06-05T13:53:33.971Z" }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block number for the diff event", "example": 1023882395 }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "Book side: B for bid, A for ask", "example": "B" }, "price": { "type": "number", "description": "Price level changed by this diff", "example": 61088 }, "size": { "type": "number", "description": "Aggregate size at the price level after the diff", "example": 0.40603 }, "count": { "type": "integer", "description": "Number of orders at the price level after the diff", "example": 3 } } }, "ApiResponseL2OrderBookDiffArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/L2OrderBookDiff" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "FullDepthL2OrderBook": { "allOf": [ { "$ref": "#/components/schemas/OrderBook" }, { "type": "object", "description": "0xArchive full-depth aggregated L2 order book snapshot derived from L4 data", "properties": { "bid_levels": { "type": "integer", "description": "Total bid price levels available before any depth truncation", "example": 9842 }, "ask_levels": { "type": "integer", "description": "Total ask price levels available before any depth truncation", "example": 10318 }, "total_bid_size": { "type": "number", "description": "Aggregate bid size across the available full-depth L2 book", "example": 10234.56 }, "total_ask_size": { "type": "number", "description": "Aggregate ask size across the available full-depth L2 book", "example": 9876.54 } } } ] }, "ApiResponseFullDepthL2OrderBook": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/FullDepthL2OrderBook" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseFullDepthL2OrderBookArray": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/FullDepthL2OrderBook" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "CvdBucket": { "type": "object", "description": "Cumulative volume delta bucket.", "required": [ "timestamp", "buy_volume", "sell_volume", "delta", "cumulative_delta" ], "properties": { "timestamp": { "type": "integer", "format": "int64", "description": "Bucket timestamp in Unix milliseconds.", "example": 1781593200000 }, "buy_volume": { "type": "number", "description": "Buy-side volume for the bucket.", "example": 30160211.46768 }, "sell_volume": { "type": "number", "description": "Sell-side volume for the bucket.", "example": 32901130.02649 }, "delta": { "type": "number", "description": "buy_volume minus sell_volume for this bucket.", "example": -2740918.55881 }, "cumulative_delta": { "type": "number", "description": "Running cumulative delta over the returned window.", "example": -2740918.55881 } } }, "ApiResponseCvdBucketArray": { "type": "object", "description": "API response containing CVD buckets.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/CvdBucket" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "LiquidationLevelsData": { "type": "object", "description": "Projected forced-liquidation levels computed from clearinghouse positions and margin state (positions plus maintenance-margin tiers), aggregated into price buckets around the snapshot mark price. Snapshots are computed roughly every 5 minutes; snapshot_ts identifies the snapshot served.", "required": [ "mid_price", "snapshot_ts", "block_number", "total_long", "total_short", "flagged_notional", "source", "levels" ], "properties": { "mid_price": { "type": "number", "description": "Mark price at the snapshot, center of the requested range.", "example": 64215 }, "snapshot_ts": { "type": "string", "description": "UTC snapshot time the levels reflect. Treat snapshots older than 2 hours as stale." }, "block_number": { "type": "integer", "format": "int64", "description": "Hyperliquid block height the snapshot reflects." }, "total_long": { "type": "number", "description": "Total long notional at risk across the whole book, not only the returned window." }, "total_short": { "type": "number", "description": "Total short notional at risk across the whole book." }, "flagged_notional": { "type": "number", "description": "Notional reported in totals but computed approximately or not assigned to a returned bucket. For HIP-3, cross-margined exposure is reported here and excluded from buckets." }, "source": { "type": "string", "enum": [ "raw", "histogram" ], "description": "Snapshot storage form used to answer the request. raw means query-time bins over stored fine-grained levels; histogram means proportional re-binning of a retained base histogram." }, "source_bin_width": { "type": "number", "description": "Stored source-bin width in price units. Present only when source is histogram." }, "levels": { "type": "array", "items": { "$ref": "#/components/schemas/LiquidationLevelBucket" } } } }, "ApiResponseLiquidationLevels": { "type": "object", "description": "API response containing projected forced-liquidation levels for one snapshot.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/LiquidationLevelsData" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "Hip3OracleExternalPrice": { "type": "object", "description": "Latest deployer-pushed external and mark price for a HIP-3 market.", "required": [ "symbol", "block_number", "timestamp" ], "properties": { "symbol": { "type": "string", "description": "HIP-3 symbol.", "example": "km:US500" }, "external_price": { "type": "number", "nullable": true, "description": "Externally derived reference price when available.", "example": 752.24 }, "mark_price": { "type": "number", "nullable": true, "description": "On-chain mark input.", "example": 752.1 }, "block_number": { "type": "integer", "format": "int64", "description": "Source block number.", "example": 1038634032 }, "timestamp": { "type": "integer", "format": "int64", "description": "Source timestamp in Unix milliseconds.", "example": 1781678086894 } } }, "Hip3OracleDiscoveryBounds": { "type": "object", "description": "Instantaneous HIP-3 discovery bounds derived from the current reference price and max leverage.", "required": [ "symbol", "reference_price", "reference_source", "max_leverage", "bound_fraction", "lower_bound", "upper_bound", "block_number", "timestamp" ], "properties": { "symbol": { "type": "string", "description": "HIP-3 symbol.", "example": "km:US500" }, "reference_price": { "type": "number", "description": "External price when available, otherwise mark price.", "example": 752.24 }, "reference_source": { "type": "string", "enum": [ "external", "mark" ], "description": "Price source used for the bounds.", "example": "external" }, "max_leverage": { "type": "integer", "description": "Market max leverage used for the bound fraction.", "example": 20 }, "bound_fraction": { "type": "number", "description": "Fraction applied on each side of reference_price.", "example": 0.05 }, "lower_bound": { "type": "number", "description": "Instantaneous lower discovery bound.", "example": 714.628 }, "upper_bound": { "type": "number", "description": "Instantaneous upper discovery bound.", "example": 789.852 }, "block_number": { "type": "integer", "format": "int64", "description": "Source block number.", "example": 1038634032 }, "timestamp": { "type": "integer", "format": "int64", "description": "Source timestamp in Unix milliseconds.", "example": 1781678086894 } } }, "ApiResponseHip3OracleExternalPrice": { "type": "object", "description": "API response containing HIP-3 oracle external price data.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip3OracleExternalPrice" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip3OracleDiscoveryBounds": { "type": "object", "description": "API response containing HIP-3 oracle discovery bounds.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip3OracleDiscoveryBounds" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "Hip4Question": { "type": "object", "description": "HIP-4 question: multi-choice resolver that groups N binary outcomes under one ballot. One named outcome per choice plus a fallback outcome that wins when no named choice resolves.", "required": [ "question_id", "name", "description", "fallback_outcome_id", "named_outcome_ids", "settled_named_outcomes", "first_seen_at", "last_updated_at" ], "properties": { "question_id": { "type": "integer", "format": "int64", "description": "Question identifier.", "example": 0 }, "name": { "type": "string", "description": "Question name as published on-chain (recurring markets use a generic name such as `Recurring`).", "example": "Recurring" }, "description": { "type": "string", "description": "Pipe-delimited question metadata (class, underlying, expiry, price thresholds, period).", "example": "class:priceBucket|underlying:BTC|expiry:20260508-0600|priceThresholds:79303,82540|period:1d" }, "fallback_outcome_id": { "type": "integer", "format": "int64", "description": "Outcome ID that resolves Yes when no named outcome does.", "example": 6 }, "named_outcome_ids": { "type": "array", "description": "Outcome IDs of the named choices grouped under this question.", "items": { "type": "integer", "format": "int64" }, "example": [ 7, 8, 9 ] }, "settled_named_outcomes": { "type": "array", "description": "Subset of `named_outcome_ids` that have already settled.", "items": { "type": "integer", "format": "int64" }, "example": [] }, "first_seen_at": { "type": "string", "format": "date-time", "description": "When this question was first observed by 0xArchive (UTC).", "example": "2026-05-08T05:57:28.326Z" }, "last_updated_at": { "type": "string", "format": "date-time", "description": "When this question row was last updated (UTC).", "example": "2026-05-08T05:57:28.326Z" } }, "additionalProperties": true }, "ApiResponseHip4Question": { "type": "object", "description": "API response containing one HIP-4 question.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/Hip4Question" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseHip4QuestionArray": { "type": "object", "description": "API response containing HIP-4 questions.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/Hip4Question" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "WalletClassifyMetrics": { "type": "object", "description": "Precomputed wallet behavior metrics.", "additionalProperties": false, "properties": { "total_orders": { "type": "integer", "format": "int64" }, "cancel_rate": { "type": "number" }, "fill_rate": { "type": "number" }, "order_to_trade_ratio": { "type": "number" }, "ioc_ratio": { "type": "number" }, "post_only_ratio": { "type": "number" }, "tpsl_ratio": { "type": "number" }, "trigger_order_ratio": { "type": "number" }, "unique_coins_traded": { "type": "integer", "format": "int64" }, "uses_tpsl": { "type": "boolean" }, "uses_builder": { "type": "boolean" }, "top_builder": { "type": "string", "nullable": true }, "avg_order_size_usd": { "type": "number" }, "max_order_size_usd": { "type": "number" }, "median_cancel_speed_ms": { "type": "number" }, "active_hours": { "type": "integer", "format": "int64" }, "total_fills": { "type": "integer", "format": "int64" }, "total_volume_usd": { "type": "number" }, "maker_ratio": { "type": "number" }, "long_short_ratio": { "type": "number" }, "buy_volume_usd": { "type": "number" }, "sell_volume_usd": { "type": "number" }, "total_fees_usd": { "type": "number" }, "realized_pnl_usd": { "type": "number" }, "liquidation_count": { "type": "integer", "format": "int64" }, "max_single_fill_usd": { "type": "number" }, "unique_fill_coins": { "type": "integer", "format": "int64" }, "uses_twap": { "type": "boolean" }, "twap_fill_ratio": { "type": "number" }, "uses_cloid": { "type": "boolean" }, "cloid_ratio": { "type": "number" }, "uses_priority_gas": { "type": "boolean" }, "total_priority_gas_paid": { "type": "number" }, "total_builder_fees_paid": { "type": "number" } } }, "ClassifiedWallet": { "type": "object", "description": "Wallet plus its precomputed behavior metrics.", "required": [ "address", "metrics", "period" ], "properties": { "address": { "type": "string", "description": "Wallet address.", "example": "0x010461c14e146ac35fe42271bdc1134ee31c703a" }, "metrics": { "$ref": "#/components/schemas/WalletClassifyMetrics" }, "period": { "type": "string", "description": "Metric lookback period.", "example": "24h" } } }, "WalletClassifyData": { "type": "object", "description": "Bulk wallet classification response body.", "required": [ "wallets", "total", "date" ], "properties": { "wallets": { "type": "array", "items": { "$ref": "#/components/schemas/ClassifiedWallet" } }, "total": { "type": "integer", "format": "int64", "description": "Total wallets matching the filters.", "example": 4444 }, "date": { "type": "string", "description": "Daily snapshot date.", "example": "2026-06-16" } } }, "ApiResponseWalletClassifyData": { "type": "object", "description": "API response containing bulk wallet classification results.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/WalletClassifyData" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "SymbolEntry": { "type": "object", "description": "Public market symbol entry.", "required": [ "symbol", "exchange", "data_types" ], "properties": { "symbol": { "type": "string", "example": "BTC" }, "exchange": { "type": "string", "description": "Venue-family key.", "example": "hyperliquid" }, "coverage_from": { "type": "string", "format": "date-time", "nullable": true }, "coverage_to": { "type": "string", "format": "date-time", "nullable": true }, "data_types": { "type": "array", "items": { "type": "string" }, "example": [ "l2_orderbook", "trades", "liquidations" ] }, "coverage_by_type": { "type": "object", "additionalProperties": { "type": "string", "format": "date-time" } }, "size_per_day": { "type": "object", "additionalProperties": { "type": "number" } }, "slug": { "type": "string", "nullable": true, "description": "HIP-4 slug when available." }, "outcome_pair": { "type": "array", "nullable": true, "items": { "type": "string" }, "minItems": 2, "maxItems": 2 }, "display_title": { "type": "string", "nullable": true }, "is_settled": { "type": "boolean", "nullable": true }, "is_active": { "type": "boolean", "nullable": true } }, "additionalProperties": false }, "SymbolsResponse": { "type": "object", "description": "Public symbol universe response.", "required": [ "symbols" ], "properties": { "symbols": { "type": "array", "items": { "$ref": "#/components/schemas/SymbolEntry" } } } }, "StatsResponse": { "type": "object", "description": "Public lightweight API/site statistics.", "properties": { "l4_open_orders": { "type": "integer", "format": "int64", "description": "Current L4 open-order count used by public status/product surfaces.", "example": 1234567 } }, "additionalProperties": true }, "Web3VerifyRequest": { "type": "object", "required": [ "message", "signature" ], "properties": { "message": { "type": "string", "description": "SIWE message returned by `/v1/auth/web3/challenge` and signed by the wallet." }, "signature": { "type": "string", "description": "65-byte hex ECDSA signature, with or without 0x prefix.", "example": "0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" } } }, "Web3UserInfo": { "type": "object", "required": [ "id", "email", "tier", "wallet_address" ], "properties": { "id": { "type": "string", "format": "uuid" }, "email": { "type": "string", "description": "Account email associated with the wallet user." }, "tier": { "type": "string", "description": "Current subscription tier.", "example": "free" }, "wallet_address": { "type": "string", "description": "Authenticated wallet address.", "example": "0x742d35cc6634c0532925a3b844bc9e7595f2bd18" } } }, "Web3AuthResponse": { "type": "object", "description": "Successful SIWE verification response for an existing wallet account. The route also sets auth cookies for browser/session flows.", "required": [ "success", "user", "is_new_user" ], "properties": { "success": { "type": "boolean", "example": true }, "user": { "$ref": "#/components/schemas/Web3UserInfo" }, "is_new_user": { "type": "boolean", "description": "Always false. SIWE verification does not create wallet accounts.", "example": false, "enum": [ false ] } } }, "Web3ErrorResponse": { "type": "object", "required": [ "code", "error", "error_code", "request_id" ], "properties": { "code": { "type": "integer", "format": "int32" }, "error": { "type": "string" }, "error_code": { "type": "string" }, "request_id": { "type": "string" } } }, "Web3SignupRequest": { "type": "object", "description": "Legacy request shape retained for compatibility clients. POST /v1/web3/signup ignores the payload and returns HTTP 410.", "required": [ "message", "signature" ], "properties": { "message": { "type": "string", "description": "Legacy SIWE message field. The retired route does not verify or process it." }, "signature": { "type": "string", "description": "Legacy personal_sign signature field. The retired route does not verify or process it.", "example": "0x..." } } }, "LiquidationLevelBucket": { "type": "object", "description": "One price bucket of projected forced-liquidation exposure.", "required": [ "price", "long_notional", "short_notional", "long_count", "short_count" ], "properties": { "price": { "type": "number", "description": "Bucket center price." }, "long_notional": { "type": "number", "description": "USD notional of long positions projected to liquidate in this bucket." }, "short_notional": { "type": "number", "description": "USD notional of short positions projected to liquidate in this bucket." }, "long_count": { "type": "integer", "description": "Number of long positions in this bucket." }, "short_count": { "type": "integer", "description": "Number of short positions in this bucket." } } }, "LiquidationLevelsHistoryItem": { "type": "object", "description": "One historical liquidation-levels snapshot. levels is omitted when summary=true.", "required": [ "snapshot_ts", "block_number", "mid_price", "total_long", "total_short", "flagged_notional" ], "properties": { "snapshot_ts": { "type": "string" }, "block_number": { "type": "integer", "format": "int64" }, "mid_price": { "type": "number" }, "total_long": { "type": "number" }, "total_short": { "type": "number" }, "flagged_notional": { "type": "number" }, "levels": { "type": "array", "items": { "$ref": "#/components/schemas/LiquidationLevelBucket" } } } }, "ApiResponseLiquidationLevelsHistory": { "type": "object", "description": "Paginated historical liquidation-levels snapshots, ascending by snapshot_ts. When a page is full, meta.next_cursor carries the cursor for the next page.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/LiquidationLevelsHistoryItem" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "TriggerLevel": { "type": "object", "description": "Aggregated currently open trigger orders at one rounded price bucket.", "required": [ "price_bucket", "bid_count", "bid_size", "ask_count", "ask_size" ], "properties": { "price_bucket": { "type": "number", "description": "Rounded trigger price bucket.", "example": 64200 }, "bid_count": { "type": "integer", "format": "int64", "description": "Number of bid-side trigger orders in the bucket.", "example": 12 }, "bid_size": { "type": "number", "description": "Bid-side trigger size in the bucket.", "example": 31.25 }, "ask_count": { "type": "integer", "format": "int64", "description": "Number of ask-side trigger orders in the bucket.", "example": 9 }, "ask_size": { "type": "number", "description": "Ask-side trigger size in the bucket.", "example": 18.75 } } }, "TriggerLevelsData": { "type": "object", "description": "Currently pending stop-loss and take-profit trigger orders grouped into price buckets around the current mid/mark price. Voluntary trigger orders, not projected forced liquidations.", "required": [ "mid_price", "as_of", "total_bid_size", "total_ask_size", "levels" ], "properties": { "mid_price": { "type": "number", "description": "Current mid/mark price, center of the requested range." }, "as_of": { "type": "string", "description": "UTC RFC3339 server time the pending-trigger state was read. The map is current-state; use this to detect staleness." }, "total_bid_size": { "type": "number", "description": "Total pending bid size across the returned window." }, "total_ask_size": { "type": "number", "description": "Total pending ask size across the returned window." }, "levels": { "type": "array", "items": { "$ref": "#/components/schemas/TriggerLevel" } } } }, "ApiResponseTriggerLevels": { "type": "object", "description": "API response containing the pending trigger-order map.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/TriggerLevelsData" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "TriggerLevelsHistoryItem": { "type": "object", "description": "One historical trigger-levels snapshot (15-minute cadence). levels is omitted when summary=true.", "required": [ "snapshot_ts", "mid_price", "total_bid_size", "total_ask_size" ], "properties": { "snapshot_ts": { "type": "string" }, "mid_price": { "type": "number" }, "total_bid_size": { "type": "number" }, "total_ask_size": { "type": "number" }, "levels": { "type": "array", "items": { "$ref": "#/components/schemas/TriggerLevel" } } } }, "ApiResponseTriggerLevelsHistory": { "type": "object", "description": "Paginated historical trigger-levels snapshots, ascending by snapshot_ts. When a page is full, meta.next_cursor carries the cursor for the next page.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/TriggerLevelsHistoryItem" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "LighterTrade": { "type": "object", "description": "Lighter trade (fill) record. Canonical rows (`source: \"bucket\"`) come from the daily Lighter Foundation reconcile and carry full enrichment. The `/recent` endpoint serves preliminary real-time rows (`source: \"ws\"`) without fee/tx_hash/order_id/realized_pnl and the other bucket-only enrichment fields until the daily reconcile finalizes them.", "required": [ "coin", "symbol", "side", "price", "size", "timestamp", "trade_id", "crossed", "source" ], "properties": { "coin": { "type": "string", "description": "Trading pair symbol (deprecated, use symbol instead)", "example": "BTC", "deprecated": true }, "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "side": { "type": "string", "enum": [ "A", "B" ], "description": "Trade side of the account this row belongs to: 'B' (buy) or 'A' (sell/ask)", "example": "B" }, "price": { "type": "string", "description": "Execution price", "example": "64708.5" }, "size": { "type": "string", "description": "Trade size in base units", "example": "0.00005" }, "timestamp": { "type": "string", "format": "date-time", "description": "Execution timestamp (UTC)", "example": "2026-07-26T14:47:59.174Z" }, "tx_hash": { "type": "string", "nullable": true, "description": "Lighter settlement transaction hash (fixed-width hex). Canonical rows only.", "example": "000000197b6fd6e90000019f9ee5a9c6000000000000000000000000000000000000000000000000" }, "trade_id": { "type": "integer", "format": "int64", "description": "Unique Lighter trade ID. Each trade produces two rows (one per counterparty) sharing this ID.", "example": 26121110211 }, "order_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Order ID of this account's order. Canonical rows only.", "example": 844421856609148 }, "crossed": { "type": "boolean", "description": "True if this account was the taker (crossed the spread), false if maker", "example": false }, "fee": { "type": "string", "nullable": true, "description": "This account's fee for the fill. Canonical rows only.", "example": "0.000028" }, "account_index": { "type": "string", "description": "Lighter numeric account index this row belongs to (serialized as a string)", "example": "513030" }, "source": { "type": "string", "enum": [ "bucket", "ws" ], "description": "Row provenance: 'bucket' = canonical (finalized by the daily Lighter Foundation reconcile), 'ws' = preliminary real-time capture", "example": "bucket" }, "position_size_before": { "type": "number", "nullable": true, "description": "This account's signed position size before the fill (long positive, short negative)", "example": -0.94632 }, "position_size_after": { "type": "number", "nullable": true, "description": "Signed position size after the fill (derived: position_size_before plus/minus size by side)", "example": -0.94627 }, "entry_quote_before": { "type": "number", "nullable": true, "description": "This account's position entry quote value before the fill", "example": 61179.114686 }, "initial_margin_fraction_before": { "type": "number", "nullable": true, "description": "This account's initial margin fraction before the fill", "example": 0.02 }, "allocated_margin_before": { "type": "number", "nullable": true, "description": "Isolated-margin allocation before the fill (0 for cross)", "example": 0 }, "allocated_margin_after": { "type": "number", "nullable": true, "description": "Isolated-margin allocation after the fill (0 for cross)", "example": 0 }, "position_sign_changed": { "type": "boolean", "nullable": true, "description": "True if the fill flipped this account's position between long and short", "example": false }, "trade_type": { "type": "string", "nullable": true, "description": "Upstream trade type. Canonical rows only.", "example": "trade" }, "is_maker": { "type": "boolean", "nullable": true, "description": "True if this account was the maker. Canonical rows only.", "example": true }, "counterparty_address": { "type": "string", "nullable": true, "description": "Counterparty's Lighter account index (serialized as a string). Canonical rows only.", "example": "710765" }, "client_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Client-assigned order ID. Canonical rows only.", "example": 46758119273906 }, "realized_pnl": { "type": "number", "nullable": true, "description": "Matching-engine realized PnL for this fill. Canonical rows only.", "example": -0.00295 }, "integrator_fee": { "type": "number", "nullable": true, "description": "Integrator fee charged on the fill. Canonical rows only.", "example": 0 }, "fee_account_id": { "type": "integer", "format": "int64", "nullable": true, "description": "Account credited with the fee. Canonical rows only.", "example": 0 }, "l2_block_height": { "type": "integer", "format": "int64", "nullable": true, "description": "Lighter L2 block height containing the trade. Canonical rows only.", "example": 300075269 }, "transaction_time_us": { "type": "integer", "format": "int64", "nullable": true, "description": "Intra-block transaction time in microseconds. Canonical rows only.", "example": 1785077279174437 }, "usdc_amount": { "type": "number", "nullable": true, "description": "Notional value of the fill in USDC. Canonical rows only.", "example": 3.235425 } } }, "ApiResponseLighterTradeArray": { "type": "object", "description": "API response containing an array of Lighter trades. History responses serve canonical rows only and clamp `end` to `finalized_through`; `/recent` responses serve preliminary rows and report `preliminary_row_count`.", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/LighterTrade" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination. Use this value as the `cursor` parameter to fetch the next page. History endpoint only." }, "request_id": { "type": "string", "format": "uuid", "description": "Unique request ID for support" }, "finalized_through": { "type": "string", "format": "date-time", "description": "Timestamp through which canonical (bucket-reconciled) data is available." }, "requested_end": { "type": "string", "format": "date-time", "nullable": true, "description": "The `end` the caller requested, echoed when it was clamped. History endpoint only." }, "clamped_to": { "type": "string", "format": "date-time", "nullable": true, "description": "Effective end after clamping to `finalized_through`. History endpoint only." }, "preliminary_row_count": { "type": "integer", "nullable": true, "description": "Number of preliminary (`source: \"ws\"`) rows in this response. `/recent` endpoint only." } } } } }, "LighterLiquidation": { "type": "object", "description": "Native Lighter liquidation event. Raw ask/bid account fields are preserved instead of a derived `liquidated_user`: the upstream payload does not reliably flag which side was liquidated, so the liquidated side is derived at read time from position signs. Margin and fee integer fields are raw upstream units.", "required": [ "symbol", "timestamp", "transaction_time_us", "trade_id", "liquidation_type", "price", "size", "usd_amount", "ask_account", "bid_account", "ask_order_id", "bid_order_id", "is_maker_ask", "taker_position_size_before", "maker_position_size_before", "taker_entry_quote_before", "maker_entry_quote_before", "taker_initial_margin_fraction_before", "maker_initial_margin_fraction_before", "taker_allocated_margin_usdc_before", "taker_allocated_margin_usdc_after", "maker_allocated_margin_usdc_before", "maker_allocated_margin_usdc_after", "taker_fee", "maker_fee", "taker_position_sign_changed", "maker_position_sign_changed", "block_height", "tx_hash", "raw_json", "source" ], "properties": { "symbol": { "type": "string", "description": "Trading pair symbol", "example": "BTC" }, "timestamp": { "type": "integer", "format": "int64", "description": "Liquidation timestamp in Unix epoch milliseconds", "example": 1785116108743 }, "transaction_time_us": { "type": "integer", "format": "int64", "description": "Intra-block transaction time in microseconds", "example": 1785116108751813 }, "trade_id": { "type": "integer", "format": "int64", "description": "Unique Lighter trade ID of the liquidation fill", "example": 26144238102 }, "liquidation_type": { "type": "string", "description": "Upstream liquidation type", "example": "liquidation" }, "price": { "type": "number", "description": "Execution price", "example": 64921.9 }, "size": { "type": "number", "description": "Liquidated size in base units", "example": 0.18476 }, "usd_amount": { "type": "number", "description": "Notional value of the liquidation in USD", "example": 11994.970244 }, "ask_account": { "type": "string", "description": "Lighter account index on the ask side (serialized as a string)", "example": "728637" }, "bid_account": { "type": "string", "description": "Lighter account index on the bid side (serialized as a string)", "example": "726722" }, "ask_order_id": { "type": "integer", "format": "int64", "description": "Order ID on the ask side", "example": 562952982931319 }, "bid_order_id": { "type": "integer", "format": "int64", "description": "Order ID on the bid side", "example": 844421854021817 }, "is_maker_ask": { "type": "boolean", "description": "True if the maker was on the ask side", "example": false }, "taker_position_size_before": { "type": "number", "description": "Taker's signed position size before the fill (long positive, short negative)", "example": 0.19771 }, "maker_position_size_before": { "type": "number", "description": "Maker's signed position size before the fill", "example": -1.85452 }, "taker_entry_quote_before": { "type": "number", "description": "Taker's position entry quote value before the fill", "example": 12945.451185 }, "maker_entry_quote_before": { "type": "number", "description": "Maker's position entry quote value before the fill", "example": 120665.315247 }, "taker_initial_margin_fraction_before": { "type": "integer", "description": "Taker's initial margin fraction before the fill (raw upstream units)", "example": 200 }, "maker_initial_margin_fraction_before": { "type": "integer", "description": "Maker's initial margin fraction before the fill (raw upstream units)", "example": 500 }, "taker_allocated_margin_usdc_before": { "type": "integer", "format": "int64", "description": "Taker's isolated-margin USDC allocation before the fill (raw upstream units)", "example": 259232053 }, "taker_allocated_margin_usdc_after": { "type": "integer", "format": "int64", "description": "Taker's isolated-margin USDC allocation after the fill (raw upstream units)", "example": 23859483 }, "maker_allocated_margin_usdc_before": { "type": "integer", "format": "int64", "description": "Maker's isolated-margin USDC allocation before the fill (raw upstream units)", "example": 0 }, "maker_allocated_margin_usdc_after": { "type": "integer", "format": "int64", "description": "Maker's isolated-margin USDC allocation after the fill (raw upstream units)", "example": 0 }, "taker_fee": { "type": "integer", "description": "Taker fee (raw upstream units)", "example": 10000 }, "maker_fee": { "type": "integer", "description": "Maker fee (raw upstream units)", "example": 28 }, "taker_position_sign_changed": { "type": "boolean", "description": "True if the fill flipped the taker's position between long and short", "example": false }, "maker_position_sign_changed": { "type": "boolean", "description": "True if the fill flipped the maker's position between long and short", "example": false }, "block_height": { "type": "integer", "format": "int64", "description": "Lighter L2 block height containing the liquidation", "example": 300340672 }, "tx_hash": { "type": "string", "description": "Lighter settlement transaction hash (fixed-width hex)", "example": "000000198190c10e0000019fa13627c7000000000000000000000000000000000000000000000000" }, "raw_json": { "type": "string", "description": "Raw upstream payload as received from Lighter." }, "source": { "type": "string", "description": "Row provenance", "example": "ws" } } }, "ApiResponseLighterLiquidationArray": { "type": "object", "description": "API response containing an array of native Lighter liquidation events", "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/LighterLiquidation" } }, "meta": { "type": "object", "properties": { "count": { "type": "integer", "description": "Number of records returned" }, "next_cursor": { "type": "string", "nullable": true, "description": "Cursor for pagination (format: timestamp_tradeId)" }, "request_id": { "type": "string", "format": "uuid", "description": "Unique request ID for support" } } } } }, "L4Order": { "type": "object", "description": "Individual resting order in a Hyperliquid-family L4 snapshot.", "required": [ "oid", "user_address", "side", "price", "size", "timestamp" ], "properties": { "oid": { "type": "integer", "format": "int64", "description": "Hyperliquid order identifier.", "example": 18499128731 }, "user_address": { "type": "string", "description": "Address attributed to the resting order.", "example": "0x0000000000000000000000000000000000000000" }, "side": { "type": "string", "enum": [ "B", "A" ], "description": "Book side: B for bid or A for ask.", "example": "B" }, "price": { "type": "number", "description": "Venue-native resting order price.", "example": 105384.5 }, "size": { "type": "number", "description": "Venue-native remaining order size.", "example": 0.824 }, "timestamp": { "type": "integer", "format": "int64", "description": "Queue-join timestamp in Unix epoch milliseconds; 0 when unknown.", "example": 1773273600123 } } }, "L4OrderBookSnapshot": { "type": "object", "description": "Current or reconstructed Hyperliquid-family L4 orderbook snapshot.", "required": [ "coin", "timestamp", "checkpoint_timestamp", "diffs_applied", "last_block_number", "bids", "asks", "bid_count", "ask_count", "total_bid_size", "total_ask_size" ], "properties": { "coin": { "type": "string", "description": "Trading pair or market symbol.", "example": "BTC" }, "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp in UTC.", "example": "2026-03-12T00:00:00.000Z" }, "checkpoint_timestamp": { "type": "string", "format": "date-time", "description": "Timestamp of the checkpoint used for this snapshot.", "example": "2026-03-12T00:00:00.000Z" }, "diffs_applied": { "type": "integer", "description": "Number of L4 diffs applied after the checkpoint.", "example": 0 }, "last_block_number": { "type": "integer", "format": "int64", "description": "Last Hyperliquid block represented by this snapshot.", "example": 1023882395 }, "bids": { "type": "array", "description": "Bid-side resting orders, best price first.", "items": { "$ref": "#/components/schemas/L4Order" } }, "asks": { "type": "array", "description": "Ask-side resting orders, best price first.", "items": { "$ref": "#/components/schemas/L4Order" } }, "bid_count": { "type": "integer", "description": "Number of bid orders in the full stored/reconstructed checkpoint before optional depth truncates returned bids/asks.", "example": 12 }, "ask_count": { "type": "integer", "description": "Number of ask orders in the full stored/reconstructed checkpoint before optional depth truncates returned bids/asks.", "example": 15 }, "total_bid_size": { "type": "number", "description": "Aggregate venue-native bid size in the full stored/reconstructed checkpoint before optional depth truncates returned bids/asks.", "example": 102.34 }, "total_ask_size": { "type": "number", "description": "Aggregate venue-native ask size in the full stored/reconstructed checkpoint before optional depth truncates returned bids/asks.", "example": 98.76 }, "is_crossed": { "type": "boolean", "description": "True only when a reconstructed historical book has best bid greater than or equal to best ask; omitted for clean snapshots.", "example": true } } }, "ApiResponseL4OrderBook": { "type": "object", "required": [ "success", "data", "meta" ], "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/L4OrderBookSnapshot" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseL4OrderBookArray": { "type": "object", "required": [ "success", "data", "meta" ], "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/L4OrderBookSnapshot" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "L3Order": { "type": "object", "description": "Individual resting order in a Lighter L3 snapshot.", "required": [ "order_index", "owner_account_index", "side", "price", "remaining_size", "original_size" ], "properties": { "order_index": { "type": "integer", "format": "int64", "description": "Numeric order index assigned by Lighter.", "example": 562953074779869 }, "owner_account_index": { "type": "integer", "format": "int64", "description": "Numeric Lighter account index associated with the resting order.", "example": 281474976710654 }, "side": { "type": "string", "enum": [ "bid", "ask" ], "description": "Book side.", "example": "bid" }, "price": { "type": "number", "description": "Lighter venue-native resting order price.", "example": 65127.5 }, "remaining_size": { "type": "number", "description": "Remaining venue-native order size.", "example": 0.02303 }, "original_size": { "type": "number", "description": "Original venue-native order size.", "example": 0.02303 } } }, "L3OrderBookSnapshot": { "type": "object", "description": "Current or historical Lighter L3 orderbook snapshot.", "required": [ "coin", "timestamp", "orders", "bid_count", "ask_count", "total_bid_size", "total_ask_size", "mid_price", "spread", "spread_bps", "truncated" ], "properties": { "coin": { "type": "string", "description": "Lighter trading pair symbol.", "example": "BTC" }, "timestamp": { "type": "string", "format": "date-time", "description": "Snapshot timestamp in UTC.", "example": "2026-03-12T00:00:00.000Z" }, "orders": { "type": "array", "description": "Individual resting orders in the served L3 view.", "items": { "$ref": "#/components/schemas/L3Order" } }, "bid_count": { "type": "integer", "description": "Bid order count for the stored checkpoint view.", "example": 250 }, "ask_count": { "type": "integer", "description": "Ask order count for the stored checkpoint view.", "example": 250 }, "total_bid_size": { "type": "number", "description": "Aggregate remaining venue-native size across bids.", "example": 102.34 }, "total_ask_size": { "type": "number", "description": "Aggregate remaining venue-native size across asks.", "example": 98.76 }, "mid_price": { "type": "string", "nullable": true, "description": "Mid price as a decimal string when both sides are present; null otherwise.", "example": "65127.25" }, "spread": { "type": "string", "nullable": true, "description": "Absolute spread as a decimal string when both sides are present; null otherwise.", "example": "0.50" }, "spread_bps": { "type": "string", "nullable": true, "description": "Spread in basis points as a decimal string when both sides are present; null otherwise.", "example": "0.08" }, "truncated": { "type": "boolean", "description": "True when the stored checkpoint reached the 250-orders-per-side ingestion cap.", "example": true } } }, "ApiResponseL3OrderBook": { "type": "object", "required": [ "success", "data", "meta" ], "properties": { "success": { "type": "boolean", "example": true }, "data": { "$ref": "#/components/schemas/L3OrderBookSnapshot" }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } }, "ApiResponseL3OrderBookArray": { "type": "object", "required": [ "success", "data", "meta" ], "properties": { "success": { "type": "boolean", "example": true }, "data": { "type": "array", "items": { "$ref": "#/components/schemas/L3OrderBookSnapshot" } }, "meta": { "$ref": "#/components/schemas/ApiMeta" } } } }, "responses": { "Unauthorized": { "description": "Authentication required", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": 401, "error": "Missing or invalid API key. Provide X-API-Key header." } } } }, "NotFound": { "description": "Resource not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": 404, "error": "Resource not found" } } } }, "RateLimited": { "description": "Rate limit exceeded", "headers": { "X-RateLimit-Limit": { "schema": { "type": "integer" }, "description": "Requests per second limit" }, "X-RateLimit-Remaining": { "schema": { "type": "integer" }, "description": "Remaining requests this second" }, "X-RateLimit-Reset": { "schema": { "type": "integer" }, "description": "Unix timestamp when limit resets" } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": 429, "error": "Rate limit exceeded" } } } }, "BadRequest": { "description": "Invalid request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "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" } } } } } }, "x-0xarchive-docs-overlay": { "name": "hyperliquid-spot", "reason": "Hyperliquid Spot routes are included in the local REST contract.", "source": "live endpoint behavior and public CLI/MCP/Skill surface truth", "updated_at": "2026-05-08", "remove_when": "Public source contract includes the same Spot route family." } }