- In a python environment that has pip installed, do
pip install twilio
thenpip install phonenumbers
. - Do
python risky-account-finder.py
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
<?php | |
/* | |
* Download the twilio-php helper library from: | |
* https://github.com/twilio/twilio-php | |
* Copy the "Services" folder into the directory containing this file. | |
*/ | |
require('Services/Twilio.php'); | |
$response = new Services_Twilio_Twiml; | |
$dial = $response->dial(); |
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
<?php | |
/** | |
* ### Subaccount Circuit Breaker Script ### | |
* This script is designed to make a subaccount suspend itself in response to | |
* a Usage Trigger firing a callback. You can learn about Usage Triggers here: | |
* https://www.twilio.com/docs/api/rest/usage-triggers | |
* | |
* Why would you want to do this? In some cases suspending a subaccount based on high, | |
* unexpected usage can be a good thing. Coding errors and fraud can both cause spikes | |
* in undesired usage. Setting this script up might help you to sleep better at night. |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<Response> | |
<Say>This call may be recording for Quality Assurance purposes.</Say> | |
<Dial record="true"> | |
<Number url="message.xml">+18085551234</Number> | |
</Dial> | |
</Response> |
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
<?php | |
/** | |
* Download the library from: https://github.com/twilio/twilio-php | |
* Copy the 'Services' folder into a directory containing this file. | |
*/ | |
require('Services/Twilio.php'); | |
$account_sid = "ACXXXXXXXXXXX"; // Your Twilio account sid | |
$auth_token = "YYYYYYYYYYYY"; // Your Twilio auth token |
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
<?php | |
// Sending SMS messages from a pool of numbers | |
// Load the Twilio PHP Helper Library | |
// This library can be downloaded from: https://github.com/twilio/twilio-php | |
require('Services/Twilio.php'); | |
// Fill in your account credentials | |
$sid = "ACXXXXXXX"; // Your Account SID from www.twilio.com/user/account | |
$token = "YYYYYYY"; // Your Auth Token from www.twilio.com/user/account |
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
<?php | |
/** | |
* Include the offical Twilio PHP Helper Library, which can be found at | |
* http://www.twilio.com/docs/libraries | |
*/ | |
include 'Services/Twilio.php'; | |
// Your Twilio Credentials | |
$accountSid = 'AC1987654gef...'; // Replace with your own Account Sid |
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
<?php | |
$db = new PDO('sqlite:database.sqlite'); | |
// Create the SQLite table. | |
$db->exec('CREATE TABLE gather_date (id INTEGER PRIMARY KEY, call_sid TEXT(32), year TEXT(4), month TEXT(2), day TEXT(2));'); | |
// Populate it with some data | |
$db->exec("INSERT INTO gather_date (call_sid, year, month, day) VALUES ('fhsdhfiuh', '2010', '09', '01');"); | |
if (file_exists('database.sqlite')) |
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
<?php | |
$twilio_welcome_message = "Welcome to Twilio SMS. Configure your number's SMS URL to change this message. Reply HELP for help. Reply STOP to unsubscribe. Msg&Data rates may apply."; | |
if($_RESPONSE['Body'] != $twilio_welcome_message){ | |
echo("<Sms>Welcome to Twilio SMS. Configure your number's SMS URL to change this message. Reply HELP for help. Reply STOP to unsubscribe. Msg&Data rates may apply.</Sms>"); | |
} |
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
<form action="form_to_sms.php" method="post"> | |
<label for="phone">Phone Number</label> | |
<input type="tel" name="phone"/><br/> | |
<label for="body">Message Body</label> | |
<textarea name="body" maxlength="160"></textarea><br/> | |
<input type="submit" /> | |
</form> |