Reports

Short URL Report

Here you can get a detailed report of an individual Short URL.

Definition

http:// or https://

Methods

Required Parameters

uid: System allocated username for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management’
pass: System password for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management
suid: The Short URL ID. Can be acquired using surlist API

Optional Parameters

format: The format you wish the return status to be in

Default: XML

Options: XML

Single textual message to single destinations

Request

<?php
switch($_SERVER["REQUEST_METHOD"]) {
    case "GET":
        $uid = htmlspecialchars($_GET["uid"]);
        $pass = htmlspecialchars($_GET["pass"]);
        $surlid = htmlspecialchars($_GET["surlid"]);
        break;
    case "POST":
        $uid = htmlspecialchars($_POST["uid"]);
        $pass = htmlspecialchars($_POST["pass"]);
        $surlid = htmlspecialchars($_POST["surlid"]);
        break;
}

$url = 'https://www.voodoosms.com/vapi/server/surlrep?uid='.$uid.'&pass='.$pass.
        '&surlid='.$surlid;

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
// Download the given URL, and return output
$output = curl_exec($ch);
echo $output . "   " . curl_error($ch);
// Close the cURL resource, and free system resources
curl_close($ch);
?>

Response

<xml>
   <item>
      <click_time>2017-05-05 14:01:22</click_time>
      <ip_address>192.168.0.12</ip_address>
   </item>
   <item>
      <click_time>2017-05-05 14:01:37</click_time>
      <ip_address>192.168.12.55</ip_address>
   </item>
</xml>

On success, the response header HTTP status code will be 200 OK confirming that the message is sent. If you try to send message without authorisation you an error code of 401 Unauthorized will be received.

SMS Response Details

Response Code

Code Type Response
400 int BAD REQUEST required parameters missing
401 int UNAUTHORIZED CHECK API USER
204 int No Record Found.

Short URL Report

Here you can get a list of all the ShortURL’s setup on your account.

Definition

http:// or https://

Methods

Required Parameters

uid: System allocated username for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management’
pass: System password for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management

Optional Parameters

format: The format you wish the return status to be in

Default: XML

Options: XML

Single textual message to single destinations

Request

<?php
switch($_SERVER["REQUEST_METHOD"]) {
    case "GET":
        $uid = htmlspecialchars($_GET["uid"]);
        $pass = htmlspecialchars($_GET["pass"]);
        break;
    case "POST":
        $uid = htmlspecialchars($_POST["uid"]);
        $pass = htmlspecialchars($_POST["pass"]);
        break;
}

$url = 'https://www.voodoosms.com/vapi/server/surlist?uid='.$uid.'&pass='.$pass;

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
// Download the given URL, and return output
$output = curl_exec($ch);
echo $output . "   " . curl_error($ch);
// Close the cURL resource, and free system resources
curl_close($ch);
?>

Response

<xml>
   <item>
      <short_url_id>1234</short_url_id>
      <name>VoodooSMS</name>
      <shorturl>vsms.co/3Sc</shorturl>
      <longurl>https://www.voodoosms.com</longurl>
      <created_date>2017-05-05 13:59:50</created_date>
      <tracked>1</tracked>
      <clicks>4</clicks>
   </item>
</xml>

On success, the response header HTTP status code will be 200 OK confirming that the message is sent. If you try to send message without authorisation you an error code of 401 Unauthorized will be received.

SMS Response Details

Response Code

Code Type Response
400 int BAD REQUEST required parameters missing
401 int UNAUTHORIZED CHECK API USER
204 int No Record Found.

Web SMS Report

Here you can retrieve the statistics of your Web SMS campaigns.

Definition

http:// or https://

Methods

Required Parameters

uid: System allocated username for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management’
pass: System password for API user configured within the VoodooSMS.com Portal in ‘Send SMS>API Management

Optional Parameters

date: The date of the report you wish to retrieve.

Default: current date

Options: Y-m-d (2017-08-02)
format: The format you wish the return status to be in

Default: XML

Options: XML

Single textual message to single destinations

Request

<?php
switch($_SERVER["REQUEST_METHOD"]) {
    case "GET":
        $uid = htmlspecialchars($_GET["uid"]);
        $pass = htmlspecialchars($_GET["pass"]);
        break;
    case "POST":
        $uid = htmlspecialchars($_POST["uid"]);
        $pass = htmlspecialchars($_POST["pass"]);
        break;
}

$url = 'https://www.voodoosms.com/vapi/server/wsmsrep?uid='.$uid.'&pass='.$pass;

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
// Download the given URL, and return output
$output = curl_exec($ch);
echo $output . "   " . curl_error($ch);
// Close the cURL resource, and free system resources
curl_close($ch);
?>

Response

<xml>
   <item>
      <id>20162</id>
      <SendTime>2017-04-05 13:55:00</SendTime>
      <name>Web SMS Testing</name>
      <originator>VoodooSMS</originator>
      <sent>1</sent>
      <delivered>1</delivered>
      <pending>0</pending>
      <failed>0</failed>
      <body>Your message here</body>
      <shorturlid>vsms.co/3Sc</shorturlid>
      <shorturl></shorturl>
      <longurl></longurl>
   </item>
</xml>

On success, the response header HTTP status code will be 200 OK confirming that the message is sent. If you try to send message without authorisation you an error code of 401 Unauthorized will be received.

SMS Response Details

Response Code

Code Type Response
400 int BAD REQUEST required parameters missing
401 int UNAUTHORIZED CHECK API USER
204 int No Record Found.