v3 SMS کا نیٹ ورک سے باہر ٹیسٹ

تفصیل:

نمبر پر آزمائشی ایس ایم ایس بھیجیں


URI:

https://api.multitel.net/v3/offnet/sms

پیرامیٹرز:

Required: 
number -  your SMS enabled phone number 

Optional:
notify_url - if provided, we will post back any status changes to this URL. (example: https://customer-crm.xyz/notify-handler )

طریقے:

POST


نمونہ آؤٹ پٹ:

{
  "status":
    {
      "code":"200",
      "msg":"Success"
    },
  "response":""
  }

نمونہ کوڈ:


<?
$curl = curl_init();
  curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://api.multitel.net/v3/offnet/sms',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
    "number":"15203861195",
    "notify_url":"https://customer-crm.xyz/notify-handler"
}',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Basic d2ViZGV2b3BzOmNvbm51b243Nw==',
    'Content-Type: application/json'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

دستاویزات تلاش کریں