Market Data API · v1

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.

bash
# 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.

Example allowlisted URL: https://api.binance.com/api/v3/ticker/price?symbol=BTCUSDT

Loading 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.

bash
GET /market-data?url={TARGET_URL}
Header: X-API-Key: nxr_...
# or: GET /market-data?api_key=nxr_...&url={TARGET_URL}

Response headers

HeaderDescription
X-RateLimit-LimitMax requests per window
X-RateLimit-RemainingRequests left in the current window
X-RateLimit-ResetUnix timestamp when the window resets
X-RateLimit-Scopeaccount, or ip when the free-plan IPv4 guard is tighter
X-CacheHIT 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.

PlanRequests / minAPI keysKey expiry
Free90130 days
Pro7003Never
Enterprise3,50010Never

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.

StatusMeaning
400Missing or invalid url
401Missing or invalid API key
403Target domain not allowlisted (exchanges / data providers only)
429Rate limit exceeded
502Upstream or proxy failure
500Internal server error
json
{
  "error": "rate_limit_exceeded",
  "message": "Account request quota exhausted"
}

Python client

nexrade-req

nexrade-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

bash
pip install nexrade-req

Direct request (no relay)

Without an API key, the client behaves like a normal fast HTTP client.

python
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.

python
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

python
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

ParameterDefaultDescription
api_keyNoneNexrade API key — enables relay routing
base_urlsNexrade nodesList of relay base URLs
timeout6Request timeout (seconds)
max_retries1Retry attempts on failure
is_random_base_urlTrueRotate relay nodes randomly

Response helpers

Responses expose .status_code, .text, .content, .json(), .headers, .url, and .raise_for_status().

Errors

python
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)
Get an API key in the dashboard, then pass it to Client(api_key=…). Full package details: PyPI · nexrade-req

HTTP 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

bash
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

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)

python
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())