To assist our developers to quickly build enterprise grade voice enable applications, TringMe has released source code for it's widgets. It can be downloaded from here. Below are sample examples of how easy it is to use TringMe APIs.

Create Account

Following is an implementation of a Create Account using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$email ='someemail@somedomain.com';
$name ='Some Name';
$password ='SomePassword';

TringMeCreateUser($email, $password, $result, $name);
?>

Login

Following is an implementation of how to LogIn using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$callsrc ='18585551111';
$calldest ='18585552222';
TringMeCall($privatekey, $publickey, $callsrc, $calldest);

?>

Call

Following is an implementation of a Click To Call application using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$pin ='1234';
$apin ='5678';

TringMeCreateConference($pin, $apin, $result);

?>

Conference

Following is an implementation of how to Create a Conference using TringMe APIs.

<'?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$pin ='1234';
$apin ='5678';

TringMeCreateConference($pin, $apin, $result);
?>

Send SMS

Following is an implementation of how to send an SMS using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$destination ='18585552222';

TringMeSendSMS($privatekey, $publickey, $destination, "Hello World");
?>

Channel

Following is an implementation of how to create a Channel using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$destination ='18585552222';

TringMeSendSMS($privatekey, $publickey, $destination, "Hello World");
?>

Get Rates

Following is an implementation to Get the Rates for a number using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$callsrc ='18585551111';
$calldest ='18585552222';
TringMeCall($privatekey, $publickey, $callsrc ,$calldest);
?>

SIP Settings

Following is an implementation to set your SIP Settings using TringMe APIs.

<?php
include_once ("tringmehelper.php");
$publickey = "yourpublicapikey";
$privatekey = "yourprivateapikey";
$destination ='18585552222';
TringMeSendSMS($privatekey, $publickey, $destination, "Hello World");
?>

More examples can be found in the code samples available for download here


If you are an enterprise and would like to know better how TringMe can help you reduce cost and at the same time benefit you,
please send a mail to bizdev@tringme.com