DEX and Pair OHLC
curl --request GET \
--url https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair} \
--header 'api-key: <api-key>'import requests
url = "https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}"
headers = {"api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'api-key': '<api-key>'}};
fetch('https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}', 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://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"api-key: <api-key>"
],
]);
$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://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"coin_a_change_pct": 123,
"coin_a_close": 123,
"coin_a_high": 123,
"coin_a_low": 123,
"coin_a_open": 123,
"coin_a_volume": 123,
"coin_b_change_pct": 123,
"coin_b_close": 123,
"coin_b_high": 123,
"coin_b_low": 123,
"coin_b_open": 123,
"coin_b_volume": 123,
"count": 123,
"timestamp": "<string>"
}
]{
"error": "Bad Request"
}{
"error": "Bad Request"
}DEX
DEX and Pair OHLC
Get OHLC (Open, High, Low, Close) price data for a trading pair on a Cardano DEX with historical candles.
GET
/
dexs
/
ohlc
/
{dex}
/
{pair}
DEX and Pair OHLC
curl --request GET \
--url https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair} \
--header 'api-key: <api-key>'import requests
url = "https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}"
headers = {"api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'api-key': '<api-key>'}};
fetch('https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}', 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://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"api-key: <api-key>"
],
]);
$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://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://mainnet.gomaestro-api.org/v1/markets/dexs/ohlc/{dex}/{pair}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"coin_a_change_pct": 123,
"coin_a_close": 123,
"coin_a_high": 123,
"coin_a_low": 123,
"coin_a_open": 123,
"coin_a_volume": 123,
"coin_b_change_pct": 123,
"coin_b_close": 123,
"coin_b_high": 123,
"coin_b_low": 123,
"coin_b_open": 123,
"coin_b_volume": 123,
"count": 123,
"timestamp": "<string>"
}
]{
"error": "Bad Request"
}{
"error": "Bad Request"
}Authorizations
Project API Key
Query Parameters
1h
Available options:
1m, 5m, 15m, 30m, 1h, 4h, 1d, 1w, 1mo 2023-04-01
2023-05-15
10000
Required range:
1 <= x <= 50000desc
Available options:
asc, desc false
Response
OK
Coin A change percentage
Coin A close
Coin B high
Coin A low
Coin A open
Coin A volume
Coin B change percentage
Coin B close
Coin A high
Coin B low
Coin B open
Coin B volume
Candlestick size
Candlestick timestamp
Was this page helpful?

