MMTMMT Docs

Get orderbook snapshot

Returns a real-time orderbook snapshot for a single exchange and symbol. Does not support aggregated exchanges. Returns bid and ask levels as `[price, size]` pairs.

GET
/api/v1/orderbook

Returns a real-time orderbook snapshot for a single exchange and symbol. Does not support aggregated exchanges. Returns bid and ask levels as [price, size] pairs.

Authorization

ApiKeyAuth
X-API-Key<token>

API key for authentication. Obtain from the MMT dashboard. Keep secret and use only from your backend; never expose in browser/mobile clients.

In: header

Query Parameters

exchange*string

Single exchange identifier. Aggregated exchanges are not supported.

symbol*string

Trading pair in base/quote format.

levels?string

Number of price levels to return per side. Defaults to 100.

Default"100"
Value in"100" | "1000" | "5000" | "full"
format?string

Response format. Defaults to json. Set to cbor for binary CBOR encoding.

Value in"json" | "cbor"

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://eu-central-1.mmt.gg/api/v1/orderbook?exchange=binancef&symbol=btc%2Fusd"
{
  "t": 0,
  "exchange": "string",
  "symbol": "string",
  "a": [
    [
      0,
      0
    ]
  ],
  "b": [
    [
      0,
      0
    ]
  ],
  "lp": 0,
  "snapshot": true,
  "seq": 0,
  "levels": 0
}
{
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Invalid request parameters",
    "details": {}
  }
}
{
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Invalid request parameters",
    "details": {}
  }
}
{
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Invalid request parameters",
    "details": {}
  }
}
{
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Invalid request parameters",
    "details": {}
  }
}