Get Prices
curl --request GET \
--url https://api.centosfi.com/v1/prices/{centos_id}import requests
url = "https://api.centosfi.com/v1/prices/{centos_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.centosfi.com/v1/prices/{centos_id}', 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://api.centosfi.com/v1/prices/{centos_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://api.centosfi.com/v1/prices/{centos_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.centosfi.com/v1/prices/{centos_id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.centosfi.com/v1/prices/{centos_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"centos_id": 123,
"exchange": "<string>",
"type": "candlesticks",
"candlesticks": [
{
"timestamp": 123,
"open": 123,
"high": 123,
"low": 123,
"close": 123,
"volume": 123
}
],
"history": [
{
"timestamp": 123,
"price": 123
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Market Data
Get Prices
Get price data for a market.
Returns either candlestick OHLC data or simple price history based on the type parameter.
The endpoint automatically determines the exchange and fetches data accordingly.
- Kalshi: Returns real OHLC candlestick data with volume
- Polymarket: Returns price history (candlesticks will have synthetic OHLC where all values equal the price)
All prices are normalized to 0-1 range.
GET
/
v1
/
prices
/
{centos_id}
Get Prices
curl --request GET \
--url https://api.centosfi.com/v1/prices/{centos_id}import requests
url = "https://api.centosfi.com/v1/prices/{centos_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.centosfi.com/v1/prices/{centos_id}', 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://api.centosfi.com/v1/prices/{centos_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://api.centosfi.com/v1/prices/{centos_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.centosfi.com/v1/prices/{centos_id}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.centosfi.com/v1/prices/{centos_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"centos_id": 123,
"exchange": "<string>",
"type": "candlesticks",
"candlesticks": [
{
"timestamp": 123,
"open": 123,
"high": 123,
"low": 123,
"close": 123,
"volume": 123
}
],
"history": [
{
"timestamp": 123,
"price": 123
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Path Parameters
Centos market ID
Query Parameters
Response type
Available options:
candlesticks, history Time range
Available options:
1d, 1w, 1m, max Minutes per data point (for Polymarket history)
Required range:
1 <= x <= 60
