- 评论 (4)
- 评论 (8)
Telegram Alerts for MT5
Telegram Alerts is a tool which send alerts on trades to Telegram
- Alert on any event concerning a position : Opening, Closing, modification (SL, TP)
- Alert on Equity change
- Display Risk, Reward and progress of profit/lost for each position
- Send signals from your indicators or experts
This utility is FREE for a limited time. Please give feedback to make it great.
If you want to see this utility in action without installing it, join the demo group in Telegram : https://t.me/MT45Alerts
Telegram Setup instruction
- Open your Telegram APP and search for "BotFather"
- Type /start and click/type /newbot to create a new bot
- Give your bot a nickname and username (e.g., nickname: MyNameAlerts and username: MyNameAlertsBot <-- username has to be ended by 'bot')
- Congratulations! You have created your Telegram bot.
- Save your bot API token (e.g. 1324115883:AAH2Z9PlxKX3Fce1e_m_w3AB7vA2EZZ_GAD)
- Back in MetaTrader 4, go to Tools > Options > Expert Advisors > tick 'Allowed WebRequest for listed URL' and add https://api.telegram.org.
- Attach the utility into your MetaTrader 4 chart and enter the Telegram Bot Token (from step 5)
- In Telegram open the Bot (search Bot username and start a chat with it)
- Press Start or enter /start
- You should get a message that the Chat Id is not correct. This message shows your Chat ID
- In Metatrader, open the utility properties and enter the Chat ID with the correct ID. This makes sure you are the only one who can use the Bot
- Back to Telegram, type /start . You should get information on your trading account number and equity
- Telegram Alerts is ready to work for you
- Bot Api Token: The unique token of your bot. Do not share this information.
- Chat ID: Your Telegram Chat ID
- Language: Choose English, French, Spanish or Brazilian portugues (contact me if need more)
- Rounding digits: How to display currency values. By default, digits=0, means rounded to the nearest integer (e.g 35€ instead of 35.23€)
- Alerts on events: Choose All if you want to be alerted on any events (Open, Closed and Modified). Otherwise choose Open & Closed
- Magic Numbers: Enter magic numbers (separated by space) if you want to be alerted on filtered orders (e.g generated by a robot)
- Alert Start Time: Choose the time you want to start receiving alerts (from 0 to 24)
- Alert End Time: Choose the time you want to stop receiving alerts (from 0 to 24)
- % of Equity alert: If you want to be alerted when Equity changes, enter the percentage (e.g 1 for 1%) if Equity variation. Keep 0 for not being alerted. Equity Alert works around the clock (24/24), not taking into account the Alert Start and End time parameters.
Integration with your own indicators and experts
This utility can be used by your own indicators and EA to send signals to Telegram. They just have to create a text file, containing the signal, to the following directory:
<Data Folder>/Telegram Alerts/<Your trading account Number/signals
You can use the following code in your indicator or EA:
string directory="Telegram Alerts/"+IntegerToString(AccountInfoInteger(ACCOUNT_LOGIN))+"/signals";
string signal="BUY EURUSD 1.20202 SL=1.201 TP=1.203";
bool saveStringFile(string s,string fileName)