How to setup Notify To Telegram

4 October 2021, 09:34
Trinh Dat
0
565

Notify To Telegram 


- You must allow WebRequest and add the https://api.telegram.org URL in "Tools" → "Options" → "Expert Advisors".

- Telegram Bot must is member of group or admin of channel.

- Attach it to one chart only.


How to get an chat ID:


- Chat with BotFather to create Bot and get API Token of Bot. If you had Bot, skip the step.

- Open the channel/group Info, then Manage, Add Administrators, type the bot username, and click Save

- Send any message to the channel/group like "hello world"

- chat with bot @userinfobot , then forward message on your channel to bot @userinfobot , the bot will reply your channel ID.


For custom message:


- Download file here  ( right click and save link as ) , then copy the file to folder <Data folder>/MQL4/Files/

- To add Emoji: search Emoji here and get code of symbol (  Unicode column )

- Below is all variable to add to custom message:

  1. [TICKET]  -> Order Ticket 
  2. [OPENTIME]   -> Order open time
  3. [TYPE]  -> Order type
  4. [SIZE]   -> Order size , order lots
  5. [SYMBOL]  -> Order symbol
  6. [OPENPRICE]  -> Order open price
  7. [S/L]  -> Order stoploss
  8. [S/L-PIPS]   -> Order stoploss in pips
  9. [T/P]  -> Order Takeprofit
  10. [T/P-PIPS]   -> Order Takeprofit in pips
  11. [COMMENT]  -> Order comment
  12. [CLOSEPRICE]  -> Order close price
  13. [CLOSETIME]  -> Order close time
  14. [EXPIRATION]  -> Order expire time
  15. [P/L]  -> Profit in money
  16. [P/L-PIPS]  -> Profit in pips
  17. [RISKREWARD]  -> Risk reward of order
  18. [OLD PRICE]   -> Old open price of pending order
  19. [OLD S/L]   -> Old order sl price
  20. [OLD T/P]   -> Old order takeprofitprice
  21. [ACCOUNT]  -> Account number
  22. [BALANCE]   -> Banlance 
  23. [EQUITY]   -> Equity 
  24. [CURRENCY]   -> Account Currency
  25. [BROKERTIME]   -> Time of broker
  26. [P/L %]  -> Profit percent = Profit / Banlance
  27. [TODAY-PL] -> Today profit in money
  28. [TODAY-PIPS]   -> Today profit in pips
  29. [REPORT_FROM] -> report from day without year
  30. [REPORT_TO] ->  report to day


Files:
Share it with friends: