Kalshi city temperature index
POST /api/kalshi-weather-indexKalshi's own minute-resolution city temperature index (Fahrenheit), the series its hourly temperature markets settle on, computed from weighted member stations. Send POST /api/kalshi-weather-index with the required field city and pay $0.002 per call over x402 or MPP (there is no free tier). It returns a JSON object with city, units, configVersion, count, totalInWindow and 5 more.
Ask for a trailing window (lastSec, default one hour, max 7 days) or a from/to window; detailed adds every station's reading per minute; includeCalibrations adds the published station-weight and offset timeline. Cities: miami, dfw, houston, phl-delaware-valley, puget-sound, sf-bay, greater-boston, southeast-michigan, kansas-city, minneapolis-st-paul, nyc, chicago, la-coastal. Free keyless Kalshi live_data.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
city | string | yes | Kalshi index city id, e.g. miami, nyc, chicago, sf-bay. Also accepted as place, location. |
lastSec | number | no | Trailing window in seconds (default 3600, max 604800). Ignored when from/to are given. |
from | number | no | Window start, unix milliseconds (pair with to). |
to | number | no | Window end, unix milliseconds (pair with from). |
detailed | boolean | no | Include every member station's reading and QC code on each point. |
includeCalibrations | boolean | no | Also return the city's published calibration timeline (station weights and offsets). |
limit | number | no | Newest points to return (default 1440, max 10000). |
Example request
curl -i -X POST https://agent402.tools/api/kalshi-weather-index \
-H "Content-Type: application/json" \
-d '{"city":"miami","lastSec":3600,"limit":5}'
Without payment this returns HTTP 402 Payment Required with the exact price for kalshi-weather-index; any x402 v2 or MPP client pays it and retries.
Example response
{
"city": "miami",
"units": "fahrenheit",
"configVersion": "miami-temperature-v1.0-cal-20260914",
"count": 5,
"totalInWindow": 60,
"latest": {
"time": "2026-09-18T16:22:00.000Z",
"valueF": 84.2,
"contributors": 5,
"status": "normal"
},
"minF": 84.2,
"maxF": 85.28,
"points": [
{
"time": "2026-09-18T16:18:00.000Z",
"valueF": 85.28,
"contributors": 5,
"status": "normal"
}
],
"source": "kalshi"
}
| Field | Type | Always present | In the example |
|---|---|---|---|
city | string | yes | miami |
units | string | yes | fahrenheit |
configVersion | string | yes | miami-temperature-v1.0-cal-20260914 |
count | number | yes | 5 |
totalInWindow | number | yes | 60 |
latest | object | yes | 4 fields: time, valueF, contributors, status |
minF | number | yes | 84.2 |
maxF | number | yes | 85.28 |
points | array of objects | yes | 1 item in the example |
source | string | yes | kalshi |
From an MCP client
catalog.call {
"slug": "kalshi-weather-index",
"params": {
"city": "miami",
"lastSec": 3600,
"limit": 5
}
}
The hosted connector at https://agent402.tools/mcp needs a payment for kalshi-weather-index; the stdio package pays it from a wallet or from AGENT402_CREDITS_KEY. Local install: npx -y agent402-mcp.
Errors and behavior
cityis required. An input the tool rejects returns an HTTP 4xx whose body carrieserror,tool,expected,requiredandexample, so the caller can correct it.- A paid call that ends in any status of 400 or above is not charged over x402, MPP or a prepaid credits key: settlement is cancelled when the tool fails. The exception is a Tempo push credential, a transfer the buyer sent before the call: it settles before the tool runs, so if the tool then fails the payment is recorded as a refund owed to the paying wallet.
- Wallet-only: this tool reaches the network or stored state, so it has no proof-of-work tier. A prepaid card-credits key issued earlier (
Authorization: Bearer a402_...) also pays it. - A
GETorHEADto /api/kalshi-weather-index returns the same 402 quote, so the price can be read without a body. - An
Idempotency-Keyheader makes a retried paid call replay the first 200 instead of charging again (an answer larger than 1 MB is not replayed).
Paid call (JavaScript agent)
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client();
client.setSpendControls?.(false); // keep your own spending ceiling in code
registerExactEvmScheme(client, { signer: privateKeyToAccount(KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);
const res = await payFetch("https://agent402.tools/api/kalshi-weather-index", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"city": "miami",
"lastSec": 3600,
"limit": 5
}),
});
Related tools
Kalshi live data behind an event
POST /api/kalshi-live-dataThe live feed a Kalshi event settles on, from Kalshi's free live_data tier: a crypto event returns the CF Benchmarks pri…
Kalshi event detail
POST /api/kalshi-eventGet full detail for a single Kalshi event with all its nested markets. Mutually-exclusive flag tells you whether the mar…
Kalshi markets list
POST /api/kalshi-marketsList Kalshi markets (CFTC-regulated US event contracts). Filter by status (open/closed/settled/unopened) or by event tic…
Current weather (global)
GET /api/weather-currentCurrent weather conditions for any location on Earth: temperature, feels-like, humidity, wind speed/direction/gusts, pre…
Known-address label lookup
POST /api/address-labelLabel a known EVM address from a curated, committed dataset: major stablecoin + token contracts (the USDC and USDG contr…
Wallet token transfers (filtered)
POST /api/asset-transfersRecent token transfers for a wallet on Base, Ethereum and other EVM chains, newest first. Filtered transfer log for an E…