Code: Select all
/ tool fetch "https://api.telegram.org/bot1111111111:t rAndomStrInGof lettersandnumbers/sendMessage?chat_id
=-222222222&text=Router $[/system identity get name] has detected the HP Printer Offline"
:log info "Telegram notification sent about HP Printer offline"
If the email script that works to send me an email is as follows when the DEVICE (printer) status is changed to DOWN:
Code: Select all
:local sub1 ([/system clock get time])
/tool e-mail send from="myemail@address.com.ca" body="At $sub1 HP Printer is Offline" subject="HP Printer is offline" to="myemail@address.com"
:log info "CHECK HP printer stat!!"
Is there some special syntax to join to separate functions??
This does not work........
Code: Select all
:local sub1 ([/system clock get time])
/tool e-mail send from="myemail@address.com.ca" body="At $sub1 HP Printer is Offline" subject="HP Printer is offline" to="myemail@address.com"
:log info "CHECK HP printer stat!!"
/ tool fetch "https://api.telegram.org/bot1111111111:t rAndomStrInGof lettersandnumbers/sendMessage?chat_id
=-222222222&text=Router $[/system identity get name] has detected the HP Printer Offline"
:log info "Telegram notification sent about HP Printer offline"