Authentication
API Authentication
All API requests require an API key. The key determines your access tier and rate limits.
Get Your API Key
- 1.Create an account at nexusglass.live/auth/register
- 2.Navigate to the Developer Portal and generate an API key.
- 3.Your key starts with
nxg_. Store it securely. It will not be shown again.
Request Header
Include your API key in every request using the X-API-Key header.
X-API-Key: nxg_your_api_key_here
Code Examples
cURL
curl -s "https://nexusglass.live/api/v1/oi/BTCUSDT" \ -H "X-API-Key: nxg_your_api_key"
Python
import requests
resp = requests.get(
"https://nexusglass.live/api/v1/oi/BTCUSDT",
headers={"X-API-Key": "nxg_your_api_key"}
)
print(resp.json())Node.js
const resp = await fetch("https://nexusglass.live/api/v1/oi/BTCUSDT", {
headers: { "X-API-Key": "nxg_your_api_key" }
});
const data = await resp.json();Go
req, _ := http.NewRequest("GET",
"https://nexusglass.live/api/v1/oi/BTCUSDT", nil)
req.Header.Set("X-API-Key", "nxg_your_api_key")
resp, _ := http.DefaultClient.Do(req)WebSocket Authentication
WebSocket connections authenticate via the token query parameter.
wss://nexusglass.live/ws/fastfeed?token=nxg_your_api_key
The server sends a HANDSHAKE message confirming your tier and available event priorities.
Access Tiers
Each tier includes all endpoints from lower tiers.
| Tier | Level | Rate Limit |
|---|---|---|
| STREAM | L1 | 120 req/min |
| QUANT | L2 | 3,000 req/min |
| PULSE | L3 | 600K req/min |
| ORACLE | L4 | Custom |
Endpoint Access Matrix
| Category | STREAM | QUANT | PULSE | ORACLE |
|---|---|---|---|---|
| Market Data | ✓ | ✓ | ✓ | ✓ |
| Open Interest | ✓ | ✓ | ✓ | ✓ |
| Risk Engine | ✓ | ✓ | ✓ | ✓ |
| ETF Tracker | ✓ | ✓ | ✓ | ✓ |
| Accuracy & QA | ✓ | ✓ | ✓ | ✓ |
| Heatmap | - | ✓ | ✓ | ✓ |
| Whale Intelligence | - | ✓ | ✓ | ✓ |
| On-Chain Metrics | - | ✓ | ✓ | ✓ |
| Unicorn Metrics | - | ✓ | ✓ | ✓ |
| Options & Greeks | - | ✓ | ✓ | ✓ |
| UTXO On-Chain | - | ✓ | ✓ | ✓ |
| WebSocket (Market Data) | ✓ | ✓ | ✓ | ✓ |
| Intelligence Engine | - | - | ✓ | ✓ |
| Signals | - | - | ✓ | ✓ |
| Paper Trading | - | - | ✓ | ✓ |
| Nexus AI Chat | - | - | ✓ | ✓ |
| WebSocket FastFeed | - | - | ✓ | ✓ |
| ML Predictions | - | - | - | ✓ |
| Forward Validation | - | - | - | ✓ |
Security Best Practices
- -Store API keys in environment variables. Never commit keys to version control.
- -Rotate keys periodically from the Developer Portal.
- -Use server-side requests. Never expose your key in client-side JavaScript.
- -If a key is compromised, revoke it immediately from the Developer Portal and generate a new one.