Get historical prices

get/api/v1/marketdata/cryptocompare/historical/prices

Get a list of historical OHLCV (Open, High, Low, Close, Volume) prices for a currency pair within a specified time range. Using this endpoint requires an access token with the appropriate enterprise ID.

Query Parameters

  • basestringRequired
    The base currency symbol (the asset being priced). Must be a BitGo-supported instrument symbol (case-insensitive).
  • quotestringRequired
    The quote currency symbol (the currency in which the price is expressed). Must be a BitGo-supported instrument symbol (case-insensitive).
  • intervalstringRequired
    The time interval for each price data point.
    Enum: minute hour day
  • startstring<date-time>
    Start time for the pricing data range (RFC 3339 format). If not provided, defaults to 1 interval before the current time.
    Example: 2024-12-17T14:00:00.000Z
  • endstring<date-time>
    End time for the pricing data range (RFC 3339 format). If not provided, defaults to the current time.
    Example: 2024-12-17T16:00:00.000Z
  • nextBatchPrevIdstring
    Pagination cursor returned from a previous request. Use this to fetch the next batch of results when there are more than 1,000 data points.
    Example: 63ff9f4c0c01fcd7162c28fc901ad915

200 Response

data object required
prices dictionary<string, array> required
A map of currency pair to price data
Example: BTC-USD
nextBatchPrevId
string or null
Pagination cursor for fetching the next batch of results. Null if there are no more results.

400 Response

error string required
Detailed error message.
errorName string required
Error code identifier.