zanshinflow.com/api · v1
The Zanshin Flow API
One request, one symbol, the levels the app is showing right now: the gamma flip and regime, the call and put walls, the king strike and max pain, with the dealer gamma at each. JSON, or one level per line for tools without a JSON reader. It's what the TradingView extension and the MotiveWave and NinjaTrader studies run on, and it's included in the subscription.
Authentication
Every request carries a key: Authorization: Bearer zsmw_…. Make one on the TradingView page while signed in (it's the same key the studies use; three devices at a time). The key works while the subscription or trial is active and is checked every five minutes.
https://www.zanshinflow.com/api/v1/levels?sym=ES| parameter | values | |
|---|---|---|
sym | SPX SPY QQQ NDX IWM ES NQ RTY GC CL | required. Each futures symbol is its own options book, live overnight. |
format | lines | plain text, one NAME,price per line, instead of JSON. |
prices | fut | with format=lines: the mapped future's prices (SPX → ES, NDX / QQQ → NQ, IWM → RTY). In JSON both are always present. |
The answer
{
"sym": "SPX", "as_of": 1794150000, "session": "RTH", "stale": false,
"spot": 7376.86, "regime": "SHORT_GAMMA", // LONG_GAMMA, SHORT_GAMMA or AT_FLIP
"flip": 7400, "king": 7410, "max_pain": 7390,
"call_walls": [7430, 7450, 7475], // biggest call gamma above price, nearest first
"put_walls": [7375, 7360, 7340],
"king_gex": 2410000000, // net dealer gamma at the strike, signed dollars
"call_wall_gex": [1620000000, 910000000, 440000000],
"put_wall_gex": [-1870000000, -940000000, -510000000],
"net_gex": -1200000000,
"fut": { // the same levels on the mapped future, with its spot
"sym": "ES", "spot": 7402.25, "flip": 7425.5, "king": 7435.5, "max_pain": 7415.5,
"call_walls": [7455.5, 7475.5, 7500.5], "put_walls": [7400.5, 7385.5, 7365.5],
"king_gex": 2410000000, "call_wall_gex": [...], "put_wall_gex": [...]
}
}
Prices are strikes in the book's own terms; fut moves them with the live basis. stale is true when the book is older than three minutes (a weekend, an outage). Errors: 403 with a reason when the key is unknown, revoked or the subscription has ended; 400 for a symbol not listed; 503 while a symbol has no book yet.
…/api/v1/levels?sym=SPX&format=lines&prices=futSYM,ES
AS_OF,1794150000
STALE,0
REGIME,SHORT_GAMMA
SPOT,7402.25
KING,7435.5
FLIP,7425.5
MP,7415.5
CW1,7455.5
CW2,7475.5
CW3,7500.5
PW1,7400.5
PW2,7385.5
PW3,7365.5
Freshness and limits
The engine publishes about every 30 seconds; the API caches each symbol for 10 seconds, so polling faster returns the same answer. There's no request quota beyond that, but a tool that polls every 10–30 seconds per symbol is the intended use; anything that fans out across every symbol every second will be rate-limited. The answer is a few hundred bytes.
Examples
# curl
curl -H "Authorization: Bearer $ZANSHIN_KEY" "https://www.zanshinflow.com/api/v1/levels?sym=NQ"
# Python
import requests
r = requests.get("https://www.zanshinflow.com/api/v1/levels", params={"sym": "ES"},
headers={"Authorization": f"Bearer {KEY}"}, timeout=10)
L = r.json(); print(L["regime"], L["flip"], L["call_walls"], L["put_walls"])
// JavaScript
const r = await fetch("https://www.zanshinflow.com/api/v1/levels?sym=SPX", { headers: { Authorization: `Bearer ${KEY}` } });
const L = await r.json();
Ready-made clients
- TradingViewBrowser extension: the levels drawn on the chart, updating intraday.
- MotiveWaveThe Zanshin study: the look, Delta Bars, Heavy Absorption, Volume Profile.
- NinjaTrader 8ZanshinLevels.cs: the levels as an indicator, in futures prices.
Questions
Does Zanshin Flow have an API?
How fresh are the levels?
Can I get the whole gamma profile?
Not financial advice. The levels are Zanshin Flow's estimates of dealer positioning; nothing here is a recommendation to buy or sell anything. Use of the API is under the terms.