HyperliquidHyperliquid REST APIMarket data

Get L2 Order Book

Returns Level 2 order book snapshot with aggregated liquidity.

Rate Limit: 2 weight

POST
/v1/info/l2Book

Request Body

application/json

type*enum<string>required

Request type identifier

Available options: l2Book
coin*stringrequired

Trading pair symbol

Example: BTC
nSigFigs?integerdefault: 5

Number of significant figures for price precision

mantissa?integer

Mantissa for price level grouping

dex?stringdefault: ""

Perp dex name for multi-dex support

Response Body

application/json

application/json

curl -X POST "https://api.hypereth.io/v1/info/l2Book" \  -H "Content-Type: application/json" \  -d '{    "type": "l2Book",    "coin": "BTC",    "nSigFigs": 5  }'
{
  "levels": [
    [
      [
        {
          "px": "43250.5",
          "sz": "2.5",
          "n": 3
        }
      ]
    ]
  ],
  "time": 0
}
{
  "error": "Insufficient margin for order placement",
  "code": 1001,
  "details": {}
}