> Bot files require payment verified by VCM customer care. Sign in and request access at https://vertexcapitalmarketsgroup.com/bot-access. Download the approved file there after activation. Public source archives and free packs are no longer offered. Agree the exact release and licence before payment.

# VCM Trend Guard v1 — research release

This is an experimental cTrader cBot, separate from VCM's paid package proposals.
It refuses live accounts. No broker account is connected to the VCM website.
There is no measured profitability, accuracy or return target for this release.

## Exact strategy

- H1 bars only. Start evaluation on EUR/USD; other instruments are unvalidated.
- On a closed bar, buy when its close exceeds the highs of the previous 20 bars,
  closes above the 200 EMA, and that EMA is rising. Sell on the inverse conditions.
- The current signal bar is excluded from the breakout window. No future bars are used.
- Entries Monday–Friday, 07:00 through 17:59 UTC. No integrated news filter.
- Stop distance: 2 × 14-period exponential ATR, constrained to 5–100 pips.
  Take profit: twice the stop distance. No martingale, grid, averaging down or trailing stop.
- Default nominal risk: 0.25% of equity. Volume rounded down, capped at 0.1 lots.
  Skip if below the broker minimum or estimated margin exceeds 20% of free margin.
- Maximum spread 1.5 pips. At most three submission attempts per UTC day.
- No entry while ANY position or pending order exists on the account.
- 2% equity loss from the daily baseline pauses entries and requests closure of this
  bot's positions. 8% loss from the saved equity peak latches a permanent halt.
  Failed exits are retried on ticks/timer while the instance is running.
- Rejected orders and missing protection latch a halt. Review logs; do not blindly restart.

## Setup without copying code

1. Download the compiled `.algo` from /bot-lab when available, then open it in cTrader.
2. Use a DEDICATED broker demo with no other bot instances, positions or pending orders.
3. Add one instance on EUR/USD H1. Leave Enable demo entries off initially.
4. Run cTrader historical tests with realistic spreads, commissions and broker data.
5. Inspect losing periods, costs, order logs and out-of-sample periods.
6. Only after reviewing results, enable entries on that demo instance to forward-test.
   The operator must start the bot in cTrader; downloading it does not place orders.

## Persistence and limits

Risk state is stored in cTrader Instance local storage, keyed to account and symbol.
It survives restarting the SAME instance with its storage intact. It is not a shared
account-wide risk service. New instances, storage deletion, machine migration or
changing symbols can reset baselines. Do not use these to bypass a halt.
Daily baseline begins at first observation after UTC midnight, not guaranteed midnight equity.
Deposits/withdrawals and other account activity distort equity-based limits.
Limits cannot guarantee a maximum loss: gaps, slippage, disconnected/stopped software,
broker rejection and execution delays can exceed the thresholds. Stops can slip.
Manually stopping the bot does not automatically close positions; broker-side stops
and targets remain. Close remaining demo positions manually if you want no exposure.
No account credentials, telemetry or withdrawal permissions are requested.

## Evidence needed before commercial release

Compilation and rule tests do not establish profitability. Obtain broker-specific
historical tests, untouched out-of-sample results and forward-demo reports. Include
all trades, fees, spread/slippage assumptions, deposits, withdrawals, drawdowns and
errors. Do not publish a win rate or earnings claim until measured and reproducible.
MT5, exchange APIs and website-controlled execution require separate implementations.

## Developer build

`dotnet build VCMTrendGuard/VCMTrendGuard.csproj -c Release`

`dotnet run --project Tests/Tests.csproj -c Release`

Official API sources:
- https://help.ctrader.com/ctrader-algo/visual-studio-ides/
- https://help.ctrader.com/ctrader-algo/documentation/cbots/cbot-bar-events/
- https://help.ctrader.com/ctrader-algo/guides/local-storage/
