Simulate Validate

Changed on

Offload OOS/Monte-Carlo validation to a worker thread (event-loop safe).

post/simulate/validate

Request

  • Base URL: https://api.pruviq.com (the document declares no server; this is the origin it was published from)
  • URL: https://api.pruviq.com/simulate/validate
  • Auth: none declared

Request body

record_provenanceboolean

Capture actual engine/input hashes for a fresh registry-strategy execution; bypass result cache, retain compute limits

strategystring

Strategy ID (ignored when entry is provided — custom-conditions mode)

directionstring nullable
sl_pctnumber
tp_pctnumber
max_barsinteger
market_type'futures' | 'spot'
top_ninteger nullable

Number of coins (null = top 50)

symbolsstring[] nullable
oos_pctnumber

OOS split %

mc_runsinteger

Monte Carlo runs

start_datestring nullable

Backtest start date (YYYY-MM-DD)

end_datestring nullable

Backtest end date (YYYY-MM-DD)

timeframe'1H' | '2H' | '4H' | '6H' | '12H' | '1D' | '1W'

Candle timeframe: 1H, 2H, 4H, 6H, 12H, 1D, 1W

avoid_hoursinteger[] nullable

UTC hours to avoid entering trades (0-23). null = use strategy default

avoid_monthsinteger[] nullable

Months to avoid entering trades (1-12). null = no month filter

min_vol_regimenumber nullable

Minimum ATR ratio (current ATR / 14-period ATR MA) to allow entry. e.g., 0.7 = skip low-volatility periods. null = no filter

namestring nullable

Custom strategy display name (custom-conditions mode only)

indicatorsobject nullable

Indicator configs for custom-conditions mode: {'bb': {'period': 20}, 'ema': {}, ...}

entryobject nullable

Entry conditions tree: {'type': 'AND', 'conditions': [...]}. Presence switches validation to custom-conditions mode (strategy field ignored).

exit_conditionsobject nullable

Optional exit-signal conditions tree (custom-conditions mode only), same shape as entry.

tp_source'custom_pct' | 'trailing'

Exit mode (custom-conditions mode only): custom_pct = fixed TP/SL; trailing = trailing stop (tp_pct is the trail distance)

trailing_pctnumber nullable

Trailing stop distance % (custom-conditions mode only). If null and tp_source=trailing, uses tp_pct.

Response

Successful Response

registry_contract_version'completed-registry-oos-v1' nullable
oos_split_datestring nullable
strategystring required
directionstring required
coins_usedinteger required
top_n_requestedinteger nullable

The top_n this run resolved to. null for explicit symbols= requests (no top-N universe).

eligible_universeinteger nullable

Coins eligible for a top-N universe at run time (stablecoins unless include_stablecoins, non-crypto and liquidity-dead markets excluded), read in the same selection as the coins run. null for symbols= requests (and on /backtest when the strategy is invalid, is_valid=false).

universe_cappedboolean nullable

eligible_universe < top_n_requested: the request asked for more coins than exist, so the whole eligible universe ran. A cap only — coins lacking data are reported in coins_missing_data. null for symbols= requests.

run_capinteger nullable

Q-B131: the per-request limit that actually stopped this run before min(top_n_requested, eligible_universe) coins, or null when none did (coins_used then reaches that number, data gaps aside). See run_cap_reason for which limit.

run_cap_reason'indicator_cache' | 'compare_max_coins' nullable

Q-B131: which limit run_cap is. «indicator_cache»: the cached path of /simulate/compare, /simulate/validate and /simulate/optimize computes at most the indicator-cache size per request (no all-coin hold; larger runs are a separate async path, Q-B132). «compare_max_coins»: kept for compatibility — since Q-B55 /simulate/compare rejects a top_n above its limit (COMPARE_MAX_COINS) with HTTP 400, so this cut no longer binds. When both apply, the smaller one — the one that bound — is reported. null when no limit bound.

coins_not_computedstring[]

Q-B131: explicitly requested symbols= that were not run because the per-request compute limit (the indicator-cache size) was reached. Empty when every requested symbol ran. Distinct from coins_missing_data (coins without candles in the window).

data_rangestring required
oos_pctnumber required

Changes

    • info

      added the new optional request property

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status