Created
October 30, 2018 11:11
-
-
Save lewisdaly/cbab097828a68d9028126091e2a9cc7a to your computer and use it in GitHub Desktop.
Simple way to create daily usage trigger alerts with Twilio
This file contains 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
#!/usr/bin/env bash | |
curl -XPOST https://api.twilio.com/2010-04-01/Accounts/$TWILIO_ACCOUNT_SID/Usage/Triggers.json \ | |
-d "CallbackUrl=$CALLBACK_URL" \ | |
-d "UsageCategory=totalprice" \ | |
-d "FriendlyName=test_trigger" \ | |
-d "TriggerBy=price" \ | |
-d "TriggerValue=5.0000" \ | |
-d "Recurring=daily" \ | |
-u "$TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment