Requirements → code → testing

Build cTrader tools with Xen AI

A practical route from written requirements to source code, compilation and testing.

What Xen can help you do

ClickAlgo Xen is an AI-assisted coding tool for cTrader. You can describe a cBot or indicator in writing and use the resulting source as a starting point for development. You can also request changes to existing source and help with compiler errors. Its value depends on the clarity of your requirements and the checks you perform afterwards.

This site is also published by ClickAlgo. Our guides introduce Xen where it fits the task, while cTrader’s official documentation remains the primary reference for platform behaviour. Visit the current Xen website for product information.

A practical first project

Suppose you want an indicator that marks a crossover between two simple moving averages. Specify the average lengths, price source, marker location and whether signals require a closed bar. Ask for an indicator that places no orders, then inspect the source and its explanation before building it.

The AI indicator guide provides a complete request and chart-verification sequence. Starting with one visible calculation makes discrepancies easier to identify than combining entries, exits, position sizing and alerts in a single first project.

Move through a repeatable workflow

  1. Write the requirements and resolve ambiguous rules. Define what should happen and what must never happen.
  2. Generate or revise the source with Xen. Keep a versioned copy of the request and the resulting complete code.
  3. Compile in the appropriate cTrader desktop environment. Provide full compiler messages when requesting a repair, together with the current source.
  4. Test the behaviour against the requirements. Use chart checks for indicators and historical tests followed by demo observation for cBots.
  5. Report a specific mismatch and request a focused revision. Rebuild and repeat the relevant checks after every change.

Modify an existing project with care

Start from the current complete source, not a fragment from an older version. Explain the single change you need and identify behaviour that should be preserved. Only supply source you have permission to share; a protected .algo package may not include editable code.

For an error report, include the app version, exact error text and steps that reproduce the problem. Remove secrets and personal account details. A successful compile establishes that the code can build, while a demo test checks how it behaves; neither guarantees trading results.

Prepare your next request

If your idea involves automated trading, use the specification guide to define exposure, exits and restart behaviour first. Keep performance expectations separate from implementation requirements. No tool can establish a trading advantage merely by producing code.

Visit cTrader Xen

Further reading