Skip to content

Instantly share code, notes, and snippets.

@ryanhs
Created May 20, 2018 15:01
Show Gist options
  • Save ryanhs/890072a0ec2a2a272abf238c2761db57 to your computer and use it in GitHub Desktop.
Save ryanhs/890072a0ec2a2a272abf238c2761db57 to your computer and use it in GitHub Desktop.
tele notif example
#!/bin/bash
notify() {
user_id=<your tele id>
bot_token=<your tele bot token>
message=$1
curl --data chat_id="${user_id}" \
--data "text=${message}" \
"https://api.telegram.org/bot${bot_token}/sendMessage"
}
notify "some message example with `date`"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment