SMS API Print

  • 8

PHP Version:

Prerequisite:

1)      PHP 4 >= 4.3.0, PHP 5, PHP 7

2)      For server need  (allow_url_fopen = On) on php.ini file

3)      Text encode knowledge

In Action:

You need a unique ApplicationId (You can collect from support team) and pass sms information with encode.

//$number must be without country code or zero.

$number = '799888799';

//$sender will be string, character limit 11 without any space.

$sender = 'AICT';

//$text will be plain text.

$text= 'We Love AryanIct';

//$type will be integer 0 or 2. 0 for Plain Text and 2 for Arabic Text

$type=0;

 

$data = array('number'=>$number, 'sender'=>$sender, 'text'=>$text, 'type'=>$type);

$data = base64_encode(CJSON::encode($data));

$appId = ApplicationId (You can collect from support team);

$API_URL ='https://www.aryanict.com/api/sendSms';

 $return = file_get_contents($API_URL . '?appID=' . $appId .'&data='. $data);

$return have 0 or 1. 0=Not Sent and 1=Sent



ARYAN ICT Solutions SMS Balance API URL
:

https://www.aryanict.com//api/getRemainingSms?appID=AICT*** 


Was this answer helpful?

« Back