A copy-trading system on MasterTrust
- Type
- Client project, anonymised
- Duration
- 3 months
- Team
- 1 senior and 1 junior developer
- Stack
- C# (.NET), SQL
- Broker
- MasterTrust, through its REST API
- Signals
- The client’s own trades, entered by hand or from TradingView
- Scale
- Many accounts
- Markets
- Stocks, futures and options
- Outcome
- Fully automated copy trading
What it does
The client places a trade once, either by hand or as an alert from TradingView. The system then carries it out in every account automatically, working out the right size for each account, through MasterTrust’s REST API. It covers stocks, futures and options, and it runs without anyone placing orders account by account.
The order handling it needed
Copying a trade is the easy part. The work is in everything that can happen to the orders afterwards, separately in every account:
- Sizing per account. Each account gets its own quantity, worked out by the system rather than typed in.
- Market and limit orders. Both order types are supported for every account.
- Bracket orders. An entry can go out with its stop loss and exit attached, so each account has its stop in place from the moment it enters.
- Partial fills. When only part of an order fills in one account, that account is handled on its own, so its position stays correct.
- A trailing stop loss for each account. The stop follows the price separately in every account.
How we worked
One senior and one junior developer built it in C# (.NET) with a SQL database over three months.
The result
A fully automated copy-trading system for stocks, futures and options on MasterTrust. The client places a trade once, and every account receives its own correctly sized orders, with bracket orders, partial fills and a trailing stop loss handled for each one.
For more on the broker side, see our Indian broker API integration page. Automating orders through an Indian broker also has to fit SEBI’s rules for retail algo trading, which our plain-English guide explains. The general pattern is on our copy-trading platform page, and TradingView integration covers the alert side.
This is an anonymised account of client work. The client’s identity, the trades and any trading figures have been removed, and every trading decision is the client’s own. We build technology. We do not provide investment advice, we do not manage money, and we make no claim about how any trade or strategy performs.