Authentication
The API has three tiers. Anonymous (no key) requests are treated as free tier.
| Tier | Daily limit | Lookback | Who gets it |
|---|---|---|---|
| free | 5 / day | 7 days | Default for all users, including anonymous requests |
| pro | 500 / day | 30 days | Active paid Pro subscription, OR founding members within their first year |
| dev | 1,000 / day | Full archive | Active paid Max subscription |
All tiers get every event-level endpoint. The differences between tiers are the daily request cap and the lookback window. Free tops out at 7 days of history, Pro reaches 30 days, and Max reaches the full archive.
The Market endpoints are Max-only: Free and Pro receive 401 dev_tier_required. The same gating applies to the corresponding MCP tools (get_market_articles, get_market_tags, get_ticker_articles, get_trending_tickers).
Anonymous requests (no key) are subject to a shared per-IP rate limit and restricted to the free 7-day lookback window. Attach a key to get a stable per-user quota, extended history, and usage tracking on the account page.
Getting a key
- Sign up at https://divergence.news/auth/signup.
- Open https://divergence.news/account.
- Click "Generate API key", optionally label it ("My laptop", "CI bot").
- Copy the key once. The full key is shown only at creation time; only the prefix (e.g.
dv_api_AbCd...) is retained.
The key format is dv_api_ followed by 43 url-safe base64 chars. Treat it as a secret. Keys can be revoked at any time from the account page.
Sending the key
Use either header form:
curl -H "X-API-Key: dv_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
"https://divergence.news/api/v2/events?limit=10"
curl -H "Authorization: Bearer dv_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
"https://divergence.news/api/v2/events?limit=10"
Header auth only. Query-string tokens are rejected.
Error responses
| Status | Code | When |
|---|---|---|
| 401 | invalid_api_key | The key was supplied but does not match any active key. No silent downgrade to anonymous. |
| 401 | archive_token_required | The request reaches data older than your tier's lookback window: 7 days for Free, 30 days for Pro, full archive for Max. |
| 429 | daily_limit_exceeded | You hit your tier's daily cap. Resets at UTC midnight. |
| 429 | rate_limited | Per-minute burst limit. See rate-limits. |
MCP tokens
Max-tier subscribers can also generate dv_mcp_<token> keys for the MCP server (Claude Desktop and other MCP clients). They are managed from the same account page and require an active Max tier.