Fast API Copier
- 유틸리티
- Konstantin Stratigenas
- 버전: 4.6
- 업데이트됨: 4 7월 2021
- 활성화: 10
This EA Connects Trading-Systems or Terminals on a Windows Server (VPS). You can also use it as a Trade Copier Local or Remote. Fast and stable Solution with 10ms Reaction Time.
- It works on VPS which allows to Run it as a Webserver (fixed IP Address and open Port 80 for Incoming Connections).
- It works on your own Datacenter / Computer with fixed IP or DNS.
Installation
- Download and Install Visual Studio 2019 on your Windows Server. Choose "ASP.NET and web Development". Download-URL: https://visualstudio.microsoft.com/downloads/?utm_content=download+vs2019
- Copy and extract this Files to C:\ or any Folder you want on your Windows Server: https://drive.google.com/file/d/1z24kXqLZ6sVJ6pwSZ7_uRb0v2vL1xZJ7/view?usp=sharing
- Set Windows Firewall to Ask if new Connection is needed.
- Make sure Port 80 is free. If IIS is installed change IIS Port for Example to 8080. https://youtu.be/2cnX1miEsas
- Open Command Line (Type Win+R and Enter "cmd").
- Navigate to the Folder with the Files by type "cd C:\" and after "cd tv2" and after "cd tv2".
- Type the follow Command to Run: dotnet run. (If your VPS Machine is slow and this Step takes more than 1 Minute, then disable Windows Defender Antivirus)
- Check API Endpoint with external URL http://YOUR_SERVER_IP/api/todoItems and internal URL 127.0.0.1/api/todoItems. You must see a JSON Value []
- Go to MT5 Terminal, open Menu Tools->Options->Expert Advisors->Allow Web Request for listed URL. Type in: 127.0.0.1 (MT5) or http://27.0.0.1 (MT4)
- Start Expert Advisor, set a secret Password. A Label "Connected" on the Chart, says you that the API is Ready.
If Step 8 is not Success with external URL http://YOUR_SERVER_IP/api/todoItems, then Install https://www.wireshark.org on your VPS Server to look for Incoming Connection on Port 80 like in Screenshot. You have to type in http://YOUR_SERVER_IP/api/todoItems from external Computer.
Setup Trading-System
Configure your Alerts in Trading-System. You need to make JSON Request like:
{ "Value":"{{strategy.order.comment}} tradesymbol=XAUUSD lot=0.03" ,"password":"YOUR_PASSWORD" }
In your Strategy write Comment "long" for Long Position or Comment "short" for Short Position. Write "closelong" to Close Long Position and "closeshort" to close Short Position. The Placeholder will be / must be replaced by the Alert and will look like this:
{ "Value":"long tradesymbol=XAUUSD lot=0.03" ,"password":"YOUR_PASSWORD" }
Alert Syntax
lot Set Fixed Lot
microlot Set the needed Amount for 1 microlot (Autolot)
For Example: Free Equity of 500$ and Microlot of 100$: (500$ / 100$) * 0.01 = 0.05 Lot. EA looks which is lower, Equity or Balance to Calculate the Autolot.
tradesymbol Symbol to Trade, for Example EURUSD or XAUUSD
long Open a Long Trade
short Open a Short Trade
closelong Close all Long Trades on used tradesymbol (from this EA / Magic Number)
closeshort Close all Short Trades on used tradesymbol (from this EA / Magic Number)
tradeid Unique Identifier for the Trade
close Close Trade. You need Parameter tradeid
sl Stoploss Price
tp Takeprofit Price
pyramiding defines how many Positions can be opened at same Symbol and Direction.
For example pyramiding=2 Maximal 2 eurusd long and 2 xauusd long.
closepart=%/Lot Close Percentage or Lot Amount of Winning Positions on same Symbol.
For example closepart=50% tradesymbol=eurusd Close 50% of eurusd.
riskpos=% open new Position if the Drawdown is below %. Needs Parameter long or short to open the Position.
hedge opens opposite Position of open Positions at same Position Size. Needs Param tradesymbol.
For example hedge tradesymbol=eurusd
closehedge close current hedge Position. So the Position is open again.
risk Open new Position based on Risk in Percentage of Equity or Balance (the lower one). Needs Parameter "long" or "short" and Parameter tradesymbol.
For example: long tradesymbol=ustec risk=1.5% sl=5% tp=3%
Channels
You can Target different Channels from your Trading-System. The Default Channel Address is
http://YOUR_SERVER_IP/api/todoItems
For second Channel use:
http://YOUR_SERVER_IP/api2/todoItems
Use Parameter Channel in EA, to listen to a different Channel than the Default.
Do not use same Channel for Copy and your Trading-Systems
Works well. I miss some extra functionality like being able to set a Stop loss.