Last active
June 1, 2025 07:01
-
-
Save therusetiawan/cc6271610be1512772742fcbf1011e0c to your computer and use it in GitHub Desktop.
Script to monitor hotspot user log
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### On Login Script | |
| :put (",,0,,,,Disable,");{ | |
| :local key "KEY DARI WINBOT"; | |
| :local noHP "NO HP TUJUAN"; | |
| :local mac $"mac-address"; | |
| :local device [/ip dhcp-server lease get [find mac-address="$mac"] host-name]; | |
| :local activeCount [/ip hotspot active print count-only]; | |
| /tool fetch url="https://api.mikrotik-winbot.com/api/v1/whatsapp/send_message/$noHP/$key/LOG-IN USER $user -enter-IP Address : $address -enter-Mac Address : $mac -enter-Device : $device -enter-Online : $activeCount Users " mode=http keep-result=no} | |
| ### On Logout Script | |
| :local key "KEY DARI WINBOT"; | |
| :local noHP "NO HP TUJUAN"; | |
| /tool fetch url="https://api.mikrotik-winbot.com/api/v1/whatsapp/send_message/$noHP/$key/LOGOUT USER $user -enter-IP Address : $address" mode=http keep-result=no |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment