curl --request GET \
--url https://{host}/v1/tokens/{chain}/{address}/ohlcv \
--header 'Authorization: Bearer <token>'import requests
url = "https://{host}/v1/tokens/{chain}/{address}/ohlcv"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/v1/tokens/{chain}/{address}/ohlcv', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/v1/tokens/{chain}/{address}/ohlcv",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{host}/v1/tokens/{chain}/{address}/ohlcv"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/v1/tokens/{chain}/{address}/ohlcv")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/v1/tokens/{chain}/{address}/ohlcv")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"candles": [
{
"close": 0.7,
"high": 2,
"low": 0.5,
"open": 1,
"time": 123,
"volume": 1000
}
]
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}OHLCV candles at one timeframe, oldest first.
The series follows the TradingView contract: countBack asks for a bar
count and supersedes from; to and timeframe still bind. A window with
more candles than the cap keeps the newest. To read older candles, repeat
the request with to set to the earliest time received.
curl --request GET \
--url https://{host}/v1/tokens/{chain}/{address}/ohlcv \
--header 'Authorization: Bearer <token>'import requests
url = "https://{host}/v1/tokens/{chain}/{address}/ohlcv"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{host}/v1/tokens/{chain}/{address}/ohlcv', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/v1/tokens/{chain}/{address}/ohlcv",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{host}/v1/tokens/{chain}/{address}/ohlcv"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{host}/v1/tokens/{chain}/{address}/ohlcv")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/v1/tokens/{chain}/{address}/ohlcv")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"candles": [
{
"close": 0.7,
"high": 2,
"low": 0.5,
"open": 1,
"time": 123,
"volume": 1000
}
]
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>",
"details": "<unknown>"
}
}Authorizations
Send the API key as Authorization: Bearer <key>.
Path Parameters
Chain the resource lives on. Chain slug. One spelling per chain, in paths and bodies alike. Only a chain with spot data is published.
solana, base, bsc, robinhood, arc Token mint or contract address.
Query Parameters
Candle bucket size; defaults to 1m.
1s, 5s, 15s, 30s, 1m, 3m, 5m, 15m, 30m, 1h, 4h, 6h, 12h, 1d, 7d OHLC metric, price or marketCap; defaults to marketCap.
OHLC denomination; defaults to usd.
Window start, inclusive; ignored when countBack is set. A window holding
more candles than the cap keeps the newest.
An instant, as milliseconds since the Unix epoch.
Window end, exclusive. An instant, as milliseconds since the Unix epoch.
TradingView bar count: the most recent N buckets at or before to.
Takes priority over from.
1 <= x <= 5000Response
One candle per bucket that traded, oldest first. The most recent 500 buckets when the request names neither countBack nor from.
GET /v1/tokens/{chain}/{address}/ohlcv response.
Buckets, oldest first.
Show child attributes
Show child attributes