Live per-market PnL for a (wallet, market) pair
Live “hover” PnL for a single wallet on a single market, sourced from a fast real-time pipeline — quick regardless of how far back the wallet’s earliest trade goes. Returns one row per token held on the contract (e.g. YES + NO for a binary market) plus aggregate totals across those tokens. Only providers on this pipeline are supported: polymarket, opinion, predictfun; kalshi and hyperliquid are rejected with 400 and must use /pnl/{user_id}. When the underlying pipeline is disabled (e.g. while a backfill is ramping), the endpoint returns a well-formed zero/empty payload (tokens: [], all totals 0.0) instead of erroring, matching the “no data” state the frontend already renders gracefully. For API-key callers, the requested provider must additionally have its API access enabled.
curl --request GET \
--url https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id} \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>'import requests
url = "https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}"
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>'
}
};
fetch('https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <api-key>",
"X-Api-Secret: <api-key>",
"X-Client-Id: <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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"provider_id": "polymarket",
"wallet_address": "0x1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b",
"contract_id": "0xabc123condition",
"tokens": [
{
"token_id": "10723948572...4",
"outcome": "YES",
"balance": 150,
"avg_entry_price": 0.42,
"cost_basis_usd": 63,
"realized_pnl_usd": 0,
"mark_price": 0.55,
"position_value_usd": 82.5,
"unrealized_pnl_usd": 19.5
}
],
"total_unrealized_pnl_usd": 19.5,
"total_realized_pnl_usd": 0,
"total_position_value_usd": 82.5
}{
"detail": "Not authenticated"
}{
"detail": [
{}
]
}{
"error": "Rate limit exceeded: 100 per 1 minute"
}{
"detail": "Invalid provider"
}Authorizations
Credential client id (kairos_ck_...). Must be sent together with X-Api-Key and X-Api-Secret.
64-char hex API key.
64-char hex API secret.
Path Parameters
MV-pipeline provider id. kalshi, hyperliquid, and any other registered-but-non-MV provider are rejected with 400.
polymarket, opinion, predictfun 32Wallet address (opaque string; trimmed, length-checked — not format-validated at this layer).
128Market/condition (contract) id.
128Response
Per-token PnL rows and aggregate totals for the wallet on this market. Returns an empty/zeroed payload (not a 404) when the underlying PnL pipeline is disabled.
Live hover-on-wallet PnL for a single (wallet, market) pair. Returns a zeroed/empty payload (tokens: []) instead of erroring when the underlying PnL pipeline is disabled.
polymarket, opinion, predictfun "polymarket"
"0x1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b"
"0xabc123condition"
Show child attributes
Show child attributes
19.5
0
82.5
Was this page helpful?
curl --request GET \
--url https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id} \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>'import requests
url = "https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}"
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>'
}
};
fetch('https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Api-Key: <api-key>",
"X-Api-Secret: <api-key>",
"X-Client-Id: <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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<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://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://data.kairos.trade/pnl/hover/{provider_id}/{wallet}/{contract_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"provider_id": "polymarket",
"wallet_address": "0x1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b",
"contract_id": "0xabc123condition",
"tokens": [
{
"token_id": "10723948572...4",
"outcome": "YES",
"balance": 150,
"avg_entry_price": 0.42,
"cost_basis_usd": 63,
"realized_pnl_usd": 0,
"mark_price": 0.55,
"position_value_usd": 82.5,
"unrealized_pnl_usd": 19.5
}
],
"total_unrealized_pnl_usd": 19.5,
"total_realized_pnl_usd": 0,
"total_position_value_usd": 82.5
}{
"detail": "Not authenticated"
}{
"detail": [
{}
]
}{
"error": "Rate limit exceeded: 100 per 1 minute"
}{
"detail": "Invalid provider"
}
