curl --request POST \
--url https://api.hotstuff.trade/info \
--header 'Content-Type: application/json' \
--data '{
"method": "ticker",
"params": {
"symbol": "all"
}
}'
import requests
url = "https://api.hotstuff.trade/info"
payload = {
"method": "ticker",
"params": {
"symbol": "all"
}
}
response = requests.post(url, json=payload)
print(response.json())
const url = "https://api.hotstuff.trade/info";
const payload = {
method: "ticker",
params: {
symbol: "all",
},
};
fetch(url, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(payload),
})
.then((response) => response.json())
.then((data) => console.log(data));
<?php
$url = "https://api.hotstuff.trade/info";
$payload = json_encode([
"method" => "ticker",
"params" => [
"symbol" => "all"
]
]);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
print_r(json_decode($response, true));
?>
package main
import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
)
func main() {
url := "https://api.hotstuff.trade/info"
payload := map[string]interface{}{
"method": "ticker",
"params": map[string]string{
"symbol": "all",
},
}
jsonData, _ := json.Marshal(payload)
resp, _ := http.Post(url, "application/json", bytes.NewBuffer(jsonData))
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.*;
URL url = new URL("https://api.hotstuff.trade/info");
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("POST");
conn.setRequestProperty("Content-Type", "application/json");
conn.setDoOutput(true);
String jsonPayload = "{\"method\":\"ticker\",\"params\":{\"symbol\":\"all\"}}";
OutputStream os = conn.getOutputStream();
os.write(jsonPayload.getBytes());
os.flush();
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String response = in.readLine();
System.out.println(response);
require 'net/http'
require 'json'
uri = URI('https://api.hotstuff.trade/info')
payload = {
method: "ticker",
params: {
symbol: "all"
}
}
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri.path, 'Content-Type' => 'application/json')
request.body = payload.to_json
response = http.request(request)
puts JSON.parse(response.body)
[
{
"type": "perp",
"symbol": "ETH-PERP",
"mark_price": "2265.6",
"mid_price": "2435.2",
"index_price": "2243.196046",
"best_bid_price": "2395.3",
"best_ask_price": "2475.2",
"best_bid_size": "291.6466",
"best_ask_size": "5.4876",
"funding_rate": "0.003421",
"open_interest": "23612.3172",
"volume_24h": "48081433.85016",
"change_24h": "-116.9",
"max_trading_price": "2333.599882",
"min_trading_price": "2197.662025",
"last_updated": 1770137768530,
"last_price": "2395.3"
}
]{
"error": "<error message>"
}Global
ticker
Send POST request to /info with method: “ticker”
POST
/
info
curl --request POST \
--url https://api.hotstuff.trade/info \
--header 'Content-Type: application/json' \
--data '{
"method": "ticker",
"params": {
"symbol": "all"
}
}'
import requests
url = "https://api.hotstuff.trade/info"
payload = {
"method": "ticker",
"params": {
"symbol": "all"
}
}
response = requests.post(url, json=payload)
print(response.json())
const url = "https://api.hotstuff.trade/info";
const payload = {
method: "ticker",
params: {
symbol: "all",
},
};
fetch(url, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(payload),
})
.then((response) => response.json())
.then((data) => console.log(data));
<?php
$url = "https://api.hotstuff.trade/info";
$payload = json_encode([
"method" => "ticker",
"params" => [
"symbol" => "all"
]
]);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
print_r(json_decode($response, true));
?>
package main
import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
)
func main() {
url := "https://api.hotstuff.trade/info"
payload := map[string]interface{}{
"method": "ticker",
"params": map[string]string{
"symbol": "all",
},
}
jsonData, _ := json.Marshal(payload)
resp, _ := http.Post(url, "application/json", bytes.NewBuffer(jsonData))
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.*;
URL url = new URL("https://api.hotstuff.trade/info");
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("POST");
conn.setRequestProperty("Content-Type", "application/json");
conn.setDoOutput(true);
String jsonPayload = "{\"method\":\"ticker\",\"params\":{\"symbol\":\"all\"}}";
OutputStream os = conn.getOutputStream();
os.write(jsonPayload.getBytes());
os.flush();
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String response = in.readLine();
System.out.println(response);
require 'net/http'
require 'json'
uri = URI('https://api.hotstuff.trade/info')
payload = {
method: "ticker",
params: {
symbol: "all"
}
}
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri.path, 'Content-Type' => 'application/json')
request.body = payload.to_json
response = http.request(request)
puts JSON.parse(response.body)
[
{
"type": "perp",
"symbol": "ETH-PERP",
"mark_price": "2265.6",
"mid_price": "2435.2",
"index_price": "2243.196046",
"best_bid_price": "2395.3",
"best_ask_price": "2475.2",
"best_bid_size": "291.6466",
"best_ask_size": "5.4876",
"funding_rate": "0.003421",
"open_interest": "23612.3172",
"volume_24h": "48081433.85016",
"change_24h": "-116.9",
"max_trading_price": "2333.599882",
"min_trading_price": "2197.662025",
"last_updated": 1770137768530,
"last_price": "2395.3"
}
]{
"error": "<error message>"
}Retrieve ticker information for trading instruments including current prices, volume, and market data.
curl --request POST \
--url https://api.hotstuff.trade/info \
--header 'Content-Type: application/json' \
--data '{
"method": "ticker",
"params": {
"symbol": "all"
}
}'
import requests
url = "https://api.hotstuff.trade/info"
payload = {
"method": "ticker",
"params": {
"symbol": "all"
}
}
response = requests.post(url, json=payload)
print(response.json())
const url = "https://api.hotstuff.trade/info";
const payload = {
method: "ticker",
params: {
symbol: "all",
},
};
fetch(url, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(payload),
})
.then((response) => response.json())
.then((data) => console.log(data));
<?php
$url = "https://api.hotstuff.trade/info";
$payload = json_encode([
"method" => "ticker",
"params" => [
"symbol" => "all"
]
]);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
print_r(json_decode($response, true));
?>
package main
import (
"bytes"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
)
func main() {
url := "https://api.hotstuff.trade/info"
payload := map[string]interface{}{
"method": "ticker",
"params": map[string]string{
"symbol": "all",
},
}
jsonData, _ := json.Marshal(payload)
resp, _ := http.Post(url, "application/json", bytes.NewBuffer(jsonData))
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.*;
URL url = new URL("https://api.hotstuff.trade/info");
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("POST");
conn.setRequestProperty("Content-Type", "application/json");
conn.setDoOutput(true);
String jsonPayload = "{\"method\":\"ticker\",\"params\":{\"symbol\":\"all\"}}";
OutputStream os = conn.getOutputStream();
os.write(jsonPayload.getBytes());
os.flush();
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String response = in.readLine();
System.out.println(response);
require 'net/http'
require 'json'
uri = URI('https://api.hotstuff.trade/info')
payload = {
method: "ticker",
params: {
symbol: "all"
}
}
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri.path, 'Content-Type' => 'application/json')
request.body = payload.to_json
response = http.request(request)
puts JSON.parse(response.body)
Body
application/json
Response
Successful response for BTC-PERP
type of instrument
instrument symbol