Skip to main content

API Documentation

This document provides a comprehensive guide to integrating with our API to access real-time for a wide range of assets.

Authentication

All API requests must be authenticated using an API key.

  • Header: X-API-Key

To authenticate your request, include your API key in the X-API-KEY header. Requests without a valid API key will be rejected with a 401 Unauthorized error.

Important

To access the API service, the IP address used must be whitelisted by our team.

API Endpoints

Get Available Pairs

Retrieves a paginated list of all supported asset pairs.

GET /v1/pairs

Query Parameters

ParameterTypeRequiredDescription
codeStringNoSearch for pairs by a specific code (e.g., BTC).
typeStringNoFilter pairs by asset type (e.g., Crypto).
pageIntNoThe page number for pagination. Defaults to 1.
per_pageIntNoThe number of items per page. Defaults to 10.

Example Request

curl --location --request GET 'https://{host}/v1/pairs?type=Crypto&page=1&per_page=2' \
--header 'X-API-KEY: YOUR_API_KEY'

Example Response

200 OK
{
"status_number": "200",
"ts": 1752728575811,
"data": [
{
"code": "Crypto:ALL:BTC/USDT",
"name": "BITCOIN",
"base": "BTC",
"quote": "USDT"
},
{
"code": "Crypto:ALL:AAVE/USDT",
"name": "AAVE",
"base": "AAVE",
"quote": "USDT"
}
]
}

Get Price

Retrieves the latest price for a specific asset pair.

GET /v1/price

Query Parameters

ParameterTypeRequiredDescription
codeStringYesThe pair code to retrieve the price for (e.g., Equity:US:NVDA/USD).
poolStringNoOptional: The pool address for specific crypto assets.

Example Request

curl --location --request GET 'https://{host}/v1/price?code=Equity:US:NVDA/USD' \
--header 'X-API-Key: YOUR_API_KEY'

Asset-Specific Responses

Crypto Assets

Crypto markets are open 24/7 and are considered to be in a continuous regular session.

200 OK
{
"status_number": "200",
"ts": 1756714674097,
"data": {
"code": "Crypto:ALL:BTC/USDT",
"ask": "109622.78961091458",
"bid": "109403.76305824542",
"price": "109513.27633458",
"market": {
"open": true,
"reason": "continuous",
"session": "REG"
}
}
}

Equity (Stock), Forex, Commodity, Metal, etc

Equity (Stock), Forex, Commodity, Metal, etc markets are open during regular market hours.

200 OK - Market Open
{
"status_number": "200",
"ts": 1672531200,
"data": {
"code": "Forex:ALL:USD/JPY",
"ask": "150.25",
"bid": "150.2",
"price": "150.225",
"market": {
"open": true,
"reason": "regular_session",
"session": "REG",
"timezone": "America/New_York"
}
}
}

200 OK - Market Closed
{
"status_number": "200",
"ts": 1672531200,
"data": {
"code": "Forex:ALL:USD/JPY",
"ask": "150.25",
"bid": "150.2",
"price": "150.225",
"market": {
"open": true,
"reason": "market_closed",
"session": "CLOSED",
"timezone": "America/New_York"
}
}
}

US Equity with Extended Hours Trading

US Equity markets that support extended hours trading have three sessions: Pre-Market (PRE), Regular Market (REG), and Post-Market (POST).

200 OK - Pre-Market Session (PRE)
{
"status_number": "200",
"ts": 1756714719483,
"data": {
"code": "Equity:US:NVDA/USD",
"ask": "174.3",
"bid": "174.09",
"price": "174.195",
"market": {
"open": true,
"reason": "pre_session",
"session": "PRE",
"timezone": "America/New_York"
}
}
}
200 OK - Regular-Market Session (REG)
{
"status_number": "200",
"ts": 1756714719483,
"data": {
"code": "Equity:US:NVDA/USD",
"ask": "174.3",
"bid": "174.09",
"price": "174.195",
"market": {
"open": true,
"reason": "regular_session",
"session": "REG",
"timezone": "America/New_York"
}
}
}
200 OK - Post-Market Session (POST)
{
"status_number": "200",
"ts": 1756714719483,
"data": {
"code": "Equity:US:NVDA/USD",
"ask": "174.3",
"bid": "174.09",
"price": "174.195",
"market": {
"open": true,
"reason": "post_session",
"session": "POST",
"timezone": "America/New_York"
}
}
}
200 OK - Market Closed (CLOSED)
{
"status_number": "200",
"ts": 1756714719483,
"data": {
"code": "Equity:US:NVDA/USD",
"ask": "174.3",
"bid": "174.09",
"price": "174.195",
"market": {
"open": true,
"reason": "market_closed",
"session": "CLOSED",
"timezone": "America/New_York"
}
}
}

Price for Illiquid or Prices are not updated in real-time.

200 OK
{
"status_number": "50102",
"message": "The provided price may not reflect real-time market conditions.",
"ts": 1672531200,
"data": {
"code": "Equity:US:AAPL/USD",
"ask": "150.25",
"bid": "150.2",
"price": "150.225",
"market": {
"open": true,
"reason": "no_price",
"session": "REG",
"timezone": "America/New_York"
}
}
}
Important

Important: A 200 OK status indicates a successful request, but a status_number other than 200 signifies that the returned data may be stale or delayed due to low liquidity or price not updated in real-time.

Error Response - Pair Not Found

404 Not Found
{
"status_number": "50104",
"data": null,
"message": "Pair not found.",
"ts": 1751298466020
}
500 Internal Server Error
{
"status_number": "50000",
"data": null,
"message": "Sorry, this is not working properly. We know about this mistake and are working to fix it.",
"ts": 1751298466020
}

Status Code

status_number field in the response indicates the result of the API call. The HTTP status code will typically be 200 OK for successful requests or a standard error code (4xx, 5xx) for failures.

Status NumberMeaningDescription
200SuccessThe request was successful.
50000Internal Server ErrorAn unexpected error occurred on our end.
50001API MaintenanceThe API is temporarily down for maintenance.
50002Websocket MaintenanceThe websocket service is temporarily down for maintenance.
50003gRPC MaintenanceThe gRPC service is temporarily down for maintenance.
50004Invalid RequestThe request was malformed or contained invalid parameters.
50005UnauthorizedThe API key is missing, invalid, or expired.
50006Too Many RequestsThe request was throttled due to rate limiting.
50007SuspendedThe API key has been suspended.
50008Resource Not FoundThe requested endpoint or resource does not exist.
50009Connection Limit ExceededThe connection limit has been exceeded.
50010Access DeniedThe API key does not have permission to access this resource.
50100Restricted UserThe user account is restricted.
50101Price Not FoundNo price could be found for the requested pair.
50102Price UnavailableThe price is temporarily unavailable (e.g., market closed, low liquidity).
50103Price Pool UnavailableThe price pool is temporarily unavailable.
50104Pair Not FoundThe requested pair does not exist.
50105Pair UnavailableThe requested pair is temporarily unavailable.
50106Pair In MaintenanceThe requested pair is currently in maintenance.
50107No Pairs AllowedNo pairs are allowed for this request.
50108Pool Not FoundThe requested pool does not exist.
50109No Access to Asset TypeThe API key is not permitted to access this asset type.