Skip to content
UDX
2026-07-15

Get a Market's Order Book

Returns the current aggregated order book for a market.

GET/markets/{ticker}/orderbook
Authorization
Authorization

Optional — this operation also accepts unauthenticated requests.

UDX-Access-KeyAPI key · header

Opaque API key ID.

UDX-Access-TimestampAPI key · header

Unix time in milliseconds, within 30 seconds of server time.

UDX-Access-SignatureAPI key · header

Standard-base64 RSA-PSS/SHA-256 signature with a 32-byte salt.

or
AuthorizationBearer token (JWT) · header

Bearer token for an active signed-in UDX user.

An authenticated request is metered against the member's read bucket and returns RateLimit headers; an unauthenticated request shares the public per-client limit.

Header parameters
Header parameters
UDX-Versionstring

Dated API version (YYYY-MM-DD).

min length 10 · max length 10
Path parameters
tickerTickerrequired

The market's ticker.

min length 1 · max length 128
Query parameters
depthinteger<int32>

Maximum number of price levels to return per side.

min 1 · max 1000
Responses
200The market's aggregated order book.
orderbookOrderbookrequired

The aggregated order book for a market.

Show properties
tickerTickerrequired

A human-meaningful natural key naming a single-leg or multi-leg market.

min length 1 · max length 128
bidsPriceLevel[]required

Bid levels, best first, as [price, quantity] pairs in YES dollars.

max items 1000
asksPriceLevel[]required

Ask levels, best first, as [price, quantity] pairs in YES dollars.

max items 1000
404No market with this ticker exists.
typestring<uri-reference>required

A stable URN identifying the kind of problem, for example urn:udx:problem:insufficient-permissions. Branch on it rather than on the localized detail. It is an identifier, not a URL to dereference.

max length 2048
titlestringrequired

A localized, human-readable summary of the error category. Stable for a given status code and resolved language — clients must not use it as a machine-readable discriminator.

max length 40
statusintegerrequired

The HTTP status code, repeated from the response itself.

detailstring

A localized, human-readable explanation specific to this occurrence. Clients must not parse it for machine-readable information.

max length 500
instancestring<uri-reference>

An identifier for this specific occurrence, so it can be correlated with server-side logs if you need to report it.

max length 100
429The request rate was exceeded. An unauthenticated request shares the public per-client limit; an authenticated request is metered against the member's read bucket.
typestring<uri-reference>required

A stable URN identifying the kind of problem, for example urn:udx:problem:insufficient-permissions. Branch on it rather than on the localized detail. It is an identifier, not a URL to dereference.

max length 2048
titlestringrequired

A localized, human-readable summary of the error category. Stable for a given status code and resolved language — clients must not use it as a machine-readable discriminator.

max length 40
statusintegerrequired

The HTTP status code, repeated from the response itself.

detailstring

A localized, human-readable explanation specific to this occurrence. Clients must not parse it for machine-readable information.

max length 500
instancestring<uri-reference>

An identifier for this specific occurrence, so it can be correlated with server-side logs if you need to report it.

max length 100
500Something went wrong on UDX's side.
typestring<uri-reference>required

A stable URN identifying the kind of problem, for example urn:udx:problem:insufficient-permissions. Branch on it rather than on the localized detail. It is an identifier, not a URL to dereference.

max length 2048
titlestringrequired

A localized, human-readable summary of the error category. Stable for a given status code and resolved language — clients must not use it as a machine-readable discriminator.

max length 40
statusintegerrequired

The HTTP status code, repeated from the response itself.

detailstring

A localized, human-readable explanation specific to this occurrence. Clients must not parse it for machine-readable information.

max length 500
instancestring<uri-reference>

An identifier for this specific occurrence, so it can be correlated with server-side logs if you need to report it.

max length 100
503Request admission is unavailable.
typestring<uri-reference>required

A stable URN identifying the kind of problem, for example urn:udx:problem:insufficient-permissions. Branch on it rather than on the localized detail. It is an identifier, not a URL to dereference.

max length 2048
titlestringrequired

A localized, human-readable summary of the error category. Stable for a given status code and resolved language — clients must not use it as a machine-readable discriminator.

max length 40
statusintegerrequired

The HTTP status code, repeated from the response itself.

detailstring

A localized, human-readable explanation specific to this occurrence. Clients must not parse it for machine-readable information.

max length 500
instancestring<uri-reference>

An identifier for this specific occurrence, so it can be correlated with server-side logs if you need to report it.

max length 100
Request
curl -X GET "https://api.underdogexchange.com/markets/UDX-EXAMPLE-MARKET/orderbook" \
  -H "UDX-Access-Key: API_KEY_ID" \
  -H "UDX-Access-Timestamp: UNIX_MILLISECONDS" \
  -H "UDX-Access-Signature: BASE64_SIGNATURE"
Response
{
  "orderbook": {
    "ticker": "UDX-EXAMPLE-MARKET",
    "bids": [
      [
        "0.54",
        "120"
      ],
      [
        "0.53",
        "300"
      ]
    ],
    "asks": [
      [
        "0.56",
        "80"
      ],
      [
        "0.57",
        "250"
      ]
    ]
  }
}