Skip to content

Instantly share code, notes, and snippets.

@Porrapat
Created January 27, 2020 08:59
Show Gist options
  • Save Porrapat/33ee8076f9569183af4514bf91a18a4a to your computer and use it in GitHub Desktop.
Save Porrapat/33ee8076f9569183af4514bf91a18a4a to your computer and use it in GitHub Desktop.
AUTH_KEY=
SENDER_NAME=
MOBILE=
TEXT="HELLO TEST LINE 1\nHELLO TEST LINE 2"
# Basic Implementation
curl -X POST -H "Content-Type: application/json" \
-H "Authorization: $AUTH_KEY" \
-d "{\"from\":\"$SENDER_NAME\",\"to\":\"$MOBILE\",\"text\":\"$TEXT\"}" \
"https://api2.ants.co.th/sms/1/text/single"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment