Auth-gated REST API for factor / similarity / label data. Authenticate with POST /api/auth/login to get a JWT, then send Authorization: Bearer <token> on every auth-marked endpoint.
?format=json or send Accept: application/json to get the JSON form.| method | path | auth | purpose |
|---|---|---|---|
| GET | /api/health | public | liveness check |
| GET | /api/status | public | health + bundle freshness + DB reachability (returns 503 when degraded — designed for uptime monitors) |
| GET | /api/manifest | public | static-bundle metadata (latest_date, ticker_count) |
| GET | /api/config | public | runtime feature flags (paid tiers on/off, etc) |
| GET | /api/docs | public | this endpoint |
| GET | /api/openapi.json | public | OpenAPI 3.0 spec — typed schema for LangChain / OpenAI / Anthropic / ChatGPT Actions / autogenerated SDKs |
| GET | /api/docs/swagger | public | Swagger UI explorer for the API spec |
| GET | /api/demo/{ticker} | public | no-auth taste: one ticker, curated factors + 8 cosine look-alikes (powers /explore.html) |
| GET | /api/demo/market-context | public | no-auth market-regime snapshot: today's SPY-vol regime + VIX/DXY + VX term structure (powers the public Explorer banner) |
| POST | /api/auth/register | public | create an account (gated by ENABLE_REGISTRATION + invite_code) |
| POST | /api/auth/login | public | exchange email+password for a JWT |
| POST | /api/billing/webhook | public | Stripe webhook (signature-validated) |
| GET | /api/auth/me | auth | current user profile + tier + daily usage |
| GET | /api/features/{ticker} | auth | feature row(s). Stock/ETF = FREE+; futures (VX, ES, NQ, CL, GC, ZN, …) = PRO+; intraday-derived columns (overnight_ret, intraday_ret, opening-range, VWAP deviation, intraday_rv, late_drift) auto-included for PRO+. No date args = latest. ?date= or ?start_date=&end_date= = historical (last 252 trading days). |
| GET | /api/top?factor=mom&n=25 | auth | top-N by factor (mom, meanrev, comp_score, ...) |
| GET | /api/market-context | auth | whole-universe derived analytics — dispersion, breadth, regime odds + cross-asset (DXY/VIX/VVIX/VIX9D/TNX/XAU/VX z20). FREE = today only; HOBBY+ = 252-day history |
| GET | /api/vx-term-structure | HOBBY+ | VIX futures contango/backwardation: (VX_continuous − VIX) / VIX + 252-day history |
| GET | /api/report-card/{ticker} | HOBBY+ | derived per-ticker digest — snapshot, percentile ranks, risk cluster, regime, unusualness |
| GET | /api/risk-cluster/{ticker} | PRO+ | risk regime a ticker's factor analogues landed in — calm / normal / stressed |
| GET | /api/embedding/{ticker} | QUANT | the 32-D regime-aware factor-state embedding vector |
| GET | /api/csv/features?ticker=AAPL | auth | CSV export |
| GET | /api/vector-search/similar/{ticker} | auth | precomputed top-K cosine lookalikes |
| GET | /api/labels/{ticker} | auth+ | forward-return labels (PRO+) |
| GET | /api/alerts/rules | auth | list user alert rules |
| POST | /api/alerts/rules | auth | create alert rule |
| DELETE | /api/alerts/rules/{id} | auth | delete alert rule |
| POST | /api/push/subscribe | auth | store a browser PushSubscription (PWA install + browser alerts) |
| POST | /api/push/unsubscribe | auth | drop a stored PushSubscription |
| POST | /api/billing/create-checkout | auth | Stripe checkout URL for tier upgrade |
| POST | /api/billing/create-portal | auth | Stripe billing portal URL |
| GET | /api/usage | auth | today + month-to-date usage stats |
| GET | /api/recent-activity | auth | last 50 API calls by this user |
| GET | /api/me/keys | auth | list dev API keys |
| POST | /api/me/keys | auth | mint a new dev API key (shown once) |
| DELETE | /api/me/keys/{id} | auth | revoke a dev API key |
| GET | /api/admin/stats | admin | aggregate dashboard: total users, paid users, calls today/this month, top users |
| GET | /api/admin/recent-activity | admin | global activity feed (last 100 calls across all users) |
| GET | /api/admin/users | admin | list users with daily / monthly usage |
| POST | /api/admin/users | admin | create a user (bypasses registration gate) |
| PATCH | /api/admin/users/{id} | admin | change tier / is_admin / status |
| GET | /api/admin/invites | admin | list outstanding invite codes |
| POST | /api/admin/invites | admin | mint invite codes |