Broker Independence

Write your strategy once and run it across brokers using one common interface.

Core conceptNo code changeMulti-broker
In short

Broker independence means your trading system talks to one common interface instead of a single broker's API. With AutoTrader, you can switch brokers or add more trading accounts by changing a setting, without rewriting or retesting your strategy code.

This chapter describes some of the building blocks of AutoTrader’s design. We strongly recommend reading it, but those in a hurry can skip it.

What is broker independence?

In software, it is good practice to build loosely coupled components. This keeps the software flexible and easy to adapt when things change.

A broker independent trading system follows the same idea. Instead of depending on one broker’s API, it uses a common interface that works the same way across brokers.

Let us understand this with an example.

Tightly coupled trading system

A trader decides to automate his strategy using the API provided by stock broker ABC. All of his strategy code now uses functions that are specific to ABC. This creates problems in two common situations.

Scenario 1: Not happy with stock broker ABC

Later the trader decides to change his broker. This is a realistic scenario. He may be unhappy with:

  • New brokerage rates
  • Customer support
  • Outage in the broker’s trading systems, etc.

He picks a new broker, XYZ. Now he has a problem. All of his strategy code uses functions that are specific to broker ABC, so the strategy will not work with XYZ. He has to change the code everywhere to use the functions provided by XYZ, and then test everything again.

This is a lot of technical work that the trader should not be doing. He should spend his time improving his trading strategy instead.

If he had used a broker independent API instead of a broker specific API, switching brokers would need only a setting change.

Scenario 2: Trade with multiple brokers

Here the trader wants to trade with multiple brokers. This is also a realistic scenario. The reasons could be:

  • To stay safe if one broker’s trading system has an outage
  • To trade the same strategy in a spouse’s account
  • To reduce risk by spreading funds across many brokers

The problem is the same. His strategy is coded using a broker specific API, so it will not work with any other broker. He would need a separate copy of the same strategy for each broker. That means a lot of extra programming and testing.

If he had used a broker independent API, he would only need to add more trading accounts in the settings.

Loosely coupled trading system

A loosely coupled trading system does not depend on a broker specific API. Instead, it uses a broker independent API. This has many advantages:

  • Change stock broker from settings (no code change required)
  • Trade in multiple accounts (no code change required)
  • No need to test API functions across different brokers (the API provider takes care of it)
  • Lets traders focus on improving the trading strategy

How AutoTrader delivers broker independence

The broker independence offered by AutoTrader makes it easy to build flexible trading systems. A lot of work goes on behind the scenes to make this possible. It is built from these components:

We look at each of these components in the next section. You can also see the full list of supported brokers and how to add trading accounts in the settings.

Next steps

Was this page helpful?

Last updated 20 June 2026