API Reference
The Kwery REST API is versioned at /v1. All endpoints require an X-API-Key header. The authoritative spec is the OpenAPI 3.1 document — this reference tracks that spec.
Base URL: https://kwery-api.com
Endpoint Groups
Discovery
| Endpoint | Description |
|---|---|
| GET /v1/sources | List all available data sources |
| GET /v1/symbols | List all available symbols per source |
| GET /v1/limits | Inspect your plan limits and current usage |
Markets
| Endpoint | Description |
|---|---|
| GET /v1/markets | Search and filter prediction markets across Polymarket and Kalshi |
| Platform routes | Source-scoped shortcuts (/v1/polymarket/*, /v1/kalshi/*, etc.) |
OHLCV & Prices
| Endpoint | Description |
|---|---|
| GET /v1/candles | OHLCV candles — Binance, Hyperliquid, Chainlink, Polymarket, Kalshi |
| GET /v1/ticker | 1-second ticker snapshots (Pro+) |
| GET /v1/candles?source=chainlink | Chainlink oracle OHLCV |
| GET /v1/derived | Derived metrics (basis, spread, ratios) |
Microstructure
| Endpoint | Description |
|---|---|
| GET /v1/snapshots | Order book snapshots across sources |
| GET /v1/orderbook | Historical order book depth |
| GET /v1/trades | Individual trade executions |
| GET /v1/flow | Directional buy/sell flow — Binance spot |
Derivatives
| Endpoint | Description |
|---|---|
| GET /v1/funding | Funding rates — Binance Futures and Hyperliquid |
| GET /v1/open-interest | Open interest history |
| GET /v1/liquidations | Liquidation events |
Account & Operations
| Endpoint | Description |
|---|---|
| GET /v1/status | API and ingestion pipeline status |
| GET /v1/health | Health check — uptime monitoring |
Authentication
Pass your API key as a request header:
curl https://kwery-api.com/v1/candles \
-H "X-API-Key: your_api_key_here" \
-G -d "symbol=BTC&interval=1h&source=binance"
You can also pass ?api-key=your_api_key_here as a query parameter, but the header is recommended. Get a key at kwery.xyz/dashboard.
Response Envelope
Every endpoint returns the same envelope:
{
"data": [...],
"meta": {
"total": 500,
"next_cursor": "abc123"
}
}
Paginate with ?after=<next_cursor>. See Pagination for details.
Error Codes
| Status | Meaning |
|---|---|
401 | Missing or invalid API key |
403 | Plan limit exceeded — upgrade at kwery.xyz/pricing |
422 | Invalid parameters — check the field errors in the response body |
429 | Rate limited — back off and retry |
Full error reference: Error Codes.