Skip to content

Market data

Public JSON-RPC methods for markets, assets, order books, tickers, trades, candles, platform totals, interest rates and funding, mark and index price history, plus the TradingView UDF feed.

On this page

Market data is public. Call these methods over HTTP at POST /market/rpc. The /market/ws WebSocket carries streams only: subscribe there for live updates instead of polling.

HTTP
WebSocket
Auth
Params
Market selector
Unknown market
Charting
MethodUse it forLive equivalent
atlas.getSymbolsMarket list and static trading parametersnone
atlas.getAssetsEvery asset id, symbol, decimals and withdrawal limitsnone
atlas.getOrderBookBook snapshotstream.order_book
atlas.getBBOTop of book with sizesstream.bbo
atlas.getTickerQuote, 24h stats, mark, funding and open interest for one marketstream.ticker
atlas.getTickersThe same for several markets, or all of them, in one callstream.ticker
atlas.getTradesPublic trades, newest first, pagedstream.trades
atlas.getCandlesOHLCV historystream.candles
atlas.getPlatformStatsVenue-wide volume, trade count, open interest and active tradersnone
atlas.getInterestRatesEach asset's current interest ratenone
atlas.getInterestRateHistoryOne asset's interest rates over timenone
atlas.getFundingRateHistoryA perp's final funding rate for each completed sessionnone
atlas.getMarkPriceHistoryMark prices the venue appliedstream.mark_price
atlas.getIndexPriceHistoryIndex prices the venue applied, per assetstream.mark_price
atlas.getTimeServer clock, Unix msnone

Market ids

Every read and subscription names a market by its numeric marketId, from atlas.getSymbols. A symbol is a display label that more than one market can share, so don't key anything on it. Signed commands name the market in a tagged form instead; see MarketId. Refresh your ids from atlas.getSymbols rather than hard-coding them.

Markets

atlas.getSymbols

atlas.getSymbolsHTTP/market/rpc

Returns the catalog of markets and their static parameters: the marketId every other read takes, decimals, tick and lot sizes, order limits, collars, margin config, status and mode. With no params you get every market open to new orders, sorted by symbol. This is static data. For prices, use atlas.getTicker or atlas.getTickers.

Fees depend on your wallet's fee tier, not the market: see Trading fees. For the funding schedule, see Funding.

Try itatlas.getSymbolsHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getSymbols","params":{"kind":"perp"}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.

Values in the example are illustrative. Read live values, and the marketId to sign with, from this method before you sign an order. For the markets listed, see Perpetual markets and Spot markets.

kindenum
sortByenum
sortDirenum
querystring
statusenum
modeenum
quoteAssetstring
limitinteger
offsetinteger

Result: SymbolInfo[]

SymbolInfo

symbolstringrequired
marketIdinteger
baseAssetstringrequired
quoteAssetstringrequired
baseAssetIdinteger
quoteAssetIdinteger
kindperp or spot
tickSizePricerequired
lotSizeSizerequired
minOrderSizeSizerequired
maxOrderSizeSizerequired
minOrderNotionalPositiveDecimalStringrequired
maxOrderNotionalPositiveDecimalStringrequired
passiveCollarBpsintegerrequired
aggressiveCollarBpsintegerrequired
baseDecimalsintegerrequired
quoteDecimalsintegerrequired
priceScaleintegerrequired
qtyScaleintegerrequired
multiplierPositiveDecimalStringrequired
statusACTIVE or INACTIVErequired
modeNORMAL or REDUCE_ONLY or CLOSE_ONLYrequired
marginModePolicyenum
imrBpsinteger
mmrBpsinteger
liquidationPenaltyBpsinteger
maxPositionNotionalUsdPositiveDecimalString
marginTiersMarginTier[]
›Show 3 child fields
notional_cap_usdintegerrequired
imr_bpsintegerrequired
mmr_bpsintegerrequired
ExampleReading leverage from imrBps
  • Say imrBps is 250. Max leverage is 10000 / 250 = 40x.
  • With the tiers in the example response, notional up to 5,000,000 USD uses 250 bps (40x). Above that, up to 25,000,000 USD, it uses 500 bps (20x).
ErrorWhen
-32602Unknown sortBy, sortDir, status or mode, or limit < 1, or offset < 0

A market closed to new orders refuses new orders and replaces with -10022. It drops out of atlas.getSymbols, the default atlas.getTickers list and UDF search, but stays readable by its marketId.

Assets

atlas.getAssets

atlas.getAssetsHTTP/market/rpc

Every asset the venue has created, sorted by assetId, with its scale and withdrawal limits. That includes assets no market references. Use it to turn the numeric assetId in deposits, transfers and balances into a symbol and a scale, and to check a withdrawal before you sign it. Takes no params. atlas.getSymbols only names the assets its markets reference.

Try itatlas.getAssetsHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getAssets","params":{}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.

Values in the example are illustrative. A real response also lists the assets that only price a perp.

Result: AssetInfo[]

AssetInfo

assetIdintegerrequired
symbolstringrequired
decimalsintegerrequired
withdrawalMinimumPositiveDecimalStringrequired
withdrawalZonesinteger[]required

For the other withdrawal rules, see Withdrawals and transfers. Raw amounts use the asset's decimals, but prices and sizes don't: use each market's tickSize and lotSize for those.

Order book

atlas.getOrderBook

atlas.getOrderBookHTTP/market/rpc

A point-in-time snapshot of the book. Pass depth to cap the levels per side. Live books come from stream.order_book, which sends levels as [price, size] pairs rather than objects.

Try itatlas.getOrderBookHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getOrderBook","params":{"marketId":4294967297,"depth":3}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired
depthinteger

Result: OrderBookSnapshot

OrderBookSnapshot

marketIdintegerrequired
symbolSymbolrequired
bidsOrderBookLevel[]required
›Show 2 child fields
priceDecimalStringrequired
sizeDecimalStringrequired
asksOrderBookLevel[]required
›Show 2 child fields
priceDecimalStringrequired
sizeDecimalStringrequired
timestampTimestampMsrequired

A known market with no book yet returns empty bids and asks with timestamp 0. Sizes can carry trailing zeros ("0.080000"): compare them as decimals, not strings.

ErrorWhen
-32602Missing or malformed marketId, or depth below 1
-20008Unknown market id
-20003The book can't be read. Retry with backoff

atlas.getBBO

atlas.getBBOHTTP/market/rpc

Best bid and offer, with sizes. Field names are single letters.

Try itatlas.getBBOHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getBBO","params":{"marketId":4294967297}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired

Result: BBO

BBO

marketIdintegerrequired
sSymbolrequired
bDecimalStringrequired
BDecimalStringrequired
aDecimalStringrequired
ADecimalStringrequired
TTimestampMsrequired

A side with no resting orders is sent as price "0" and size "0". Read a zero price as "no orders on this side", never as a bid or ask at zero: no real price on ATLAS is zero or below.

Tickers

atlas.getTicker

atlas.getTickerHTTP/market/rpc

One market's live quote: best bid and ask, the last trade, the rolling 24-hour window and the trading mode, plus mark price, and for perps the index, funding, impact prices and open interest.

Try itatlas.getTickerHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getTicker","params":{"marketId":4294967297}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired

Result: Ticker

Ticker

marketIdintegerrequired
symbolstringrequired
bestBidDecimalStringrequired
bestAskDecimalStringrequired
lastPriceDecimalStringrequired
lastSizeDecimalStringrequired
open24hDecimalStringrequired
high24hDecimalStringrequired
low24hDecimalStringrequired
volume24hDecimalStringrequired
volumeQuote24hDecimalStringrequired
tradeCount24hUint64Numberrequired
priceChange24hDecimalStringrequired
priceChangePct24hDecimalStringrequired
modeenumrequired
timestampTimestampMsrequired
markPriceDecimalString
indexPriceDecimalString
fundingRateDecimalString
nextFundingTimeTimestampMs
impactBidDecimalString
impactAskDecimalString
openInterestDecimalString
openInterestValueDecimalString
ErrorWhen
-32602Missing or malformed marketId
-20008Unknown market id
-20003Market state can't be read. Retry with backoff

atlas.getTickers

atlas.getTickersHTTP/market/rpc

Several tickers in one call, each exactly as atlas.getTicker returns it. Pass no selector for every listed market. Use it for a watchlist or a markets table.

Try itatlas.getTickersHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getTickers","params":{"marketIds":[4294967297,1]}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.

The spot row has no perp fields.

marketIdsinteger[]
symbolsstring[]
symbolstring

Send at most one of marketIds, symbols and symbol; more than one is -32602. With none, you get every listed market.

Result: Ticker[], in the order you asked, then catalog order within a symbol. An unknown market id or symbol fails the whole call with -20008: there is no partial result.

Trades

atlas.getTrades

atlas.getTradesHTTP/market/rpc

Public trades for one market, newest first, one page at a time. Pass nextCursor back as cursor, with the same marketId, for the next page; null ends the traversal. Paging reaches back only as far as the trades the service retains for that market. For live trades, subscribe to stream.trades.

Try itatlas.getTradesHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getTrades","params":{"marketId":4294967297,"limit":2}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired
limitinteger
cursorstring

Result: TradeHistoryPage

TradeHistoryPage

rowsTrade[]required
nextCursorstring or nullrequired

Trade

marketIdintegerrequired
symbolSymbolrequired
pricePricerequired
sizeSizerequired
sidebuy or sellrequired
timestampTimestampMsrequired
tradeIdTradeIdrequired
liquidationboolean
ErrorWhen
-32602Missing or malformed marketId, limit outside 1 to 500, or a cursor that is malformed, expired (older than the retained trades) or was issued for another market
-20008Unknown market id
-20003Trade history can't be read. Retry with backoff

Candles

atlas.getCandles

atlas.getCandlesHTTP/market/rpc

OHLCV candles, oldest first, at most limit of them. Three ways to ask:

You passYou get
from and toThe latest limit candles in that range. Page back by setting to to the earliest t you got
to onlyThe latest limit candles before to. Use this to page backwards
NeitherThe most recent limit candles, the live one (x: false) included
Try itatlas.getCandlesHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getCandles","params":{"marketId":4294967297,"interval":"1h","to":1791210000000,"limit":2}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired
intervalIntervalrequired
fromTimestampMs
toTimestampMs
limitinteger

Result: Candle[]

Candle

marketIdintegerrequired
tTimestampMsrequired
TTimestampMsrequired
sSymbolrequired
iIntervalrequired
oDecimalStringrequired
hDecimalStringrequired
lDecimalStringrequired
cDecimalStringrequired
vDecimalStringrequired
nintegerrequired
xbooleanrequired

Candles are built from public trades. t is a multiple of the interval since the Unix epoch, UTC. x: true can arrive a moment after T, and a candle marked x: true can still be updated: upsert by t.

ErrorWhen
-32602Malformed params or wrong types, an unsupported interval, from later than to, or limit outside 1 to 1000
-20008Unknown market id
-20003Candle history can't be read. Retry with backoff

Platform totals

atlas.getPlatformStats

atlas.getPlatformStatsHTTP/market/rpc

Totals across every market for one trailing window, for a public dashboard: volume, trade count, open interest, trading wallets, active Builders and live markets. They are refreshed periodically; see asOf. Notional values are in the margin asset, USDT.

Try itatlas.getPlatformStatsHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getPlatformStats","params":{"window":"day"}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
windowenum

Result: PlatformStats

PlatformStats

windowenumrequired
volumeQuoteobjectrequired
›Show 3 child fields
perpsDecimalStringrequired
spotDecimalStringrequired
totalDecimalStringrequired
tradeCountobjectrequired
›Show 3 child fields
perpsUint64Numberrequired
spotUint64Numberrequired
totalUint64Numberrequired
openInterestValueDecimalStringrequired
tradersUint64Numberrequired
activeBuildersUint64Numberrequired
marketsUint64Numberrequired
asOfTimestampMsrequired
ErrorWhen
-32602Unknown window
-20003The totals for that window haven't been computed yet. Retry with backoff

Interest rates

atlas.getInterestRates

atlas.getInterestRatesHTTP/market/rpc

Each asset's current interest rate, in basis points per funding session, not an annualized rate. An asset without a rate is left out; a zero rate is listed as "0". No params.

Try itatlas.getInterestRatesHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getInterestRates","params":{}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.

Result: InterestRate[], each { assetId, rateBps }. assetId is a decimal string here.

atlas.getInterestRateHistory

atlas.getInterestRateHistoryHTTP/market/rpc

One asset's interest rates over time, newest first: each rate as it was set, and the rate each closed session charged. Paged like the price and funding histories below.

Try itatlas.getInterestRateHistoryHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getInterestRateHistory","params":{"assetId":"0","limit":2}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
assetIdUint64Stringrequired
fromTimestampMs
toTimestampMs
limitinteger
cursorstring

Result: { rows: InterestRatePoint[], nextCursor, coveredThrough }

InterestRatePoint

assetIdUint64Stringrequired
rateBpsDecimalStringrequired
sessionIdUint64String | nullrequired
timestampTimestampMsrequired

An absent rate has no row; a zero rate does. coveredThrough is how far the history has been processed, as below. Interest settles with funding: see Funding.

Price and funding history

These reads return the history the venue actually applied, newest first, one page at a time: { rows, nextCursor, coveredThrough }. Pass nextCursor back unchanged as cursor, with the same filters; null ends the traversal. coveredThrough is how far the history has been processed, not the time of the last row, or null when unknown. A history that can't be read is -20003, never an empty page. For their weight, see Rate limits.

atlas.getFundingRateHistory

atlas.getFundingRateHistoryHTTP/market/rpc

A perp's final funding rate for each completed session, newest first. Predicted rates published during a session are not included. This is the market's rate. An account's payments are atlas.getFundingHistory.

Try itatlas.getFundingRateHistoryHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getFundingRateHistory","params":{"marketId":4294967297,"limit":2}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired
fromTimestampMs
toTimestampMs
limitinteger
cursorstring

Result: FundingRateHistoryPage

FundingRate

marketIdintegerrequired
symbolSymbolrequired
sessionIdUint64Stringrequired
rateBpsDecimalStringrequired
timestampTimestampMsrequired

History rates stay in basis points (rateBps), while the ticker and stream.mark_price give the current rate as a decimal fraction (fundingRate). "1" bp here is "0.0001" there.

Not every hour has a row; a zero rate does. See Funding.

-32602 also covers a from that isn't earlier than to, and a cursor that is malformed or was issued for other filters.

atlas.getMarkPriceHistory

atlas.getMarkPriceHistoryHTTP/market/rpc

The mark prices the venue applied to a market.

Try itatlas.getMarkPriceHistoryHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getMarkPriceHistory","params":{"marketId":4294967297,"limit":2}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
marketIdintegerrequired
limitinteger
cursorstring

Result: { rows: MarkPricePoint[], nextCursor, coveredThrough }. Each row has marketId, symbol, markPrice (DecimalString) and timestamp (when it was applied, Unix ms).

atlas.getIndexPriceHistory

atlas.getIndexPriceHistoryHTTP/market/rpc

The index prices the venue applied for one asset. Rejected inputs are not included.

Try itatlas.getIndexPriceHistoryHTTP POST
paramsedit me
curl -s https://<api-host>/market/rpc \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"atlas.getIndexPriceHistory","params":{"asset":"BTC","limit":1}}'
Sent to testnet by the docs server, which adds the API key
Response
Press Send to see the response.
assetstringrequired
limitinteger
cursorstring

Result: IndexPriceHistoryPage

IndexPricePoint

assetstringrequired
assetIdintegerrequired
indexPriceDecimalString or null
anchorDecimalString or null
freshSourcesinteger or null
regimeenum or null
qualityenumrequired
calcTimestampTimestampMs or null
timestampTimestampMsrequired

A row backed by a committed live mark carries only the price, its quality and the time: anchor, freshSources, regime and calcTimestamp are null on it. Treat each of those as optional.

TradingView UDF

A REST adapter for the TradingView charting library, mounted at /market/udf/*. It is a charting convenience, not the canonical API. It needs your X-Api-Key header, like the rest of the API. TradingView's stock UDF datafeed can't add a header, so serve UDF through your own backend, which adds the key, and point the charting library at that backend. Don't ship the key to the browser. All UDF times are Unix seconds. UDF names a market by its market id as a decimal string, such as "4294967297": that is the ticker TradingView passes back to /udf/history. The display symbol is only a label here.

EndpointQueryReturns
GET /udf/confignoneUdfConfig: supported_resolutions (for example ["1","5","15","60","240","1D"]), and booleans supports_search, supports_group_request, supports_marks, supports_timescale_marks, supports_time
GET /udf/timenonePlain text Unix seconds, for example 1791210612. Not JSON
GET /udf/symbolssymbol (required): the market id as a decimal string, for example 4294967297UdfSymbolInfo or { s: "error", errmsg }
GET /udf/searchquery (matched against display symbols; absent or empty returns every market), limit (1 to 50, default 10){ symbol, full_name, description, type, exchange }[]. symbol is the market id as a decimal string; full_name is Atlas: and the display symbol
GET /udf/historysymbol (the market id), resolution, from and to (all required), and optional countbackBars. See below

UdfSymbolInfo always has name (the display symbol), ticker (the market id as a decimal string), description, type, session, timezone, exchange, minmov, pricescale (price decimals are log10(pricescale)), has_intraday and supported_resolutions.

A missing required query parameter, or one that doesn't parse (such as a non-numeric from), gets HTTP 400 with a plain-text message, not a UDF object. Over the rate limit, every endpoint answers HTTP 429 with { "status": "err", "response": "[rate_limit_exceeded]", "limiter", "retryAfterMs" }: wait retryAfterMs milliseconds before retrying.

GET /udf/history

Returns the bars that open at or after from and before to (to is exclusive), with the live bar always appended. With countback, it returns the latest countback bars that open before to instead, the live bar included; from is still required but ignored, and a countback of 0 is refused. An unknown market id answers no_data.

ResolutionInterval
11m
55m
1515m
601h
2404h
1D1d
Request
curl -s -H 'X-Api-Key: <key>' 'https://<api-host>/market/udf/history?symbol=4294967297&resolution=60&from=1791202800&to=1791210000'

The response is tagged on s: ok with parallel arrays t (bar open times, Unix seconds) and o, h, l, c, v (decimal strings), where index i of each array is one bar; no_data when there are no bars; or error with an errmsg.

Response
{
  "s": "ok",
  "t": [1791202800, 1791206400],
  "o": ["70420", "70290"],
  "h": ["70610", "70350"],
  "l": ["70180", "69980"],
  "c": ["70290", "70105"],
  "v": ["84.315", "91.002"]
}

For the full contract, see the OpenAPI spec.