Termos de Referência
Project Overview:
I am looking for an expert MetaTrader 5 (MT5) developer/architect to build a highly optimized, professional-grade Trade Copier system. This is NOT a basic trade copier. It requires advanced execution handling, bypass mechanisms, strict risk management, and multi-threaded syncing.
Here are the complete requirements for the project:
1. Architecture & Topology:
-
Multi-Account Routing: Must support both One-to-Many (1 Master $\rightarrow$ up to 30 Slaves, grouped in batches of 5) and Many-to-One (up to 10 Masters $\rightarrow$ 1 Single Slave account).
-
Consolidation Logic: In Many-to-One mode, the system must properly track order tickets/magic numbers so trades from different masters do not conflict on the single slave.
-
Read-Only Master Compatibility: Must flawlessly extract and copy trades from Master accounts even if logged in using only an "Investor Password" (Read-Only mode).
2. Core Execution Mechanisms:
-
Hybrid Execution Engine (Standard vs. Stealth Mode):
-
Execution Mode = Standard / Stealth (Configurable per slave).
-
Standard: Uses standard MT5 OrderSend() for ultra-fast execution on normal brokers.
-
Stealth (EA-Block Bypass): For brokers restricting EAs on client charts, the copier MUST execute trades mimicking "Manual Trades" (e.g., via Windows API Automation, GUI injection, or external hooks) to bypass restrictions.
-
-
Reverse Trading: Reverse Trading = True/False . Automatically inverts BUY/SELL and calculates inverted SL/TP.
-
Bi-Directional Closure (Slave-to-Master Sync): Slave-to-Master Close Sync = True/False . If turned ON, closing a trade on the Slave account must immediately trigger the closure of the corresponding original trade on the Master account.
3. Advanced Logic & Resizing:
-
Real-Time Dynamic Risk Resizing: If I change the risk multiplier or lot proportion settings while trades are already active, the copier must automatically modify/adjust the open position sizes in real-time on slave terminals (via partial close or adding volume).
-
Forced Virtual Netting Mode: Enforce Netting Logic = True/False . If ON, even if the slave is a Hedging account, it must act as a Netting account. (e.g., If Slave has a SELL and Master sends a BUY, the copier must NOT hedge; it must Square-off/Close the existing SELL).
-
Contract Size Normalization: Ability to define a "Contract Size Ratio" to adjust lot sizes automatically if the Master and Slave brokers have different asset specifications (e.g., Gold 100 oz vs 10 oz).
4. Safety, Syncing & "Anti-Loop" Protection:
-
Smart Anti-Loop (Death Loop Prevention): If a slave trade is closed prematurely (Margin Call, Stop-Out, Broker Error) but remains open on the Master, the copier MUST NOT enter an infinite force-sync loop. It must add the ticket to a temporary "Ignore List".
-
GUI "Force Sync" / Scan Button: A clickable button on the dashboard. When I deposit new funds and click it, the copier must scan, clear the Ignore List, and instantly sync/reopen missing positions at the current market price.
-
Global Panic Button: A highly visible emergency "Kill Switch" that instantly closes ALL open positions across ALL slaves, deletes pending orders, and stops copying immediately.
-
Max Time Filter: Do not copy trades if the master trade is older than X minutes.
-
Max Slippage Filter: Max Allowed Slippage = X Pips/Points . Do not execute on the slave if the price has deviated too far from the Master's entry.
5. Operational Features:
-
Advanced Symbol Mapping: Dynamic Prefix/Suffix auto-detection + custom mapping (e.g., EURUSD $\rightarrow$ EURUSD.ecn).
-
Symbol Filtering: Allow restricting copied trades by specific symbols per batch.
-
Preset (.set) Configurations: Save and 1-click load entire topology, mapping, and channel setups.
-
Centralized Dashboard Compatibility: Ability to sync running metrics across VPS nodes with external trackers (like FXBlue/Myfxbook).
6. Code Quality, Delivery & Future Scalability (Non-Negotiables):
-
Clean & Modular Code: Must be structured using full Object-Oriented Programming (OOP) principles.
-
Full Source Code Delivery: I require the complete uncompiled source code ( .mq5 and any associated .dll , .cs , or API scripts).
-
Multi-Device & VPS Compatibility: There must be NO hardware, IP, or domain locking. I must have complete freedom to run it locally or move it between VPS nodes without developer keys.
-
Execution Optimization: Multi-threaded/Asynchronous logic to keep latency under 0.5 seconds for 30+ accounts.
-
Detailed Logs: Generate real-time .txt logs for every event, broker error, and execution speed.
-
Long-Term Collaboration: After successful delivery, I will likely require future upgrades, which will be discussed and paid as separate milestones. I am looking for a reliable, long-term developer.