Overview

Using CQG Custom Algo SDK, our customers can create their own, new order types ("Algos"). The new functionality is implemented in C++, producing a shared library that is loaded at run time by our CQG Algo Server.

Speed

CQG's Custom Algo SDK platform offers a sub-10 microsecond socket to socket response times for algorithmic trading thus allowing you to create the new order types in high-performance C++ and load them into CQG Algo Server.

Since your order is running inside CQG Algo Server, there is virtually no overhead allowing your algorithm to take full advantage of the speed CQG Algo Server offers. Hosting a high-performance language like C++ directly in CQG Algo Server process allows it to respond to the market thousands of times faster than an Algo built using a proprietary drag and drop tool.

Easy to Get Started

Setting up a complete development environment from scratch, if you are not actively developing with C++, can be time-consuming. To help you get it up and running quickly, we offer a full development environment out of the box with Docker.

Docker works across Windows, macOS, and Linux and everything you need is packaged together in one image.

Implementation

Creating a new algo begins with implementing a standard C++ class derived from IAlgoOrder. Start with the algo_template example to get going.

The first call your new Algo receives is do_before_launch, which is an opportunity to validate parameters and allocate any long-lived resources required for execution. Next, the algo receives either do_launch in the case of a new order or do_launch_attached if the order is being attached to an existing order.

After that, your algo receives a reference to IAlgoServices, which is how it calls out to CQG Algo system. It will use IAlgoServices to subscribe to market events, launch and control child orders, and communicate its state to the larger CQG Algo system.

Fully Integrated

When a CQG Algo Server plugin is loaded, it registers its exposed Algos with CQG Algo Server through the init_spark_plugin callback. This callback allows the algo to describe the parameters it expects so they can be automatically entered in the Algo API test client and the CQG Algo API.

Note:

*Algo API test client is a windows GUI tool user for testing and debugging purposes only and should not be used in production, other than to check and verify API trades. Please contact API Help to download the GUI.

**You will see "spark" references in some of the instructions and examples in these help files. This is the name used for CQG Algo Server internally.

  Next