| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Evoweb | 2011-12-08 | ||
| images | 2011-12-08 | ||
| Services | 2011-12-08 | ||
| config.install.php | 2011-12-08 | 14.3 kB | |
| install.php | 2011-12-08 | 6.1 kB | |
| LICENSE-Twilio | 2011-12-08 | 1.2 kB | |
| mainsms.php | 2011-12-08 | 3.8 kB | |
| Makefile | 2011-12-08 | 794 Bytes | |
| package.php | 2011-12-08 | 3.2 kB | |
| package.xml | 2011-12-08 | 5.4 kB | |
| README.md | 2011-12-08 | 2.0 kB | |
| readsms.php | 2011-12-08 | 703 Bytes | |
| _gitignore | 2011-12-08 | 8 Bytes | |
| backup.doc | 2011-12-08 | 36.4 kB | |
| install.do.php | 2011-12-08 | 3.0 kB | |
| multinumberdemo.ovbx | 2011-12-08 | 2.0 kB | |
| addrecord.php.new | 2011-12-08 | 1.5 kB | |
| AUTHORS | 2011-12-08 | 190 Bytes | |
| directions-newinstall.doc | 2011-12-08 | 86.0 kB | |
| directions-newinstall.txt | 2011-12-08 | 37.3 kB | |
| addrecord.php | 2011-12-08 | 1.5 kB | |
| adduser.php | 2011-12-08 | 3.1 kB | |
| content.php | 2011-12-08 | 22.0 kB | |
| deleterecord.php | 2011-12-08 | 1.8 kB | |
| deleteuser.php | 2011-12-08 | 1.6 kB | |
| editrecord.php | 2011-12-08 | 1.6 kB | |
| edituser.php | 2011-12-08 | 2.3 kB | |
| import.php | 2011-12-08 | 3.7 kB | |
| index.php | 2011-12-08 | 2.4 kB | |
| login.php | 2011-12-08 | 2.5 kB | |
| menu.php | 2011-12-08 | 2.5 kB | |
| styles.css | 2011-12-08 | 4.4 kB | |
| LICENSE-Other | 2011-12-08 | 102 Bytes | |
| LICENSE | 2011-12-08 | 1.2 kB | |
| error_log | 2011-12-08 | 42.6 kB | |
| config.php | 2011-12-08 | 14.3 kB | |
| Totals: 36 Items | 311.4 kB | 0 |
A Brief Introduction
With version 3.0 we've simplified interaction with the Twilio REST API. No more manually creating URLS or parsing XML/JSON. You now interact with resources directly. Follow the Quickstart Guide to get up and running right now. The User Guide shows you how to get the most out of twilio-php.
Prerequisites
- PHP >= 5.2.1
- The PHP JSON extension
Installing
Via PEAR (>= 1.9.3):
pear channel-discover twilio.github.com/pear
pear install twilio/Services_Twilio
From Source
Not using PEAR? Not a problem. Download the source which includes all dependencies.
Quickstart
Want to get up running with twilio-php in minutes? Read through the quickstart here. Highly suggested reading.
Full Documentation
http://readthedocs.org/docs/twilio-php/en/latest/
Reporting Issues
Report issues using the Github Issue Tracker or email help@twilio.com.
Sample Code
Making a Call
require "Services/Twilio.php";
$sid = "ACXXXXXX"; // Your Twilio account sid
$token = "YYYYYY"; // Your Twilio auth token
$client = new Services_Twilio($sid, $token);
$call = $client->account->calls->create(
'9991231234', // From this number
'8881231234', // Call this number
'http://foo.com/call.xml'
);
Generating TwiML
To control phone calls, your application need to output TwiML. Use Services_Twilio_Twiml to easily create such responses.
$response = new Services_Twilio_Twiml();
$response->say('Hello');
$response->play('monkey.mp3', array("loop" => 5));
print $response;
<?xml version="1.0" encoding="utf-8"?>
<Response>
<Say>Hello</Say>
<Play loop="5">monkey.mp3</Play>
</Response>