Cancel a message you have scheduled to be sent in the future.


Parameter



Description



Required


idMessage ID
YES


 


Example


curl https://api.transmitsms.com/cancel-sms.json \
  -u 2e24c1cbdd987221e165d543f34b84bf:secret \
  -d id=48782

JSON Response



XML Response



{
  success: "OK",
  error: {
           code: "SUCCESS",
           description: "OK"
  }
}


<?xmlversion="1.0"encoding="UTF-8"?>
<response>
  <success>OK</success>
  <error>
    <code>SUCCESS</code>
    <description>BFFs</decscription>
  </error>
</response>


 


PHP Examples


<?php
 include'../../APIClient2.php';
 $api=new transmitsmsAPI("API_KEY",'API_SECRET');
 
 $result=$api->cancelSms(49680);
 
 if($result->error->code=='SUCCESS')
 {
     echo"Message cancelled";
 }
 else
 {
     echo"Error: {$result->error->description}";
 }