All servers / Finance / DWLF MCP server
DWLF MCP server
MCP server for DWLF market analysis platform — exposes market data, indicators, signals, strategies, backtests, portfolio, trade journal, and more as AI-accessi
Tested by ConnectATDScore 89 out of 100. Tested 2026-11-19 on package version 0.68.0. Package: @dwlf/mcp-server · source
Score breakdown
| Runs | 18 / 20 | |
|---|---|---|
| Tool descriptions | 19 / 20 | |
| Package safety | 20 / 20 | |
| Maintenance | 20 / 20 | |
| Adoption | 12 / 20 |
What we saw
- Starts and answers the MCP handshake: yes (2.9 seconds including download)
- Tools offered: 116
- Last published: 2026-11-17
- Weekly downloads (npm): 1,259
- License: MIT · Direct dependencies: 3
Want this server set up for your team?
ConnectATD builds AI automation and wires up MCP servers like this one. Tell us what you are trying to do.
Talk to ConnectATDTools and how they are described
Agents choose tools from these descriptions. Under each name you can see how many of its parameters are explained.
dwlf_get_market_data3 of 3 parameters describedGet OHLCV candle data (open, high, low, close, volume) for a trading symbol at a chosen timeframe. Reach for this when you need ACTUAL BARS — sweeps, ranges, exact intraday highs/lows, "did price touch $X on date D", the close on a specific bar — rather than the pivot-based reconstruction from `dwlf_get_price_picture` / `dwlf_get_events`. Timeframes: `daily`, `weekly`, `hourly` (hourly is available only for symbols that have 1h data). Gated to the owner account; other API keys get a 403 with a pivot-based fallback hint.
dwlf_get_quote2 of 2 parameters describedGet the latest price (close + date) for one or more symbols. Lightweight and API-key-accessible — works for ANY tracked symbol, including off-watchlist ones the daily briefing does not cover. Returns ONLY the current level (no OHLCV, no history) — for bar data use dwlf_get_market_data (owner-account only) or dwlf_get_price_picture for a pivot narrative. Ideal for marking a trade/skip to current price or pricing an arbitrary symbol. Unknown symbols come back with found:false (not an error).
dwlf_list_symbolsno parametersList all available trading symbols with metadata. Use this to discover what symbols are available on DWLF.
dwlf_get_support_resistance1 of 1 parameter describedGet the current key levels (support and resistance) for a trading symbol, from daily candles, recomputed nightly. Each level is a zone (`zone.lower`/`zone.upper`, ATR-wide) built from confirmed cycle pivots (daily and weekly) and the previous week, month and year high/low and year open; round numbers only add confluence. `sources` lists what built it, `score`/`scoreParts` rank it (touches × reaction × recency × timeframe × confluence), `distanceAtr` is how far it sits from the close, and `id` is stable across nights. Up to 5 per side, nearest first. Interactions with these levels are daily events: dwlf_get_events with type `keyLevel.<kind>` (formed, approached, tested, rejected, broken, retested, flipped, reclaimed, expired), each with a `keyLevel` block (levelId, kind, direction, role, levelPrice, zone edges).
dwlf_get_events11 of 11 parameters describedGet indicator events (cycle lows/highs, crossovers, breakouts, divergences, etc.). Filter by a single `symbol` or a `symbols` watchlist, by `type` (e.g. `cycle.low.confirmed`), by `timeframe` (1d / 4h / 1h — without this the response is dominated by hourly noise), and by time window via `days` or explicit `fromDate` / `toDate`. 📑 PAGINATION: results are paged. When scoped by `customEventId` or `eventName`, this tool AUTO-FOLLOWS the cursor and returns the event’s COMPLETE history in one call (`filtersApplied.autoPaginated` / `pagesFetched` report what happened) — but you must still pass a wide `days` (e.g. 2000) or `fromDate`/`toDate`, or the 7-day default caps how far back it looks. For non-scoped queries a `cursor` in the response means there are MORE pages: follow it (or use a tight `fromDate`/`toDate`) before trusting any count or “oldest” date — page 1 holds only the most-recent matches. 💡 For accounts without raw OHLC access (most API-key callers), this is the canonical way to reconstruct price action: cycle pivots, swing points, MA/EMA crosses and trendline breaks each carry the price at the event date; for a single-call summary across those types, use `dwlf_get_price_picture` instead. RSI(14): `rsi.exit.overbought` / `rsi.exit.oversold` (back inside 70 / 30), `rsi.midline.bullish` / `rsi.midline.bearish` (a close across 50). Divergence: `rsi.divergence.*` and `dss.divergence.*`, each `{regular,hidden}.{bullish,bearish}` (e.g. `rsi.divergence.regular.bullish`), compare price with RSI(14) or DSS at consecutive confirmed daily cycle lows (bullish) or highs (bearish). Each row carries a `divergence` block (both pivots' prices, both oscillator readings, barsBetween); it is dated by the later pivot and knowable at `eventTimestamp`. SMA reclaim / loss (daily): `sma.reclaimed` / `sma.lost` on the 50, 100 and 200-day SMA (`length` on the row): two closes in a row on the other side, each at least half an ATR beyond the average, so a one-day poke through it (`sma.cross.*`) is not one. ADX / DMI (daily, Wilder 14): `adx.trend.started.bullish` / `.bearish` (ADX rises to 25; side from the DIs), `adx.trend.faded` (ADX falls below 20: ranging again), `adx.di.cross.bullish` / `.bearish` (DIs cross while ADX >= 20); each row carries an `adx` block (adx, previousAdx, plusDI, minusDI, threshold). Context (trending vs ranging), not an entry trigger, and events only: not builder nodes. Trend starts and fades fire a few times a year per symbol, so pass a wide `days` (e.g. 365) for them.
dwlf_get_price_picture4 of 4 parameters describedAggregate the price-meaningful indicator events for a symbol into a chronological narrative — cycle pivots, swing points (HH/HL/LH/LL, breaks, sweeps), MA/EMA crosses, SMA 50/100/200 reclaims and losses (`sma.reclaimed` / `sma.lost`), trendline breaks and breaches, bollinger breaks, key level breaks / flips / reclaims. The levels themselves are not included (use dwlf_get_support_resistance), nor SMC, VWAP, fib or DSS events (use dwlf_get_events). Each row carries date + price (or level) + a human-readable label. Use this when you need structural price context for a symbol but do not have raw OHLC access, or when you want a clean one-call summary instead of stitching together multiple `dwlf_get_events` queries. Returns events sorted newest-first.
dwlf_get_cycle_setups1 of 1 parameter describedThe Cycle Setup Screener: universe-wide cross-reference of the WEEKLY cycle timing window with DAILY cycle confirmation, both sides, ranked best-first. Stages: `confirmed_setup` (weekly window open AND daily pivot confirmed fresh <=15d — the multi-timeframe trigger has fired), `awaiting_confirmation` (daily pivot provisional, confidence % included), `window_open` (timing window open, no daily signal yet). Each row: weekly window position (early/mid/late + days-since-pivot), `weekly.timing`, daily pivot price/confidence/freshness, last close and % from pivot (the entry-freshness number — fresher entries pay less confirmation tax). Start daily market reviews here: the long/short counts alone summarise the universe regime (e.g. 9 long vs 33 short = late-cycle topping). `weekly.timing` is the STORED weekly window, the same edges the chart draws: `earliest`, `opens`, `closes`, `hardMax` (dated edges), `phase` (upcoming | open | overdue | missed), `n` (gaps behind the edges), `calibration`, `verification` (always `unverified` while the detection gate stands failed), `rulerAgreesWithState`, `generation` and `projectionHash`; null when the store holds no window for the series. Reads the persistent cycle FSM state — exactly what the cycle engine itself sees — and the window store for timing; no window is computed here. ⚠️ A symbol whose weekly window is not yet open is ABSENT from every list, not suppressed — for its window dates call `dwlf_get_cycle_windows`. DEPTH (`depth: true`, DWLF-416): each row also carries `depth`, its weekly window's derived price band (the same object `dwlf_get_cycle_windows` returns; long rows = the fall into the weekly low, short rows = the rise into the weekly high), and `depth.reading.position` places the last weekly close: `in-zone` (inside the p25–p75 of past cycles' moves — call it out), `shallow` / `deep` / `beyond`, or `not-reached` (short of the smallest move on record — not worth raising). Context, NOT a gate or target: it does not change the stage or ranking. A missing band says why in `depthUnavailable` (incl. `ruler-mismatch` when the band's window is not the setup's). UI equivalent: https://www.dwlf.co.uk/screener
dwlf_get_ranges3 of 3 parameters describedRange / support-resistance CONTEXT derived from cycle pivots — answers "where in a range are we?". Pass a `symbol` for that symbol's current daily + weekly ranges, or OMIT it to list every symbol currently in a range (optionally filtered by `timeframe` / `state`). Each range carries: bounds (floor/ceiling/touches/since); a `live` block — livePosition (0 = floor, 1 = ceiling) and liveState (near_floor | mid_range | near_ceiling | above | below), recomputed from the latest price = WHERE PRICE IS NOW; and a `snapshot` block — the weekly lifecycle narrative (state broke_out_up / broke_down / retesting_* + brokeDaysAgo + ageDays), which can be up to a week old. Use it for the classic reads: "at the BOTTOM of a range" (near_floor — significant alongside a daily cycle low), "at the TOP of the range — think twice about entering here", "broke out of the range", "retesting an edge". IMPORTANT: "not in a range" is a first-class, common answer — a symbol with no clear current range simply is not returned in the list, or returns inRange:false. Prefer `live` for current location and `snapshot` for the lifecycle narrative. NOTE: this is context, not a trade signal.
dwlf_get_setup_transitions5 of 5 parameters describedCycle Setup Screener stage transitions in ONE call — the five `cycle.setup.*` event types merged and pre-grouped into `entered` / `downgraded` / `left`, newest first. Use this instead of five separate `dwlf_get_events` calls (that endpoint filters one `type` per request). 💡 This is the delta feed: what CHANGED stage, not what currently sits in the screener — for the current standing list use `dwlf_get_cycle_setups`. ⚠️ SEEDED ROWS ARE EXCLUDED BY DEFAULT. The first live run of the transitions job seeds the entire current state as `seeded: true` rows (≈34 of them on 27-Aug-2026); they are bookkeeping, not news, and SPT’s dispatcher does not deliver them either. Counting them as transitions would report a flood of false “new setups”. `suppressedSeeded` tells you how many were hidden. Pass `includeSeeded: true` only when auditing the seed itself. 📅 Transitions are written by the 04:12 UTC job, so the freshest data appears after that. 📑 Each type is paginated to completeness (cursor-followed, 10-page cap). If a type hits the cap the response carries `truncated: true` + `truncatedTypes` and the counts are PARTIAL — narrow with a smaller `days` or a `symbol`. A per-type fetch failure sets `partial: true` + `failedTypes` rather than failing the whole call.
dwlf_get_cycle_windows6 of 6 parameters describedWhen is this symbol's next cycle LOW (or HIGH) due? Returns the STORED cycle timing window per side — the same edges the chart draws and the screener reads — for ONE symbol, whether or not the window is open yet. Use it for "when does X's next weekly-low window open?", "when is X's next DAILY low due?" and "how many weeks since X's last weekly low, against its usual gap?". Unlike `dwlf_get_cycle_setups`, which only lists symbols whose weekly window is already open (and adds `phase` / early-mid-late for them), this answers for any symbol but carries NO phase: to say whether a window is open, overdue or missed, compare today with the dated edges below. SHAPE: `{ symbol, timeframe, generation, generationSource, verification, low, high }`. Each side is `null` when the store holds nothing for it, otherwise `{ symbolUsed, current, retiredAbove, history }`. `current` is the live window: `ruler` (the confirmed pivot the window counts from — `pivotDate`, `price`); dated edges in order `earliest` (the shortest gap on record; weekly and daily — a daily one is always an estimate, `extrapolated: true`; null when there is none) → `opens` (early bound) → `centre` (typical) → `closes` (late bound) → `hardMax` (the last bar by which the pivot must arrive or the window is a miss), each with `bars` counted from the ruler and `extrapolated: true` when it lies beyond the last candle; `gaps` (the gap statistics the band was drawn from, incl. `used` = the inter-pivot gaps in bars, `n`, `spreadPct`); `status` (the store row lifecycle: projected | closed — NOT the screener's phase); `calibration` (calibrated = the gap chain is long enough to mean anything); `provenance.projectionHash` — the versioned definition of how the edges are drawn; when it changes, the edges mean something new. Closed windows in `history` carry an `outcome` — where the pivot actually landed (`landedInside`, `daysFromOpen`, …) — which is how to judge how reliable THIS symbol's windows have been. ⚠️ Read `verification`: while it says `unverified` (it does for every window as long as the detection gate stands failed), treat the edges as rough timing, not a forecast. ⚠️ The store covers WEEKLY and DAILY (daily folded from the ledger's daily lows/highs); `timeframe: "1h"` answers with null sides rather than a computed substitute. On daily, `bars` are trading candles, and an extrapolated edge's date is an estimate from average bar spacing (it can fall on a non-trading day until real bars exist). PRICE ZONE (`depth: true`, DWLF-416): each window also carries `depth`, DERIVED at read time: how far price MOVED into this side's past pivots (`pct` min/p25/median/p75/max, a fall into a low or a rise into a high, over the trailing `n` completed cycles; `thin` when few) and `zone` = that band as prices from the current cycle's `anchor`: the confirmed opposite pivot (`anchor.source: confirmed-pivot`, `pivotDate`; the highest high after a low ruler, the lowest low after a high ruler) or, when none has confirmed or price has gone beyond it, the cycle's extreme SO FAR (`running-extreme`, `barDate`, not yet a confirmed pivot). `zone` is null when there is no anchor (a pivots-only band — `anchorBasis: pivots`, e.g. candles not licensed or unavailable — before the opposite pivot confirms) or no completed cycles to measure (`pct` null). The CURRENT window also carries `reading`: `position` of the last weekly close in the band — `not-reached` (short of the smallest move on record: the band does not apply yet) | `shallow` | `in-zone` (inside p25–p75: the one to call out) | `deep` | `beyond` — plus `movePct`, `price` and `closeDate`. An API key without raw-candle rights gets `price`/`movePct` null (`priceWithheld: true`), the position kept, and a pivots-only band (`candlesUnavailable: not-licensed`). ⚠️ `depth.verification.state` is `context-only`: a distribution of past moves, NOT a target or forecast. Use it for "has X fallen far enough for a typical weekly low?", never as an entry level. A missin…
dwlf_get_divergences12 of 12 parameters describedRecent price/oscillator DIVERGENCES across every symbol DWLF tracks: dated events that happened, not signals. A divergence compares two consecutive confirmed cycle pivots: a `regular` one is price making a lower low (or a higher high) while RSI(14) or DSS does not; a `hidden` one is the reverse, a pullback inside the trend. Bullish = measured at lows, bearish = at highs. FILTERS: `days` (1-365, default 30) windows the later pivot's date; `oscillator` (rsi | dss), `kind` (regular | hidden), `direction` (bullish | bearish), `symbols` (restrict to these), `limit` (1-500; this tool sends 50 unless you set it), `timeframe` (daily, the default | weekly | all), `includeRetired` (also return divergences whose pivot the cycle ledger later superseded; by default they are left out and counted in `retiredOmitted`). CONFLUENCE: `confluence` names the layers to check around each divergence: `cycle` (a confirmed daily cycle low or high near the pivot, and whether it sits in the weekly window), `smc` (Smart Money Concepts events), `tl` (a trendline break), `weekly` (a weekly divergence agrees), `fib` (a cycle fib level). `confluenceDays` (1-30 bars, default 10) is the window; `minLayers` keeps only items matching at least that many layers (filtered by the API). Each item then carries `confluence: { matched, layers, … }`: a layer not requested is null, requested and absent is `{ matched: false }`, and a matched layer lists its dated events and a one-line `why`. Passing `timeframe` or `confluence` returns `responseVersion: 2`, which always includes `definitions` (stable wording you can quote); `explain: true` adds them to the plain read. READING IT: each item has `summary` (one plain sentence, the DWLF page's own wording: use it), both pivots' dates, prices and oscillator readings, `knowableAt` (when it could first be known: never imply it was visible earlier) and `chartUrl`. When the user wants to see one, give them its `chartUrl`. `cyclePivot.ledgerState` `unknown` or `missing` means the pivot is unverified, not confirmed. A divergence is something that happened on the chart, not a recommendation: never present one, or a confluence of layers, as a reason to buy or sell. `truncated: true` means more matched than were returned. A key whose plan lacks the cycles family gets a teaser (`locked: true`, `newThisWeek`, `requiredPlan`, `pricingUrl`) and no items: tell your human what unlocks it.
dwlf_get_stage3 of 3 parameters describedWhat stage of its market cycle is this symbol (or sector) in, on the WEEKLY chart? Returns the Weinstein stage — 1 base, 2 advance, 3 top, 4 decline — derived from the 30-week average, with `weeksInStage`, `since` (when the stage became knowable) and the recent transitions. Use it for "is X basing or advancing?", "how long has X been in Stage 2?" and, with `group` or several `symbols`, for sector breadth ("what share of metals are in Stage 2?"). This is the platform's market-cycle read: dwlf_get_regime carries no cycle phase. On a DWLF Block key the stage is the Cycles family: below the plan that reads it, it is a 403 whose error ends `[PLAN_REQUIRED; family=cycles; requiredPlan=…; pricingUrl=…]`. SHAPE (one symbol): `{ symbol, stage, stageName, weeksInStage, since, rulesVersion, verification, history: [{ to, from, baseline, knowableFrom, close }] }`. `stage: null` with `reason: "no-stage"` = too little weekly history. SHAPE (many): `{ verification, stages: { SYM: … }, unavailable: [{ symbol, reason }], breadth: { counted, withoutStage, share: { base, advance, top, decline } } }` — shares are over symbols WITH a stage. With no arguments, returns every staged symbol plus universe breadth (a large response). ⚠️ Stages are CONTEXT, not a trading signal: report the response's `verification` (state + reason) with the stage rather than presenting it as a buy/sell call. Like any trend read a stage confirms late — much of a move has happened by the time a stage changes.
dwlf_get_conditions3 of 3 parameters describedWhat are an asset's conditions right now? Bitcoin today (`asset: "btc"`). ONE call returning: the regime (daily and weekly trend, momentum, volatility; the Weinstein weekly stage; and the on-chain bands: MVRV below 1 / above 3.5, supply in profit below 50 %, 7-day STH-SOPR below 1); the COST-BASIS LADDER (price above or below the realised, short-term-holder and long-term-holder realised price, and since when); the stored weekly and daily cycle windows with today's `position` against their dates; every event on the symbol in the last `days` (price, cycle, CFTC positioning `cot.*`, on-chain `onchain.*`); and provenance. For BITCOIN, call this first, instead of stitching dwlf_get_regime, dwlf_get_stage, dwlf_get_cycle_windows and dwlf_get_events together. It carries the on-chain cost basis, the on-chain bands, the cycle windows and CFTC positioning in one read; use dwlf_get_support_resistance for BTC's S/R levels. SHAPE (responseVersion 3; the response carries `responseVersion`, so check it; 1 and 2 are the same shape from an older DWLF API, which never locks a section): `{ kind: "conditions", asset, responseVersion, framing, symbol, asOf, price, regime: { daily, weekly, stage, onchain: { status, bands[] } }, costBasisLadder: { status, onchainSymbol, sideBasis, levelsPending, rungs: [{ key, side, level, distancePct, since }], counts }, cycleWindows: { weekly, daily }, recentEvents: { days, truncated, events: [{ eventType, date, family, onchain?, cot? }] }, provenance: { sources, methodVersions, brkVersion, scoring, unavailable } }`. A rung's `side` comes from its latest on-chain cross event; `level`/`distancePct` need the stored on-chain day (`levelsPending: true` until then). On-chain readings are read from the own-data BTC symbol (`onchainSymbol`), whose price is DWLF's own BRK oracle close. ⚠️ Read before you report: - `framing`: these are CONDITIONS, NOT CALLS. Describe the state ("price is below the STH realised price since 20-Oct"); never turn it into a buy/sell/hold recommendation. `provenance.scoring` is `unscored`: no reading is a validated predictor. - `status: "pending"` means the on-chain events are not ingested yet, not that the market is neutral. Say so rather than inferring a side. - `provenance.unavailable` lists legs that failed or timed out (those fields are null). Never fill them from memory. - `asOf` holds the price bar date and the on-chain day, block height and `confirmedAt`. Quote them, so staleness is visible. - `price.withheld: true` means this API key may not receive the vendor's raw close (data licensing). Sides and states are unaffected; do not ask for the close another way. - Cycle windows carry `verification` (currently unverified): treat them as rough timing, not a forecast. - LOCKED (responseVersion 3, DWLF Block plans): a section the plan does not read (`regime.daily`, `regime.weekly`, `regime.stage`, `cycleWindows`) is `{ locked: true, lockedFamily, requiredPlan, pricingUrl }`, and an event row of such a family is `{ eventType, date, …, locked: true, lockedFamily, requiredPlan, pricingUrl }` (what fired and when; no price, levels, values or meaning). Say the reading exists and which plan unlocks it; never infer its value.
dwlf_get_indicators2 of 2 parameters describedGet the stored DAILY moving averages for a symbol: SMA and EMA at 10, 20, 50, 100 and 200 periods (computed nightly from daily closes). `latest` holds the most recent value of each, with its date; `missing` lists any average with no stored value. The backend response (`indicators`: rows grouped by average, each with its daily `data` points) is returned as is, with `latest` and `missing` added. This is the only indicator data stored as values: there is no RSI, MACD or Bollinger value series, and there is no 4h/1h data. For momentum, band and cross signals use dwlf_get_events (e.g. `dss.cross.*`, `bollinger.break.*`, `ema.cross.*`, `sma.reclaimed` / `sma.lost` for a confirmed reclaim or loss of the 50/100/200-day SMA, `atr.regime.*` for volatility expansion/contraction, `adx.trend.*` / `adx.di.cross.*` for ADX/DMI trend strength (trending vs ranging), `rsi.exit.*` / `rsi.midline.*` for RSI(14), `rsi.divergence.*` / `dss.divergence.*` for price vs oscillator at confirmed cycle pivots), or dwlf_get_regime for the trend/momentum/volatility read. `atr.regime.*`, `adx.trend.*` and the divergences are daily and fire rarely (ATR once when an episode starts), so pass a wide `days` for those.
dwlf_get_trendlines2 of 2 parameters describedGet the automatically detected trendlines for a symbol on one timeframe (daily by default; weekly; hourly only for symbols with 1h data). Each line carries its type (support/resistance), its two anchors (date + price), slope and whether it is still active. Breaks of these lines are the `trendline_break_*` / `trendline_breach_*` events in dwlf_get_events. Weekly lines are not stored for every symbol yet (BTCOC/USD has daily lines only): an empty weekly list means "none stored", not "no trend". The engine's weekly detection still emits weekly `trendline_break_*` events (for BTCOC/USD too), so read those with dwlf_get_events.
dwlf_get_active_signalsno parametersGet currently active trade signals. These are open positions or pending entries that DWLF is tracking.
dwlf_get_recent_signals7 of 7 parameters describedGet user trade signals — strategy fires recorded by the daily evaluator. Shows signal history with entry/exit prices, R-multiple targets, contextHash, current P&L if filled. Filters compose: `symbol` (single), `strategy` (full strategy field, e.g. `visual_strategy_X`), and `fromDate`/`toDate` (ISO YYYY-MM-DD) OR `days` (last N). Without any filter the default cutoff is the most-recent N signals up to `limit`. Use this rather than the older `/recent` endpoint variant — that one has a hard-coded 5-day window that silently hides older fires.
dwlf_get_signal_statsno parametersGet signal performance statistics — win rate, average P&L, total signals, and performance breakdown.
dwlf_get_watchlistno parametersGet the user's watchlist — symbols they're actively monitoring.
dwlf_add_to_watchlist1 of 1 parameter describedAdd a trading symbol to the user's watchlist for monitoring.
dwlf_get_briefing_listno parametersGet the user's BRIEFING LIST — symbols they want in the daily briefing but are NOT actively watching (Mag7, macro/dollar like UUP, sector bellwethers). Distinct from the watchlist: the daily briefing (dwlf_get_daily_briefing) covers watchlist UNION briefing list, while the watchlist alone drives the active/Today views. An empty briefing list means the briefing is just the watchlist. The whole-universe layer is the cycle screener (dwlf_get_cycle_setups); the briefing list is the curated middle tier.
dwlf_add_to_briefing_list1 of 1 parameter describedAdd a symbol to the BRIEFING LIST — briefed daily but not actively watched. Use for wider-universe context the user wants the structural read on without cluttering their watchlist (e.g. UUP for the dollar, AAPL/AVGO/NVDA for Mag7).
dwlf_remove_from_briefing_list1 of 1 parameter describedRemove a symbol from the user's briefing list.
dwlf_list_symbol_tagsno parametersList every distinct symbol TAG. Tags are the groups the markets chart's right-hand panel organises symbols into (e.g. crypto, metals, tech, macro); an untagged symbol falls into the catch-all "Others" bucket. Call this FIRST to see the existing group names before adding a symbol to one (reuse a name to drop it in that group).
dwlf_get_symbol_tags1 of 1 parameter describedGet the tags currently assigned to one symbol — i.e. which chart group(s) it belongs to (empty ⇒ it shows under "Others"). Handy to verify before/after (re)tagging.
dwlf_add_symbol_tag2 of 2 parameters describedTag a symbol so it lands in the right group on the markets chart's right-hand panel instead of "Others". Reuse an existing tag (from dwlf_list_symbol_tags) to add it to that group, or pass a new tag name to create a group. A symbol can carry multiple tags. Example: tag STRC as "crypto", GDX as "metals".
dwlf_remove_symbol_tag2 of 2 parameters describedRemove a tag from a symbol — re-categorise it, or (if it has no other tags) drop it back to the "Others" bucket.
dwlf_describe_strategy_nodes2 of 2 parameters describedDescribe the visual-strategy node types and their (currently-implicit) runtime parameters. Use this to understand what an SL/TP/logic node will actually do at backtest/live time, including the engine defaults that are NOT visible in the visual graph today. Optional `nodeType` filters to a single node (e.g. `sl_below_recent_low`); optional `category` filters to a class (`stopLoss` / `takeProfit` / `signal` / `logic` / `cancellation` / `condition` / `exit`). When `honoredByExecutor: false` on a param, the listed `default` is the only value the engine uses today regardless of what the visual node's data field says — this is what the SL-resolver bug in PR#220 exposed. `honoredByExecutor: null` means not verified (catalogue parameters reach the compiled strategy; their effect on the run is not checked here). Indicator/event condition nodes come from the platform's node catalogue (GET /v2/node-types, cached up to 15 minutes; an unfiltered call lists them by name, ask by nodeType or category "condition" for detail), the same list the strategy builder offers, marked `source: "catalogue"` with `label`, `direction`, `timeframes` (the only ones the node fires on) and `catalogueCategory`. A node with `engineIgnored` is one the engine cannot evaluate: do not use it. `engineIgnores` is the raw rule list ({ id } or { prefix }, with a reason). `catalogueError` means the catalogue could not be read and only the static nodes are listed.
dwlf_list_strategiesno parametersList the user's visual trading strategies with names, descriptions, and associated symbols.
dwlf_get_strategy1 of 1 parameter describedGet full details of a specific strategy including signal definitions, nodes, and edges.
dwlf_create_strategy3 of 3 parameters described⚠️ Create a new strategy. CRITICAL WORKFLOW: 1) Create strategy → 2) Compile → 3) MUST call dwlf_activate_strategy_symbols (or strategy will NEVER generate signals!) → 4) Run backtest. Without step 3, backtests return 0 trades. The strategy exists but is invisible to the evaluation engine until symbols are activated. Always activate symbols immediately after creation.
dwlf_update_strategy4 of 4 parameters describedUpdate an existing visual trading strategy. Provide the strategy ID and updated fields.
dwlf_compile_strategy1 of 1 parameter describedCompile a visual strategy into an executable trade signal. Must be called after creating or updating a strategy before it can be evaluated or generate signals.
dwlf_delete_strategy1 of 1 parameter describedPermanently delete a visual strategy. Hard delete — also removes the compiled executable and symbol activations. ⚠️ Past UserTradeSignal rows that referenced this strategy are NOT scrubbed (they remain as historical record), but they will be filtered out of the chart's strategy dropdown going forward because the chart filters by current live strategies. If you have an active subscription on this strategy, the subscription will keep consuming events but the dispatcher's strategy lookup will fail — disable the subscription first via `dwlf_update_subscription({ enabled: false })` or delete it via `dwlf_delete_subscription` to keep state clean.
dwlf_list_public_strategiesno parametersList community-shared public strategies that can be used as inspiration or cloned.
dwlf_run_backtest12 of 12 parameters described⚠️ Run a strategy backtest (async). Returns requestId → poll with dwlf_get_backtest_results. PREREQUISITES: 1) Strategy MUST have symbols activated (dwlf_activate_strategy_symbols) or backtest returns 0 trades. 2) Requires 200+ daily candles: startDate must be 10+ months before endDate. If backtest returns 0 trades, check: a) Are symbols activated? b) Is date range long enough? c) Do event conditions actually match historical data? Optional capital/risk params (initialCapital, riskPerTrade, maxConcurrentTrades, portfolioMode, allowSymbolPyramiding) override backend defaults — set portfolioMode=true together with maxConcurrentTrades to model shared-capital concurrency across symbols; set allowSymbolPyramiding=true to permit more than one concurrent open position per symbol, and maxPositionsPerSymbol to bound that (e.g. 3) so per-symbol concentration stays capped. Set disableTakeProfit=true for exit-signal-only strategies (no tp node) so the backend does NOT force a fallback take-profit that would exit early.
dwlf_get_backtest_results2 of 2 parameters describedGet results for a backtest by requestId. If status is not "complete", poll again shortly. DEFAULTS TO SUMMARY MODE: returns DDB-level per-symbol stats (totalReturn, totalTrades, winningTrades, sharpe, maxDrawdown, finalEquity) and the portfolio-level aggregate metrics object, with all bulky fields stripped (per-symbol trades, equityCurve, signals, monthlyReturns; request-level portfolioEquityCurve, portfolioTrades, portfolioRejectedSignals). Summary is ~1-3 KB vs ~1-3 MB full — use it for headline metric checks, leaderboard-style comparisons, and "did it work" sanity passes. Pass `summary: false` to get the full payload (per-trade rows, equity curves, signals) — needed for plotting, per-trade analysis, or feeding into another tool. ⚠️ When summary=false, the MCP transport will dump the response to disk and ask you to extract via subagent — budget for that. 📡 For background polling without burning context window: the REST URL is `GET https://api.dwlf.co.uk/v2/backtests/{requestId}/results?summary=true`.
dwlf_list_backtests4 of 4 parameters describedList your backtests (most recent first) with their status and config. DEFAULTS TO SUMMARY MODE: strips the bulky `strategyDefinition` (visual-builder node graph) from each item while keeping all metadata (requestId, strategyId/Name, symbols, timeframe, start/end dates, initialCapital, riskPerTrade, status, createdAt). PAGED: returns the 15 most recent by default plus a `cursor`; even summarised, a large account overflows in one shot. To see more: raise `limit`, pass the returned `cursor` for the next page, or narrow with `status`. Use the summary to pick a requestId, then drill in: dwlf_get_backtest_results for the run's metrics/trades. Pass `summary: false` only if you specifically need each row's full strategy graph (keep `limit` small when you do — full records are ~8 KB each).
dwlf_delete_backtest1 of 1 parameter describedPermanently delete a backtest request and its associated result data by requestId. Use to clean up stale or invalid runs (e.g. results computed before an engine bug was fixed). Idempotent — deleting an already-deleted requestId returns success.
dwlf_cancel_backtest1 of 1 parameter describedCancel a queued or running backtest by requestId. Pending requests cancel cleanly (worker skips). Running requests get a best-effort cancel — result is marked cancelled but mid-run computation isn't interrupted; the response's `bestEffort: true` flag indicates this. Terminal states (completed / failed / already-cancelled) return 409 with the actual status. Use this rather than `dwlf_delete_backtest` when you want to halt without scrubbing the audit trail.
dwlf_get_backtest_summaryno parametersGet a summary of all backtests — aggregated performance stats.
dwlf_list_portfoliosno parametersList the user's portfolios.
dwlf_get_portfolio1 of 1 parameter describedGet portfolio details including holdings.
dwlf_get_holdings1 of 1 parameter describedGet detailed holdings for a portfolio with current values and P&L.
dwlf_get_portfolio_snapshots1 of 1 parameter describedGet historical snapshots for a portfolio — shows value over time.
dwlf_list_trades2 of 2 parameters describedList trades from the trade journal. Filter by status or symbol. Statuses: `open` (live position), `closed` (exited, has P&L), `planned` (confirm-mode signal awaiting confirm/skip), `skipped` (passed signal — carries skipReasons[]/skipNote). Omit `status` to get ALL statuses. Use `status: "skipped"` to review the skip journal (which signals you passed and why).
dwlf_get_trade1 of 1 parameter describedGet full details for a specific trade including notes, executions, and events.
dwlf_create_trade12 of 12 parameters describedLog a new trade in the journal. Specify symbol, direction, entry price, and optional stop loss / take profit. STRONGLY RECOMMENDED: pass confirmReasons[] — WHY the trade is being taken, in the same structured vocabulary dwlf_confirm_trade uses, so a directly-logged trade feeds the byConfirmReason decision analytics exactly like a confirmed planned one. Valid confirmReasons: fresh_cycle_entry, trendline_break_confirmed, cluster_confluence, regime_aligned, risk_reward_attractive, adding_to_winner, other. confirmNote is required when a reason is "other". Reasons are optional (untagged trades still log) but every untagged entry is decision-analytics data lost — and unlike a skip, it cannot be reconstructed later. reasonText is the free-text thesis and does NOT substitute: no rollup can read it.
dwlf_close_trade3 of 3 parameters describedClose an open trade by specifying the exit price.
dwlf_add_trade_note2 of 2 parameters describedAdd a note to an existing trade — observations, adjustments, lessons learned.
dwlf_get_trade_notes1 of 1 parameter describedGet all notes for a trade — observations, updates, and lessons recorded during the trade.
dwlf_list_trade_plansno parametersList trade plan templates — reusable frameworks for entering trades.
dwlf_update_trade13 of 13 parameters describedUpdate an existing trade by ID. All fields except tradeId are optional (partial update). Parameter names match dwlf_create_trade / dwlf_confirm_trade: initialStop / initialTakeProfit / positionSize (formerly stopLoss / takeProfit / quantity — the old names are no longer accepted). symbol and tags are NOT editable — the backend has never accepted them, and offering them meant a caller could set one and be told 200 while nothing changed. To change the levels on an OPEN trade use this; to set them as the trade is taken, pass them to dwlf_confirm_trade instead so it is one call.
dwlf_delete_trade1 of 1 parameter describedDelete a trade by ID.
dwlf_position_size5 of 5 parameters describedCalculate recommended position size based on account size, risk percentage, entry price, and stop loss.
dwlf_get_trade_state1 of 1 parameter describedGet the current state of a trade — including execution history and adjustments.
dwlf_get_skip_outcomesno parametersThe Counterfactual scorecard: what would have happened had each SKIPPED trade been taken. Every skip is replayed against daily candles from its signal date using the decision-time-frozen entry/SL/TP (pre-registered — no hindsight bias). Per outcome: status (`would_be_stopped` capped at exactly -1R / `would_hit_target` / `running` = open mark), `counterfactualR`, `savedR` (= -R: positive means the skip SAVED money), move %, MFE/MAE in R, skip reasons + note. Aggregates: per-skip-reason and per-strategy rollups plus the cumulative saved-R series ("is the discretionary overlay adding edge"). Assumes MECHANICAL execution of the planned levels — no discretionary management; same-bar stop+target counts the stop first (flagged `ambiguousBar`). Pairs with dwlf_list_trades(status:"skipped") and dwlf_skip_trade. UI equivalent: https://www.dwlf.co.uk/trades/counterfactual
dwlf_get_decision_stats2 of 2 parameters describedThe decision-quality ledger: TAKES (confirmed trades, judged by actual outcomes — closed realized R, open marks vs initial risk) and SKIPS (judged by the counterfactual replay) joined into one record. Returns: the 2x2 decision `matrix` (tookRight/tookWrong/skipRight/skipWrong, with open takes and running skips as unjudged open counts), `byStrategy` records (W/L, net realized R, net open R, skips + saved R), and per-reason hit rates for BOTH vocabularies (`byConfirmReason`, `bySkipReason`) — use these to tell the user which of their stated reasons carry alpha (e.g. "your regime_risk_off skips are 3-for-3, +3R saved"). Honesty: only resolved outcomes are judged; paper trades excluded; legacy trades without a genuine numeric R are judged by P&L sign and counted in `rUnknown` (they contribute no R magnitude). UI equivalent: https://www.dwlf.co.uk/trades/decisions. Optional recent-window scope — `months` (last N months) or `fromDate` (YYYY-MM-DD); omit for all-time. A growing skip history dilutes the current-form read, so scope to e.g. months=12 for "recent" decisions. `meta.window` echoes the applied scope.
dwlf_confirm_trade8 of 8 parameters describedConfirm (take) a confirm-mode PLANNED trade — turns it into an OPEN position. Only trades with status "planned" can be confirmed. By default it opens at the planned entryPrice / positionSize / stop and stamps entryAt=now; override any of them to reflect what you actually did. ⚠️ OVERRIDING THE STOP IS THE COMMON CASE, not an exception: the engine derives its stop from regular-session candles, so it routinely sits inside the broker's wider range and has to be moved before the take. Overriding initialStop does NOT re-derive positionSize — pass both to keep risk constant. STRONGLY RECOMMENDED: pass confirmReasons[] — WHY the trade is being taken (the symmetric twin of skip reasons; feeds the Counterfactual scorecard / 2x2 decision analytics). Valid confirmReasons: fresh_cycle_entry, trendline_break_confirmed, cluster_confluence, regime_aligned, risk_reward_attractive, adding_to_winner, other. confirmNote is required when a reason is "other". Reasons are optional (untagged confirms still work) but every untagged confirm is decision-analytics data lost. Pair with dwlf_skip_trade to pass instead. Find planned trades via dwlf_list_trades(status: "planned").
dwlf_skip_trade3 of 3 parameters describedSkip (pass on) a confirm-mode PLANNED trade, recording WHY. Moves it to status "skipped" with skipReasons[] + an optional skipNote — this feeds the skip journal / scorecard (dwlf_list_trades(status: "skipped")). Only planned trades can be skipped. Valid skipReasons: entry_extended_from_anchor, risk_reward_poor, thesis_already_played_out, low_conviction_signal, regime_risk_off, correlated_exposure, account_drawdown_pause, broker_access, other. skipNote is REQUIRED when a reason is "other". The first reason is treated as primary. Pair with dwlf_confirm_trade to take it instead.
dwlf_list_custom_eventsno parametersList the account's custom events: conditions the user defined (indicator and event condition nodes joined by and/or/not/then gates), each with its id and name. An event's definition is dwlf_get_custom_event; its fires are dwlf_get_events with type `custom_event` and its `customEventId` (pass a wide `days`); the symbols it runs on, and whether it is really running, are dwlf_get_event_symbols.
dwlf_get_custom_event_notifications1 of 1 parameter describedGet all recently fired custom events where the user has notifications enabled. Returns fires across ALL symbols in one call — the most efficient way to check what custom events have triggered. The eventName field contains the human-readable name (e.g. "wcl_confirmed"). The eventType field is always "custom_event" — use eventName to distinguish events.
dwlf_get_custom_event1 of 1 parameter describedGet one custom event: its name, its condition graph (`visual`: nodes and edges), its settings and its compiled status. Its fires are not here: read them with dwlf_get_events (type `custom_event`, `customEventId` = this id, a wide `days`). Which symbols it runs on, and its last-night health, are dwlf_get_event_symbols.
dwlf_compile_custom_event1 of 1 parameter describedRecompile a LEGACY custom event. Saving already compiles: dwlf_create_custom_event, and every dwlf_update_custom_event that changes the definition, compile in the same request and refuse (400) a graph that will not compile, so this is needed only when activating symbols answers 422 `EVENT_NOT_COMPILED` (an older event never compiled, or one whose saved definition is not what would run). A 409 means the event changed while it compiled: reload it and retry.
dwlf_preflight_custom_event1 of 1 parameter describedValidate a custom event graph WITHOUT saving it. Returns execution tier (fast/async/reject), complexity score with breakdown, graph metrics, plan policy limits, errors, warnings, and suggested fixes. Call this BEFORE creating or updating a complex event to check whether it will be accepted and which execution tier it will land in.
dwlf_create_custom_event2 of 2 parameters described⚠️ Create a new custom event. CRITICAL WORKFLOW: 1) Create event (saving compiles it; a graph that will not compile is refused with 400) → 2) MUST call dwlf_activate_event_symbols (or event will NEVER fire!) → 3) Trigger evaluation. Without step 2, backtests return 0 trades. The event exists but is invisible to the evaluation engine until symbols are activated. Always activate symbols immediately after creation.
dwlf_update_custom_event2 of 2 parameters describedUpdate an existing custom event. Accepts any subset of {name, description, visual, metadata, version, notifyOnFire} via bodyJson. Most common use: flip notifyOnFire to true after creation so future fires surface in dwlf_get_custom_event_notifications. A change to `visual` or a condition compiles in the same request (a graph that will not compile is refused with 400): no separate compile call is needed.
dwlf_delete_custom_event1 of 1 parameter describedDelete a custom event permanently. Hard delete — also removes the compiled executable, symbol activations, and watermark state. Past fires already written to EventsTable are NOT deleted (they remain as historical record).
dwlf_evaluate_custom_event3 of 3 parameters described⚠️ Trigger an on-demand evaluation run for a specific custom event. This is the workflow step BETWEEN activating symbols and querying fires — without it, the custom event only evaluates on the daily cron and historical data is not backfilled until then. Returns { requestId, status: "pending" } — poll dwlf_get_evaluation_status(requestId) until status is "completed", then query fires via dwlf_get_events(type: "custom_event"). Consumes one EVALUATION quota. IMPORTANT: by default only the most recent ~400 candles (~14 months of daily data) are backfilled; older history produces NO fires and any backtest spanning it silently sees zero entries before that window. To backfill the full history a backtest needs, pass lookbackDays covering the whole backtest range (e.g. 2200 for a ~5-6yr window).
dwlf_evaluate_strategy3 of 3 parameters describedTrigger an on-demand evaluation run for a specific visual strategy. Parallels dwlf_evaluate_custom_event but for strategies. Returns { requestId, status: "pending" } — poll dwlf_get_evaluation_status until completed. Consumes one EVALUATION quota. Same backfill caveat as dwlf_evaluate_custom_event: defaults to ~400 candles (~14 months); pass lookbackDays to cover a longer history. ⚠️ IMPORTANT — this DOES NOT emit `strategy.entry.triggered` events to the dispatcher. Those events are only emitted by the daily cron (`dailyTradeSignalJob`, ~04:00 UTC) when entry conditions match on the *latest bar*. On-demand evaluation populates the signal/event tables for analytical queries (`dwlf_get_recent_signals`, `dwlf_get_events`) but will NOT trigger Telegrams or planned-Trade rows even if it finds matches on historical bars. To get a fresh Telegram fire on a historical signal you need a manual replay through the dispatcher, not this tool. Got bitten by this twice while debugging WULF on 2026-05-27 — documenting so future-me does not re-discover.
dwlf_get_evaluation_status1 of 1 parameter describedGet the status and result summary of a specific evaluation by requestId. Poll this after calling dwlf_evaluate_custom_event or dwlf_evaluate_strategy until status === "completed". ⚠️ IMPORTANT — `summary.totalItems` / `summary.processedItems` count the eval-JOB items (one per strategy or one per custom event), NOT the per-symbol fan-out inside the job. A strategy eval across 37 symbols will show `totalItems: 1, processedItems: 1` when done — that just means "the strategy job finished," NOT "37 symbols were processed." For the per-symbol count: the request body itself carries `symbols: [...]` (or empty = all activated). When the symbols array is present this tool surfaces `symbolsRequested: <count>` next to summary so you can see both numbers; otherwise inspect the request shape directly. When status is "completed", query the fires it produced via dwlf_get_events(type: "custom_event") or dwlf_get_recent_signals (for strategies) — if you see fewer fires than expected across many symbols, that confirms the eval reached all of them (worker would not have written status=completed without finishing the loop).
dwlf_list_evaluations2 of 2 parameters describedList recent evaluation requests for the account with their status and summary. Useful for finding the requestId of a previous evaluation, or for checking whether one is already in-flight before triggering another.
dwlf_list_annotations2 of 2 parameters describedList annotations for a symbol. Optionally filter by timeframe (e.g. daily, weekly, hourly). Returns each annotation with its annotationId, type, timeframe and full data — copy a data shape from here when you are unsure how to build a new one.
dwlf_create_annotation5 of 5 parameters describedCreate a chart annotation. `type` selects the shape; `data` carries the type-specific fields documented below. Note `arrow` is the callout/bubble-with-pointer and `text` is a plain text box — for commentary that points at a level, use `arrow`. DATA SHAPES BY TYPE (times = unix-ms, prices = chart price): • hline — {price, color, lineStyle, lineWidth, showPrice, label?}: horizontal price level. • vline — {time, color, lineStyle, lineWidth, showTime, label?}: vertical time marker. • text — {time, price, text, fontSize, color, backgroundColor?}: free text box anchored at a point. Use \n inside `text` for multi-line — long single-line text renders too wide to read, so break it up. • arrow — {time1, price1, time2, price2, text, fontSize, color, lineStyle, lineWidth}: callout/speech-bubble. The text box sits at (time1,price1); the arrowhead points to (time2,price2). Use this to label a level or zone with a pointer. • trendline — {time1, price1, time2, price2, color, lineStyle, lineWidth, label?, extendLeft?, extendRight?}: line through two points. • ray — {time1, price1, time2, price2, color, lineStyle, lineWidth, label?}: half-line from point 1 through point 2. • rectangle — {time1, price1, time2, price2, color, fillOpacity, lineStyle, lineWidth, label?}: shaded zone between two opposite corners. • channel — {time1, price1, time2, price2, priceOffset, color, lineStyle, lineWidth, fillOpacity, label?, extendLeft?, extendRight?}: parallel channel; the second rail runs priceOffset above (+) / below (−) the base line. • crossline — {time, price, color, lineStyle, lineWidth, showPrice, showTime, label?}: crosshair marker at one point. • emoji — {time, price, emoji, size}: emoji marker (e.g. emoji "🦊"). • timerange — {time1, time2, color, fillOpacity, lineStyle, lineWidth, label?}: vertical time band. • fibRetracement / measure — {time1, price1, time2, price2, levels:number[], showExtensions, extendRight, color, lineStyle, lineWidth, fillOpacity, label?}: fib/measure between two swing points. • fib_extension — {time1, price1, time2, price2, color, lineStyle, lineWidth, label?}: extension projection. • alert_line — {price, color, lineStyle, lineWidth, showPrice, direction:"above"|"below", label?}: a DRAWING of a price-alert line. Creating one here does NOT arm a price alert: nothing will fire, and the web chart shows it as "Alert not armed" until the user arms it there. Deleting an armed line disarms its alert. • long_position / short_position — {time1, time2, entryPrice, stopPrice, targetPrice, label?}: renders an entry line, stop+target zones and a live R:R badge. ALIASES (same storage — prefer the first of each pair): text over note; emoji over icon; alert_line over price_alert; fibRetracement over fib_retracement. TIP: copy an existing shape via dwlf_list_annotations if unsure.
dwlf_update_annotation8 of 8 parameters describedUpdate an existing annotation. symbol + timeframe are REQUIRED (the backend needs them to locate the row). `data` is merged field-by-field into the existing data — pass only the fields you want to change (e.g. {label: "..."} or {price: 56}); sibling fields are preserved. visible/locked/zIndex/groupId can also be patched.
dwlf_delete_annotation3 of 3 parameters describedDelete an annotation by ID. symbol + timeframe are required (the backend needs them to locate the row). Deleting an armed alert_line also cancels its live price alert.
dwlf_bulk_create_annotations1 of 1 parameter describedCreate multiple annotations in one call (max 25). Each entry follows the same shape as dwlf_create_annotation — see its data-shape reference. Returns a per-item results array; an individual item can fail without aborting the rest.
dwlf_get_trade_plan1 of 1 parameter describedGet full details for a specific trade plan by ID.
dwlf_create_trade_plan9 of 9 parameters describedCreate a new trade plan with entry, stop loss, and take profit levels.
dwlf_update_trade_plan11 of 11 parameters describedUpdate an existing trade plan by ID. All fields except planId are optional (partial update).
dwlf_delete_trade_plan1 of 1 parameter describedDelete a trade plan by ID.
dwlf_activate_event_symbols2 of 2 parameters described⚠️ REQUIRED STEP after creating custom events! Activate (enable) symbols for an event. Events do NOT evaluate automatically — they are invisible to backtests and the daily pipeline until activated. If backtests return 0 trades, you likely forgot this step. Call immediately after creating an event (saving compiles it).
dwlf_get_event_symbols1 of 1 parameter describedGet the symbols a custom event is activated on, plus the event's `health` line from last night's coverage check: { active, ok, failing, paused, pending, lastCheckedAt, judgedAt, lastFired: { symbol, at }, compileState }. Use it to check an event is really running, not just activated. Each activation's state is ok | failing (with a kind, e.g. stale_market_data, not_compiled, evaluation_failed) | paused | pending; kinds are an open set, so branch on the state.
dwlf_deactivate_event_symbols2 of 2 parameters describedDeactivate (disable) one or more symbols for a custom event: it stops evaluating, and so stops recording fires, for those symbols. An alert subscription that names those symbols is separate and is not changed: edit it with dwlf_update_subscription.
dwlf_activate_strategy_symbols2 of 2 parameters described⚠️ REQUIRED STEP after creating strategies! Activate symbols for a strategy. Strategies do NOT generate signals automatically — they are invisible to backtests until symbols are activated. If backtests return 0 trades, you likely forgot this step. Call immediately after compiling a strategy.
dwlf_get_strategy_symbols1 of 1 parameter describedGet the list of symbols currently activated for a strategy.
dwlf_deactivate_strategy_symbols2 of 2 parameters describedDeactivate (disable) one or more symbols for a strategy. The strategy will stop generating signals for these symbols.
dwlf_list_all_symbol_activations1 of 1 parameter describedList all the user's symbol activations across both custom events and strategies. Shows which symbols are active for which events/strategies.
dwlf_ai_dashboardno parametersGet a complete account overview in a single call: watchlist with prices, active signals, open trades, portfolios, strategies, and recent events. Ideal for "what's going on?" queries. Requires markets:read permission; other sections degrade gracefully based on permissions.
dwlf_ai_symbol_brief1 of 1 parameter describedGet a condensed single-symbol view: latest price with change, recent candles, key indicators, S/R levels, recent events, and active signals. Perfect for "how's BTC doing?" queries.
dwlf_ai_strategy_performanceno parametersGet all strategies with signal stats and performance metrics in a single call: total signals, active signals, win rate, avg R/R, total P&L, and per-strategy breakdowns.
dwlf_list_academy_tracksno parametersList all DWLF Academy tracks and lessons. Use this to discover educational content about DWLF concepts — indicators, events, strategies, charting, and more.
dwlf_get_academy_lesson1 of 1 parameter describedGet the full content of a DWLF Academy lesson by slug. Returns markdown. Use dwlf_list_academy_tracks first to find available lessons.
dwlf_search_academy1 of 1 parameter describedSearch DWLF Academy content by keyword. Searches track and lesson titles. Returns matching lessons with their track context.
dwlf_get_regime4 of 4 parameters describedGet the market regime classification for a symbol on one timeframe (daily by default) — trend, momentum, volatility and a confidence score, plus `insufficientHistory` (true when the symbol has too little history on that timeframe: the fields are then placeholders, not a reading). With `history`, returns a dated regime series, newest first. It carries no cycle phase: for where an asset is in its market cycle, use dwlf_get_stage (weekly Weinstein stage).
dwlf_get_intelligence1 of 1 parameter describedGet the full semantic snapshot for a symbol — current price, active events, FSM state, market regime, the weekly Weinstein `stage` object (`stage`, `stageName`, `weeksInStage`, `since`, `verification`; context, not a signal — see dwlf_get_stage), support/resistance levels, signal quality, and the swing ladders, both in the same call: `structure` (daily) and `structureWeekly` (weekly), each with bias, sequence, flipLevel, trapdoor and recent pivots. Each pivot has a `status`: "active"; "superseded" (the cycle engine replaced it in TIMING with a more extreme pivot, named in `supersededBy`, but it still counts as a level in STRUCTURE; `supersededKept` lists these); or null when that ladder's `supersessionTracked` is false, which means unknown, NOT active. `finalAfter` is null today (finality is not computed yet); while it is null, don't call a pivot final. `structureIncomplete: true` means the ladder may be missing pivots. Read `agentHints.structure` for how to word these. This is the preferred single-call way to get structured market context for a symbol. For BITCOIN's on-chain cost basis, cycle windows and positioning in one call, use dwlf_get_conditions first.
dwlf_get_daily_briefing3 of 3 parameters describedGet the cross-asset daily briefing (covers the watchlist UNION the briefing list). Returns a TOP-LEVEL OVERVIEW by default: one headline line per symbol (price/%chg/ribbon, regime trend + `cycle`, the weekly cycle FSM's setup state (bottoming/rising/topping/declining; not the cycle read — that is `stage`), weekly Weinstein `stage` number + `stageWeeks` (weeks in stage; context, not a signal), cycleAlignment composite, active-signal count, openTrade, and `flags`) plus the full cross-asset block (sectorSentiment + triggerThemes + alignmentThemes) and a `drilldown` block. The overview is sized to stay within a single response across a large watchlist + briefing list — START HERE for the universe-wide read, then drill into symbols that matter. Three tiers: view:"overview" (default, one-glance) → view:"summary" (compact per-symbol: nearest S/R, trendline state, truncated events, SMC digest) → view:"full" (every field — pivots, trendline touch-points, fibLevels, annotations). summary/full across the whole watchlist can exceed response limits, so SCOPE them with `symbols`. `drilldown.flaggedSymbols` and per-symbol `flags` mark notable structure — drill those proactively (view:"summary"/"full" scoped, or dwlf_get_price_picture / dwlf_get_trendlines / dwlf_get_support_resistance / dwlf_get_events). Use `symbols` to extend coverage beyond your watchlist + briefing list. Pass depth:true for crossAsset.depth: each symbol's weekly cycle window depth band (where the last close sits in the move past cycles made; lead with in-zone).
dwlf_register_agent3 of 3 parameters describedProgrammatically register a new DWLF account — no browser or Google OAuth required. Returns an API key immediately. Email verification unlocks compute features (backtests, evaluations). Useful for onboarding flows where an agent registers itself.
dwlf_get_quotasno parametersGet the current user's plan tier, resource usage (custom events, strategies, FSMs, on-demand evals), limits, and custom event policy limits including fast/async path constraints (max nodes, max OR fanout, max nesting depth, etc.). Use this to understand what the user's plan allows before building complex events.
dwlf_list_subscriptionsno parametersList all subscriptions on the account, including their enabled state, event source, channels, and filters. Use to verify what's wired up before creating duplicates, or to find a subscriptionId for update/delete.
dwlf_create_subscription8 of 13 parameters describedCreate a new subscription. Four shapes are supported, distinguished by `eventTypeId`: - `strategy.entry.triggered` — requires `strategyId`; pair with `mode: 'confirm'` or `'auto'`. Confirm-mode creates a planned Trade for review; auto-mode opens it directly. - `strategy.exit.triggered` — requires `strategyId`. Fires when the strategy's exit graph matches, and also delivers that strategy's stop alerts: every live stop-out (fixed or trailing) and a trailing stop locking in breakeven, then each further whole R. `strategy.stop.hit` / `strategy.stop.moved` cannot be subscribed to directly. - `custom_event` — requires `customEventId`. Fires when that custom event fires. - any indicator event id (e.g. `cycle.low.confirmed`, `cycle.high.window.early`, `swing_low_break`). Fires on the raw indicator event. `symbols` controls scope: an array of symbols, or `['*']` for a wildcard across the whole account universe. `timeframes` accepts `['1d']`, `['1w']`, or `['*']` for any. `channels` is an array of delivery destinations — currently `{ type: 'telegram', destination: { chatId: <id> }, enabled: true }`.
dwlf_update_subscription8 of 13 parameters describedUpdate an existing subscription (PATCH). Only the fields you supply are changed; everything else is preserved. Most-used: toggle `enabled` to pause/resume without losing the subscription's history. Editable fields: enabled, symbols, timeframes, channels, quietHours, dedupeWindowMinutes, mode, strategyId, risk/accountBalance/maxConcurrentTrades overrides, and customEventId (custom_event subscriptions only). `eventTypeId` is NOT patchable — switching event class on an existing subscription requires delete+recreate.
dwlf_delete_subscription1 of 1 parameter describedPermanently delete a subscription. Hard delete — also removes any pending dispatcher state. If you just want to pause it, use `dwlf_update_subscription` with `enabled: false` instead so the history is preserved.
dwlf_list_thesis_condition_typesno parametersThe vocabulary of thesis alerts ("Waiting for"): each condition type with its parameters and a definition, the rules (ordered steps, invalidation, arming, nightly checking) and the limits. Read this before dwlf_create_thesis. Condition types: pivot_confirmed (the next confirmed cycle low/high, optionally inside a level), close_vs_level (a daily/weekly close or intraday trade beyond a level), window_opens, trendline_break, engine_event (a short allow-list), manual. Full parameters and definitions: dwlf_list_thesis_condition_types.
dwlf_create_thesis10 of 10 parameters describedSave what the user is waiting for on a symbol, and why ("Waiting for", DWLF-855): ordered steps of conditions, optional invalidation conditions, and the user's own context. DWLF checks it once a night after the close and sends one Telegram digest per run when something happens; nothing known before a condition was saved counts. Use dryRun: true first: it restates every condition in plain words (`checks`) and checks each can occur, writing nothing. Show the restatement to the user before saving. Refusals: 422 CANNOT_OCCUR (a condition can never happen for its symbol), 422 ALREADY_MET (a step condition is already true now; set allowAlreadyMet to save anyway). The refusal's checks are returned. clientKey makes the call an upsert (re-sending an identical thesis writes nothing; a changed one writes a new revision). Condition types: pivot_confirmed (the next confirmed cycle low/high, optionally inside a level), close_vs_level (a daily/weekly close or intraday trade beyond a level), window_opens, trendline_break, engine_event (a short allow-list), manual. Full parameters and definitions: dwlf_list_thesis_condition_types.
dwlf_list_theses3 of 3 parameters describedThe user's theses ("Waiting for"): each with its steps and conditions (pending, met, missed or marked), status (waiting, in_progress, complete, challenged, archived, closed) and liveness (the bar it was last checked against; `stale` when the nightly check has been quiet over 30 hours). A challenged thesis is waiting for the user's review. Closes are withheld for keys not entitled to raw prices; the % change is not.
dwlf_get_thesis1 of 1 parameter describedOne thesis in full: every condition with its state, the revisions (earlier ones are kept), its fires (what happened, when DWLF could know it) and liveness. Read `currentRevision` here before dwlf_revise_thesis or a review that revises.
dwlf_revise_thesis7 of 8 parameters describedChange a thesis: writes a new revision and keeps the earlier ones. Send expectedRevision (the currentRevision you read; 409 REVISION_CONFLICT if it moved) and only the fields to change. steps/invalidation, when sent, replace the whole list: keep each unchanged condition's id so it keeps its arming and result. A changed or new condition is armed from now (nothing before counts). Same refusals as create (422 CANNOT_OCCUR / ALREADY_MET). Condition types: pivot_confirmed (the next confirmed cycle low/high, optionally inside a level), close_vs_level (a daily/weekly close or intraday trade beyond a level), window_opens, trendline_break, engine_event (a short allow-list), manual. Full parameters and definitions: dwlf_list_thesis_condition_types.
dwlf_review_thesis9 of 10 parameters describedRecord the user's answer to a thesis (usually a challenged one): keep (unchanged; clears the challenge), revise (a new revision: send expectedRevision and the fields to change, as dwlf_revise_thesis) or close (ends it, with an outcome). Record the user's own answer; do not choose it for them.
dwlf_mark_thesis_condition_met2 of 3 parameters describedMark one of a thesis's MANUAL conditions met (once), with an optional note: something only the user can judge (e.g. "the news I was waiting for came out"). The nightly check records it on its next run. Only manual conditions can be marked (400 NOT_A_MANUAL_CONDITION); a second mark is 409 ALREADY_MARKED.
dwlf_archive_thesis1 of 1 parameter describedArchive a thesis: it is kept, with its revisions and fires, in the journal and is no longer checked. To end it with an outcome instead, use dwlf_review_thesis with answer close.
dwlf_delete_thesis1 of 1 parameter describedPermanently delete a thesis with its revisions and fires. This cannot be undone; dwlf_archive_thesis keeps the record instead. Confirm with the user first.
dwlf_list_thesis_fires2 of 2 parameters describedThe feed of thesis fires, oldest first: each time a step was met, a condition was missed, an invalidation was hit or a deciding event was withdrawn, across all the user's theses. Pass back the returned `cursor` next time to read only new fires (each fire is read once). The cursor is yours to keep (this server stores nothing): with none, the feed pages from the oldest fire, and the ones the user has not seen are the loud fires with `acknowledgedAt` null. `knowableAt` is when DWLF could first know it; `session` the bar. Closes are withheld for keys not entitled to raw prices. After telling the user, acknowledge with dwlf_ack_thesis_fires.
dwlf_ack_thesis_fires0 of 1 parameter describedAcknowledge fires the user has seen (up to 100 per call), so the app stops showing them as new. Pass { thesisId, fireId } pairs from dwlf_list_thesis_fires or dwlf_get_thesis.
dwlf_describe_onchain_events3 of 3 parameters describedWhat does a Bitcoin on-chain event mean? Describes the `onchain.*` event types: the plain-English condition, the inputs and threshold, the history start, how often it has fired, the method version and the caveats. Packs: `engine` (the types DWLF's engine evaluates: cost-basis crosses, MVRV, supply in profit, STH-SOPR, cohorts, dormancy, CDD, whale transfers) and the onchain-packs (`quantum`, `mining`, `fees`, `dca`, `regime`, `blockspace`). No arguments → the packs with their summaries. `pack` → that pack's types. `eventType` → one type: `event` (its summary line) and `definition` (the full definition: inputs, threshold, caveats, history; `detailUnavailable` says why when it could not be read). `search` → types whose id or meaning contains the words. For one type's occurrences, use dwlf_explain_event. ⚠️ Read before you report: - `definitionSource`: `api` = read live from DWLF; `bundled` = this package's offline copy (dated `asOf`), used only when the API could not be read (`apiError` says why). Say which when it matters. - `inEngine` (per TYPE; a pack is `true` if ANY of its types is): `true` = the engine evaluates it and its rows can be read with dwlf_get_events, dwlf_get_conditions or dwlf_explain_event; `false` = a documented condition with its history measured on DWLF's own node, not yet queryable; `null` = unknown. Before building a custom event on a type, check that type's own `inEngine`. - Every type describes a CONDITION on the chain, not advice. `estimated: true` marks types built on an attribution or a proxy: read their caveats. `confirmedAt` on a row is when it became knowable. Frequencies are historical counts, not predictions.
dwlf_explain_event3 of 3 parameters describedExplain one Bitcoin on-chain event type (`onchain.*`) and, for the types the engine evaluates, its occurrences. Returns the DEFINITION: meaning, method and version, inputs, threshold, history start, caveats, `revision` (can this event's history change under you, and why: immutable / oracle / model / estimated), `measuredHistory` (how often it fired on DWLF's node, by year, dated) and `inEngine`. With `inEngine: true` it also returns OCCURRENCES: `date` = that day's occurrence (or the nearest days either side); `since` = what changed, as three disjoint buckets placed by the day a row became knowable (`onchain.confirmedAt`; an on-chain row dated D is confirmed on D+1): `fired` (knowable on or after `since`), `published` (knowable before `since` but first served on or after it, e.g. a backfill: new to you, NOT a firing) and `revised` (served before `since`, restated on or after it). Each bucket is { count, firstDated, lastDated, rows (the newest), truncated }: quote `count`, not the rows listed. Neither = the 5 most recent. A `date` with nothing on it gives `occurrence: null` and the nearest days. Every occurrence answer carries `history` { count, first, last, methodVersions } from the live table. Use dwlf_describe_onchain_events to browse or search the types. ⚠️ Read before you report: - These are CONDITIONS on the chain, not calls. Describe them; never turn one into a buy/sell/hold. - `definitionSource: "bundled"` means this API does not serve explain yet and the definition is this package's copy, dated by `bundledAsOf`: say so. A bundled definition has no `revision` or `measuredHistory` (null = UNKNOWN, not "cannot change") and no occurrences. - `occurrencesUnavailable` says why there are none (not in the engine, or the read failed). Never infer "it has not fired" from it. - `priceWithheld: true` on a row means this key may not receive the close (data licensing): do not ask for it another way. - `revised` rows changed after they were first served: quote the revision, and `revision.why`. - `published` rows are history DWLF served late (a backfill): never report them as recent firings. - A row with `locked: true` is of a family the plan does not read (DWLF Block): `{ eventType, date, …, locked: true, lockedFamily, requiredPlan, pricingUrl }` (what fired and when; no price, levels, values or meaning). `requiredPlan` unlocks the detail. Counts and dates outside the rows are real. - Check `occurrences.responseVersion`. 2 or 3 = the bucket shape above (3: rows may be locked). MISSING = an older DWLF API, where `fired` and `revised` are plain arrays and `fired` mixes real firings with late-published history (a backfill): then report as firings only the `fired` rows whose `onchain.confirmedAt` (else `date`) is on or after `since`, the same rule as version 2, and say that the API is older.
Tested in a sandbox with an empty environment: no API keys, a throwaway folder, nothing from a real account. A passing test shows the server runs and responds. It is not a security audit.