Create Telegram Bots for Mikrotik

One day in April 2024, my boss told me to create a bunch of Telegram Bots so he could check the network right from Telegram without the need to log in to Mikrotik.

1. Admin privilege on Mikrotik.
2. Telegram Desktop
3. Browser (duh)

Read more: Create Telegram Bots for Mikrotik
  1. Open Telegram, create new group, add new human member.
  2. Search @BotFather in Telegram search column.
  3. Type /start to BotFather, wait for his reply.
  4. Type /newbot, then give your bot a name.
  5. Look for token HTTP API in BotFather message. Paste the token in your favorite text editor. Mine is 6342848463:AAG04h_yVRK9s7plReAWRDgFVGXsiBfVnEI
  6. Add your bot to the group you created in step 1.
  7. It’s time to find out your group chat id. Use this template and adjust it to your token in step 5: Mine is The paste that URL in your browser. Mine is -4179390964. The group chat id is always number with minus sign.
  8. You’re done on Telegram. It would be useful if you paste all those number in your favorite text editor. It’s time to move to Mikrotik.
  9. As admin or root, login to your Mikrotik via Winbox.
  10. Go to Tools —> Netwatch, click + sign (create new netwatch). Keep the default values on Interval and Timeout. On Host tab, type your server’s IP in Host column, then add this in Up tab: /tool fetch url=” One connect” keep-result=no
  11. On Down tab: /tool fetch url=” One down” keep-result=no


Work till death do me part.

Leave a Reply