Insights
How to Get a Stock Market Risk Regime Indicator via API
Alphanume Team · June 9, 2026
Wire Alphanume's daily risk-on / risk-off classification into your strategy as a one-line filter.
A regime filter is one of the cheapest improvements you can make to a systematic strategy, but only if the signal is clean and point-in-time. The Alphanume S&P 500 Risk Regime endpoint gives you a single daily flag, risk-off or risk-on, that you can read in one line of code.
The endpoint
GET https://api.alphanume.com/v1/sp500-risk-regimeAuthenticate with ?api_key=alp_your_key or an X-API-Key header. Each row carries a date and a risk_regime value of 1 (risk-off) or 0 (risk-on).
Read today's regime
import requests
r = requests.get(
"https://api.alphanume.com/v1/sp500-risk-regime",
params={"api_key": "alp_your_key"},
)
regime = r.json()["data"][0]["risk_regime"]
trade_enabled = regime == 0 # only take new risk when risk-onUse it as a backtest overlay
Pull the full history with date range filters and join it to your strategy returns by date:
GET https://api.alphanume.com/v1/sp500-risk-regime?date_gte=2026-01-01&api_key=alp_your_keyNow you can compare your strategy's performance in risk-on versus risk-off days, or simply mask out trades that would have been opened during risk-off sessions. The signal is fixed once published, so the regime value for any past date is exactly what would have been available that morning.
Practical patterns
- Hard filter: only open new positions when
risk_regimeis 0. - Soft filter: cut position size by half during risk-off regimes instead of going flat.
- Hedge trigger: add index puts or reduce beta when the regime flips to 1.
Access and limits
The signal is on the free tier as a rolling 30-day delayed window, with Pro raising the rate limit to 600 requests per minute. The signal updates daily at 10:10 AM ET. Start with a free Alphanume API key and the API documentation, or explore it on Alphanume.
A cheap, high-leverage overlay
A regime filter is one of the least expensive improvements you can make to a systematic strategy. The signal is one value per day, so wiring it in is a single comparison: gate new risk on risk_regime being 0, or scale exposure down rather than off when it flips to 1. There is almost no integration cost.
The leverage comes from honest history. Because the classification is fixed once published, you can join it to past strategy returns by date and segment performance into risk-on and risk-off days without lookahead. That tells you where your edge actually lives, and whether a regime filter would have helped or hurt.
Frequently asked questions
What is the risk regime endpoint?
GET https://api.alphanume.com/v1/sp500-risk-regime. Authenticate with ?api_key=alp_your_key or an X-API-Key header. Each row carries a date and a risk_regime of 1 (risk-off) or 0 (risk-on).
How do I use it as a filter in code?
Read the latest risk_regime value and gate new positions on it, for example only opening trades when the value is 0. It is effectively a one-line overlay.
Can I apply it to a historical backtest?
Yes. Pull the history with date range filters and join it to your strategy returns by date. The value is fixed once published, so it matches what was available each morning.
What is a soft filter versus a hard filter?
A hard filter goes flat during risk-off. A soft filter keeps trading but cuts position size, for example halving exposure when risk_regime flips to 1.
When does the signal update?
Daily at 10:10 AM ET. A single morning call gives you the current regime for the session.