GET
/
api
/
v1
/
instruments
/
{instrument}
/
candles
curl --request GET \
  --url https://api.international.coinbase.com/api/v1/instruments/{instrument}/candles
{
  "aggregations": [
    {
      "start": "2024-04-23T00:00:00Z",
      "open": "62884.4",
      "high": "64710.6",
      "low": "62884.4",
      "close": "63508.4",
      "volume": "3253.9983"
    }
  ]
}
InstrumentsService instrumentsService = IntxServiceFactory.createInstrumentsService(client);
GetAggregatedCandlesRequest request = new GetAggregatedCandlesRequest.Builder()
    .instrumentId("BTC-PERP")
    .granularity("ONE_DAY")
    .start("2024-01-01T00:00:00Z")
    .build();
GetAggregatedCandlesResponse response = instrumentsService.getAggregatedCandles(request);

For more information, please visit the INTX Java SDK.

Path Parameters

instrument
string
required

Identifies the instrument by name (e.g., BTC-PERP)

Query Parameters

granularity
enum<string>
required

The aggregation period of the candles data. End timestamp in ISO 8601 timestamp format (e.g. 2024-03-01T00:00:00Z).

Available options:
ONE_DAY,
SIX_HOUR,
TWO_HOUR,
ONE_HOUR,
THIRTY_MINUTE,
FIFTEEN_MINUTE,
FIVE_MINUTE,
ONE_MINUTE
start
string
required

Start timestamp in ISO 8601 timestamp format (e.g. 2024-03-01T00:00:00Z)

end
string

End timestamp in ISO 8601 timestamp format (e.g. 2024-03-01T00:00:00Z)

Response

200
application/json

Instrument list

The response is of type object.