Skip to main content
POST
/
market-data
/
order-book
Get Order Book
curl --request POST \
  --url http://localhost:8000/market-data/order-book \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "connector_name": "<string>",
  "trading_pair": "<string>",
  "depth": 10
}
'
{
  "trading_pair": "<string>",
  "bids": [
    {
      "price": 123,
      "amount": 123
    }
  ],
  "asks": [
    {
      "price": 123,
      "amount": 123
    }
  ],
  "timestamp": 123
}

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Body

application/json

Request model for getting order book data

connector_name
string
required

Name of the connector

trading_pair
string
required

Trading pair

depth
integer
default:10

Number of price levels to return

Required range: 1 <= x <= 1000

Response

Successful Response

Response for order book data

trading_pair
string
required

Trading pair

bids
OrderBookLevel · object[]
required

Bid levels (highest to lowest)

asks
OrderBookLevel · object[]
required

Ask levels (lowest to highest)

timestamp
number
required

Snapshot timestamp