Skip to main content
GET
/
orderbook
Get Aggregated Order Book
curl --request GET \
  --url https://api.dexaggregatorbeta.xyz/orderbook \
  --header 'X-API-KEY: <api-key>'
{
  "symbol": "BTC-USD",
  "timestamp": 123,
  "bids": [
    {
      "price": "<string>",
      "size": "<string>",
      "exchange": "hyperliquid",
      "count": 123
    }
  ],
  "asks": [
    {
      "price": "<string>",
      "size": "<string>",
      "exchange": "hyperliquid",
      "count": 123
    }
  ]
}
Get aggregated order book data across all or selected DEX exchanges. This endpoint provides real-time bid and ask levels with exchange attribution.

Features

  • Multi-exchange aggregation: Combines order book data from multiple DEXes
  • Exchange filtering: Use exchanges[] parameter to filter specific exchanges
  • Configurable depth: Control the number of price levels returned
  • Real-time data: Updated every 100ms for optimal accuracy

Request

  • Method: GET
  • Endpoint: /orderbook
  • Query Parameters: symbol (required), depth, exchanges[]
curl -X GET "https://api.dexaggregatorbeta.xyz/orderbook?symbol=BTC-USD&depth=5" \
  -H "Content-Type: application/json"

Use Cases

  • Display aggregated market depth in trading interfaces
  • Calculate best bid/ask prices across exchanges
  • Analyze liquidity distribution across DEXes
  • Build market making strategies
For real-time order book updates, consider using the WebSocket orderbook:{symbol} topic instead of polling this endpoint.

Authorizations

X-API-KEY
string
header
required

Query Parameters

symbol
string
required

Trading pair symbol

Example:

"BTC-USD"

depth
integer
default:20

Number of price levels to return

Required range: 1 <= x <= 100
exchanges[]
enum<string>[]

Filter by specific exchanges

Available options:
hyperliquid,
aster,
lighter,
avantis

Response

Aggregated order book data

symbol
string
Example:

"BTC-USD"

timestamp
integer

Timestamp in milliseconds

bids
object[]
asks
object[]