Market Data API
Hosted proxy for public crypto exchange and market-data endpoints — not a general-purpose web scraper. Authenticate with an API key, pass an allowlisted target URL, and receive the upstream response with rate-limit and cache headers.
Base URL: https://api.nexrade.com
For multi-exchange trading logic (orders, balances, aggregators), use the open-source nexrade library — it can route public market-data traffic through this API.
Authentication
All requests require an API key (created in the dashboard; starts with nxr_). Pass it either as:
- Header (preferred):
X-API-Key: nxr_… - Query string:
?api_key=nxr_…
If both are present, the query param wins. Prefer the header so the key does not end up in access logs or browser history.
# Preferred — header curl "https://api.nexrade.com/market-data" -H "X-API-Key: nxr_your_api_key" -G --data-urlencode "url=https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT" # Also supported — query string curl "https://api.nexrade.com/market-data?api_key=nxr_your_api_key&url=https%3A%2F%2Fapi.binance.com%2Fapi%2Fv3%2Fticker%2Fprice%3Fsymbol%3DBTCUSDT"
Missing key → 400. Invalid / disabled / expired key → 401 Unauthorized.
Allowed domains
Requests are restricted to crypto exchange APIs and market-data providers. Arbitrary websites, internal hosts, and non-allowlisted domains return 403. Only exact API hostnames are accepted — not marketing sites or arbitrary subdomains.
Live catalog from GET /market-data/allowed-domains.
https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDTLoading allowlist…
Endpoints
The market-data endpoint accepts a required url query parameter. The value must be a fully qualified HTTP(S) URL on an allowlisted exchange or data-provider host.
GET/market-data
Route the request through the proxy pool with IP rotation. Use this for production access to rate-limited or IP-sensitive exchange endpoints.
GET /market-data?url={TARGET_URL}
Header: X-API-Key: nxr_...
# or: GET /market-data?api_key=nxr_...&url={TARGET_URL}Response headers
| Header | Description |
|---|---|
| X-RateLimit-Limit | Max requests per window |
| X-RateLimit-Remaining | Requests left in the current window |
| X-RateLimit-Reset | Unix timestamp when the window resets |
| X-RateLimit-Scope | account, or ip when the free-plan IPv4 guard is tighter |
| X-Cache | HIT or MISS (when cached) |
Rate limits
Limits are applied per account and shared across all active API keys in a fixed one-minute window. Free traffic also has a client-IP guard. Exceeding the limit returns 429 Too Many Requests.
| Plan | Requests / min | API keys | Key expiry |
|---|---|---|---|
| Free | 90 | 1 | 30 days |
| Pro | 700 | 3 | Never |
| Enterprise | 3,500 | 10 | Never |
Per-user request fairness — to keep one account from monopolising the shared proxy pool, parallel requests on the same account are also subject to a short, plan-scaled concurrency guard. If you exceed it, the API returns 429 with a short retry hint in the body; no additional headers, no separate counter to track. Stay within the per-minute quota and you will not see this in practice.
Errors
Errors return JSON with a machine-readable error field and an optional message.
| Status | Meaning |
|---|---|
| 400 | Missing or invalid url |
| 401 | Missing or invalid API key |
| 403 | Target domain not allowlisted (exchanges / data providers only) |
| 429 | Rate limit exceeded |
| 502 | Upstream or proxy failure |
| 500 | Internal server error |
{
"error": "rate_limit_exceeded",
"message": "Account request quota exhausted"
}Python client
nexrade-reqnexrade-req is the official Python client for the Market Data API. It mirrors a familiar HTTP surface and, with an API key, routes traffic through the Nexrade proxy so each public request can use a fresh IP.
For multi-exchange trading (orders, balances, Spot/Futures aggregators), use nexrade instead — a separate trading library that can call this API for public market data.
Package: pypi.org/project/nexrade-req · Requires Python ≥ 3.9
Install
pip install nexrade-req
Direct request (no relay)
Without an API key, the client behaves like a normal fast HTTP client.
import nexrade_req as req
r = req.get(
"https://api.binance.com/api/v3/ticker/price",
params={"symbol": "BTCUSDT"},
)
print(r.status_code, r.json())With Nexrade relay
Pass your Nexrade API key (from the dashboard) to route through /market-data automatically.
from nexrade_req import Client
client = Client(api_key="nxr_your_api_key")
r = client.get(
"https://api.binance.com/api/v3/ticker/price",
params={"symbol": "ETHUSDT"},
)
print(r.json())Session reuse
from nexrade_req import Client
with Client(api_key="nxr_your_api_key") as c:
r1 = c.get("https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT")
r2 = c.get("https://api.binance.com/api/v3/ticker/price?symbol=ETHUSDT")
print(r1.json(), r2.json())Client options
| Parameter | Default | Description |
|---|---|---|
| api_key | None | Nexrade API key — enables relay routing |
| base_urls | Nexrade nodes | List of relay base URLs |
| timeout | 6 | Request timeout (seconds) |
| max_retries | 1 | Retry attempts on failure |
| is_random_base_url | True | Rotate relay nodes randomly |
Response helpers
Responses expose .status_code, .text, .content, .json(), .headers, .url, and .raise_for_status().
Errors
from nexrade_req import Client
from nexrade_req.exceptions import NexradeException
client = Client(api_key="nxr_your_api_key")
try:
r = client.get("https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT")
r.raise_for_status()
except NexradeException as e:
print("All relay attempts failed:", e)Client(api_key=…). Full package details: PyPI · nexrade-reqHTTP samples
Prefer the official Python client (nexrade-req) when possible. These examples call the REST API directly. Auth is shown via the X-API-Key header (preferred). Query api_key= is also accepted.
curl
curl "https://api.nexrade.com/market-data" \ -H "X-API-Key: nxr_your_api_key" \ -G --data-urlencode "url=https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT"
JavaScript
const endpoint = new URL("https://api.nexrade.com/market-data");
endpoint.searchParams.set(
"url",
"https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT"
);
const res = await fetch(endpoint, {
headers: { "X-API-Key": process.env.NEXRADE_API_KEY },
});
const data = await res.json();
console.log(data);Python (requests)
import os
import requests
r = requests.get(
"https://api.nexrade.com/market-data",
headers={"X-API-Key": os.environ["NEXRADE_API_KEY"]},
params={
"url": "https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT"
},
timeout=15,
)
r.raise_for_status()
print(r.json())