Designing a Synchronous Order-Following System with Controls
Summary
This article describes a server strategy that receives trade signals and mirrors them on a connected exchange. It adds a pause-and-restart control protected by a password, allowing order following to be disabled without stopping the bot. It also supports either a fixed order size or scaling the incoming signal size by a ratio, while disallowing both settings at once.
The design parses a symbol, contract type, direction, and amount, then routes spot and futures actions through helper functions. The article illustrates the process with a test in which one exchange sends orders and another follows them, including opening and closing a short position. The demonstrated order size is adjusted to meet the receiving exchange's integer-size requirement. These examples show the intended workflow but do not establish reliability under network failures, duplicate signals, partial fills, or live risk conditions; the authors describe the code as a basis for further modification and testing.
Key ideas
- A password-protected control can suspend and resume signal following while the bot remains active.
- Order size can be fixed or scaled from the incoming signal, but the two modes are mutually exclusive.
- The server maps parsed spot or futures directions to exchange order functions.
- The example demonstrates mirrored opening and closing trades across two exchange accounts.
- The article does not analyze failure handling or live trading risk.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.