Last active
August 29, 2015 14:04
-
-
Save superchausette/c5c52bd44ec632d8bcc3 to your computer and use it in GitHub Desktop.
Send SMS to myself using the Free (illiad) SMS api
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
#!/bin/bash | |
USER=XXXXXXX | |
PASSWD=XXXXX | |
URL=https://smsapi.free-mobile.fr/sendmsg | |
if [ $# -eq 0 ] | |
then | |
echo "No message supplied" | |
exit | |
fi | |
MSG="$*" | |
CURL_ARGS="-G --insecure -I" | |
# --insecure since there is some issue with free cert | |
# -I to get HTTP return code | |
curl $CURL_ARGS --data-ascii user=$USER --data-ascii pass=$PASSWD --data-asci msg="$MSG" $URL |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment