10 lines
208 B
Bash
10 lines
208 B
Bash
|
#!/bin/bash
|
||
|
token="APItoken"
|
||
|
userid="usernameorid"
|
||
|
|
||
|
#1. arg = text
|
||
|
send() {
|
||
|
echo "Sending $1 to ${userid}"
|
||
|
curl -s "https://api.telegram.org/bot${token}/sendMessage?chat_id=${userid}&text=$1" > /dev/null
|
||
|
}
|