Orderbook Snapshot
curl --request GET \
--url https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}import requests
url = "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"baseDecimals": 8,
"baseToken": "BTC",
"data": {
"bids": [
{
"price": "35000.00",
"quantity": "1.5",
"orderCount": 3
}
],
"asks": [
{
"price": "35000.00",
"quantity": "1.5",
"orderCount": 3
}
],
"bestBid": "34900.00",
"bestAsk": "35100.00",
"bidVolume": "15.5",
"askVolume": "12.3",
"priceChange": {
"price24hAgo": "34500.00",
"priceChange24h": "500.00",
"priceChangePercent24h": "1.45"
}
},
"eventType": "orderbook_snapshot",
"symbol": "BTC/USDC",
"tradingPairId": "123e4567-e89b-12d3-a456-426614174000",
"quoteDecimals": 6,
"quoteToken": "USDC",
"sequenceNumber": 12345,
"timestamp": "2023-11-13T10:30:00Z",
"tradingMode": "Spot"
}Orderbook
Orderbook Snapshot
Orderbook Snapshot
Get the complete orderbook snapshot for a trading pair showing all bids and asks with their price levels. This is a public endpoint that does not require authentication.
GET
/
api
/
v1
/
orderbook
/
{tradingPairId}
Orderbook Snapshot
curl --request GET \
--url https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}import requests
url = "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.apimonaco.xyz/api/v1/orderbook/{tradingPairId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"baseDecimals": 8,
"baseToken": "BTC",
"data": {
"bids": [
{
"price": "35000.00",
"quantity": "1.5",
"orderCount": 3
}
],
"asks": [
{
"price": "35000.00",
"quantity": "1.5",
"orderCount": 3
}
],
"bestBid": "34900.00",
"bestAsk": "35100.00",
"bidVolume": "15.5",
"askVolume": "12.3",
"priceChange": {
"price24hAgo": "34500.00",
"priceChange24h": "500.00",
"priceChangePercent24h": "1.45"
}
},
"eventType": "orderbook_snapshot",
"symbol": "BTC/USDC",
"tradingPairId": "123e4567-e89b-12d3-a456-426614174000",
"quoteDecimals": 6,
"quoteToken": "USDC",
"sequenceNumber": 12345,
"timestamp": "2023-11-13T10:30:00Z",
"tradingMode": "Spot"
}Path Parameters
Query Parameters
Number of price levels (max 100)
Required range:
1 <= x <= 100Trading mode
Available options:
SPOT, MARGIN Minimum string length:
1Price grouping magnitude
Available options:
0.0001, 0.001, 0.01, 0.1, 1, 10, 100, 1000, 10000 Minimum string length:
1Price denomination
Available options:
base, quote Minimum string length:
1Response
OK
Orderbook snapshot with token metadata and sequence number.
Base token decimal places
Example:
8
Base token symbol
Example:
"BTC"
Show child attributes
Show child attributes
Event type identifier
Example:
"orderbook_snapshot"
Trading pair symbol
Example:
"BTC/USDC"
Trading pair UUID
Example:
"123e4567-e89b-12d3-a456-426614174000"
Quote token decimal places
Example:
6
Quote token symbol
Example:
"USDC"
Orderbook sequence number
Example:
12345
Snapshot timestamp
Example:
"2023-11-13T10:30:00Z"
Trading mode
Example:
"Spot"
Was this page helpful?

