Skip to content

Instantly share code, notes, and snippets.

@jaboutboul
Created November 22, 2011 22:17
Show Gist options
  • Save jaboutboul/1387215 to your computer and use it in GitHub Desktop.
Save jaboutboul/1387215 to your computer and use it in GitHub Desktop.
Viewing Call Records
<?php
include 'Services/Twilio.php';
include 'credentials.php';
$version = "2010-04-01";
$client = new Services_Twilio($ACCOUNT_SID, $AUTH_TOKEN, $version);
try {
foreach ($client->account->calls as $call){
echo nl2br("Call from $call->from to $call->to at $call->start_time of length \"$call->duration\".\n");
}
}
catch (Exception $e){
echo "Message: ".$e->getMessage();
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment