v1

latestOpenAPI 3.0.32026-07-267278168.1 KB
Market Data

Get Candles

Returns OHLCV candlestick data for a perpetual futures market as an array of objects, each with the full field names startTime, open, high, low, close, and volume (values are strings). If you need the TradingView UDF format instead (parallel o/h/l/c/v arrays of numbers), use GET /v1/perps/history (Get Price History).

get/v1/perps/candles

Query parameters

marketstring required
Example:AAPL-USD.P

Perps trading market

resolutionstring required
Example:1

Bar resolution. If the string has no "D", "W", or "M" suffix it is interpreted as minutes (e.g. 1, 5, 15, 30, 60, 240). Use suffixes for daily (e.g. 1D), weekly (1W), or monthly (1M).

frominteger required
Example:1684814400

Start of the requested time range (Unix timestamp in seconds)

tointeger required
Example:1684900800

End of the requested time range (Unix timestamp in seconds)

Response

Array of OHLCV candles

successboolean required

Whether the request was successful

errorstring

Error message, present only on failure

error_codestring

Semantic error code. See each endpoint's error responses for the specific codes it can return.

deprecatedstring

Deprecation notice, if applicable

Example response

{
  "success": true,
  "result": [
    {
      "startTime": "2024-01-04T16:00:00Z",
      "open": "150.25",
      "high": "152.10",
      "low": "149.80",
      "close": "151.45",
      "volume": "1234.56"
    }
  ]
}