Fetch multiple markets by id, one provider at a time
Fetches metadata for one provider and up to 200 market ids in a single call. Rate-limit bucket: LIGHT, flat cost of 1 unit regardless of batch size (unlike /v1/market-identifiers/resolve, this endpoint does NOT charge per-item). Not cached (Cache-Control: no-store) — every call returns live data.
Request body is capped at 1 MiB, and market_ids is capped at 200 entries per request (market_ids exceeds maximum 200).
Ids that cannot be found are omitted from markets and listed in misses.
curl --request POST \
--url https://md.kairos.trade/v1/markets/batch \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>' \
--data '
{
"provider": "polymarket",
"market_ids": [
"1897040",
"1897041",
"does-not-exist"
]
}
'import requests
url = "https://md.kairos.trade/v1/markets/batch"
payload = {
"provider": "polymarket",
"market_ids": ["1897040", "1897041", "does-not-exist"]
}
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({provider: 'polymarket', market_ids: ['1897040', '1897041', 'does-not-exist']})
};
fetch('https://md.kairos.trade/v1/markets/batch', 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://md.kairos.trade/v1/markets/batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'provider' => 'polymarket',
'market_ids' => [
'1897040',
'1897041',
'does-not-exist'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://md.kairos.trade/v1/markets/batch"
payload := strings.NewReader("{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://md.kairos.trade/v1/markets/batch")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://md.kairos.trade/v1/markets/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"exchange_id": "polymarket",
"markets": {
"1897040": {
"exchange_id": "polymarket",
"market_id": "1897040",
"condition_id": "0xabc123...",
"event_id": "evt-4521",
"title": "Will BTC close above $120k on July 31?",
"neg_risk": false,
"tick_size": 0.01,
"outcomes": [
{
"outcome": "Yes",
"normalized_outcome": "yes",
"token_id": "18812649149814341758733697580460697418474693998558159483117"
}
],
"raw": {}
}
},
"misses": [
"does-not-exist"
]
}Authorizations
Credential client id (kairos_ck_...). Must be sent together with X-Api-Key and X-Api-Secret.
64-char hex API key. Must be sent together with X-Client-Id and X-Api-Secret.
64-char hex API secret. Must be sent together with X-Client-Id and X-Api-Key.
Body
Response
Batch lookup result, keyed by market_id.
Was this page helpful?
curl --request POST \
--url https://md.kairos.trade/v1/markets/batch \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>' \
--data '
{
"provider": "polymarket",
"market_ids": [
"1897040",
"1897041",
"does-not-exist"
]
}
'import requests
url = "https://md.kairos.trade/v1/markets/batch"
payload = {
"provider": "polymarket",
"market_ids": ["1897040", "1897041", "does-not-exist"]
}
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({provider: 'polymarket', market_ids: ['1897040', '1897041', 'does-not-exist']})
};
fetch('https://md.kairos.trade/v1/markets/batch', 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://md.kairos.trade/v1/markets/batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'provider' => 'polymarket',
'market_ids' => [
'1897040',
'1897041',
'does-not-exist'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://md.kairos.trade/v1/markets/batch"
payload := strings.NewReader("{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://md.kairos.trade/v1/markets/batch")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://md.kairos.trade/v1/markets/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider\": \"polymarket\",\n \"market_ids\": [\n \"1897040\",\n \"1897041\",\n \"does-not-exist\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"exchange_id": "polymarket",
"markets": {
"1897040": {
"exchange_id": "polymarket",
"market_id": "1897040",
"condition_id": "0xabc123...",
"event_id": "evt-4521",
"title": "Will BTC close above $120k on July 31?",
"neg_risk": false,
"tick_size": 0.01,
"outcomes": [
{
"outcome": "Yes",
"normalized_outcome": "yes",
"token_id": "18812649149814341758733697580460697418474693998558159483117"
}
],
"raw": {}
}
},
"misses": [
"does-not-exist"
]
}
