Technical analysis and sizing
Indicators, levels, patterns, structure, regimes, correlation and position sizing.
get_indicator
Compute one of 16 indicators (RSI, MACD, ATR, SMA, EMA, BOLLINGER, ADX, STOCHASTIC, CCI, PARABOLIC_SAR, ICHIMOKU, WPR, MFI, STDDEV, DEMARKER, MOMENTUM) server-side from closed bars. order:"newest_first": values[0] is the latest CLOSED bar and equals current. Raw numbers only (no signals). Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_indicator
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | yes | — | |
indicator | any | yes | — | |
params | object | no | — | Indicator parameters, e.g. {"period":14}. Defaults are listed by the indicator. |
applied_price | CLOSE | OPEN | HIGH | LOW | MEDIAN | TYPICAL | no | "CLOSE" | |
count | integer | no | 3 |
Example request:
{
"symbol": "BTC/USDT:USDT",
"timeframe": "M1",
"indicator": "<indicator>"
}check_confluence
Evaluate up to 10 indicator/price conditions on the latest closed bar (cross_above/cross_below use the previous bar). Returns per-condition booleans (met:null when an input is unavailable — never guessed) and counts; no buy/sell verdict. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/check_confluence
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | yes | — | |
conditions | object[] | yes | — | |
match | all | any | no | "all" |
Example request:
{
"symbol": "BTC/USDT:USDT",
"timeframe": "M1",
"conditions": []
}get_key_levels
Support/resistance candidates: classic pivots from the previous completed bar of pivot_timeframe, recent fractal swing highs/lows, the lookback high/low, and psychological round numbers scaled to the price magnitude (step echoed in criteria). Raw levels, nearest first within ±10% of price. Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_key_levels
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | no | "H4" | |
pivot_timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | no | "D1" | |
lookback | integer | no | 200 |
Example request:
{
"symbol": "BTC/USDT:USDT"
}get_fibonacci_levels
Fibonacci retracement/extension levels between the most recent swing high and swing low in the lookback (or an explicit high/low). direction "up" means the move went low→high (levels retrace down from the high) and uses a swing low that came before its swing high; "down" the reverse. Without a direction the most recent swing ends the leg; when no swing pair fits, insufficient_history is returned. Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_fibonacci_levels
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | no | "H4" | |
lookback | integer | no | 200 | |
high | number | no | — | |
low | number | no | — | |
direction | up | down | no | — |
Example request:
{
"symbol": "BTC/USDT:USDT"
}detect_patterns
Candlestick patterns (doji, hammer, bullish/bearish engulfing) over the last N closed bars, order:"chronological", each with bar_time. Raw detections; no direction advice. Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/detect_patterns
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | yes | — | |
bars | integer | no | 50 |
Example request:
{
"symbol": "BTC/USDT:USDT",
"timeframe": "M1"
}detect_structure
Smart-money structures over closed bars: fair-value gaps, order blocks, liquidity sweeps, BOS and CHoCH with fixed criteria echoed in the response. order:"chronological". Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/detect_structure
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | yes | — | |
bars | integer | no | 200 | |
types | string[] | no | — |
Example request:
{
"symbol": "BTC/USDT:USDT",
"timeframe": "M1"
}get_market_structure
Multi-timeframe HH/HL/LH/LL swing sequence, trend (uptrend/downtrend/range) and BOS/CHoCH events per timeframe, plus whether the trends are aligned. Close-based confirmation; criteria echoed. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_market_structure
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframes | string[] | no | ["H1","H4","D1"] | |
bars | integer | no | 200 |
Example request:
{
"symbol": "BTC/USDT:USDT"
}get_volatility_regime
Classify volatility as compressed/expanding/trending/choppy from ATR ratio, Bollinger-bandwidth percentile and Kaufman efficiency ratio (fixed thresholds echoed). Also returns er and, with include_adx, adx_h4/adx_d1 so label-vs-ER overrides need no extra calls. Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/get_volatility_regime
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | no | "H4" | |
lookback | integer | no | 100 | |
include_adx | boolean | no | false |
Example request:
{
"symbol": "BTC/USDT:USDT"
}get_correlation_matrix
Pairwise correlation (symbols default to the connection's trade universe, up to 20; scope:"exchange_top" uses the top USDT markets of the connection's market type by volume) of log returns (method "returns") or closes aligned by bar time, with single-linkage clusters above cluster_threshold. residual_vs:"BTC" first removes each asset's BTC beta (crypto is one-factor dominated: raw alt correlations are all high) and reports beta_to_btc. NaN cells (insufficient overlap) are returned as null. Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/get_correlation_matrix
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbols | string[] | no | — | |
scope | universe | exchange_top | no | "universe" | |
timeframe | M1 | M5 | M15 | M30 | H1 | H4 | D1 | W1 | no | "H4" | |
bars | integer | no | 200 | |
method | returns | close | no | "returns" | |
residual_vs | BTC | no | — | |
cluster_threshold | number | no | 0.7 |
Example request:
{}calculate_position_size
Size a position from a stop distance and a risk budget (risk_usdt, or risk_percent of account equity). Uses the single sizing function shared with CHECK_ORDER. Returns size_usdt (what to pass to place_order), amount_base, contracts, actual risk, min-notional check, rounding loss, required margin and estimated liquidation vs the stop, and max_leverage_for_stop (the highest leverage that keeps liquidation ≥ 1.5× the stop distance beyond the stop, ≈ 1 / (1.5 × stop_distance_pct + mmr)). Available on every tier.
Capability: read · read-only · REST: POST /v1/tools/calculate_position_size
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
entry_price | number | no | — | |
stop_price | number | yes | — | |
risk_usdt | number | no | — | |
risk_percent | number | no | — | |
leverage | number | no | — |
Example request:
{
"symbol": "BTC/USDT:USDT",
"stop_price": 0
}estimate_fill
Estimate a market order's fill by walking the live order book for size_usdt: average price, slippage vs mid in bps, levels consumed, taker fee and total cost. Basis is "book_walk" (no queue position, no latency). Requires the analytics capability (Pro and above).
Capability: analytics · read-only · REST: POST /v1/tools/estimate_fill
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
symbol | string | yes | — | Canonical ccxt symbol: BTC/USDT:USDT (perp) or BTC/USDT (spot). Aliases like BTCUSDT are accepted and the canonical symbol is echoed. |
side | buy | sell | long | short | yes | — | |
size_usdt | number | yes | — |
Example request:
{
"symbol": "BTC/USDT:USDT",
"side": "buy",
"size_usdt": 0
}