After doing a huge amount of research i cant find a way how to add new carrier to SMS app.
here is the sample code from carrier, wish to have some help how to add it well.
$url = "https://carrier.com/api";
$key = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
$xml ='
<?xml version="1.0" encoding="UTF-8"?>
<sms>
<user>
<username>UserNmae</username>
</user>
<source>'SourceNumber'</source>
<destinations>
<phone>'DestionationNumber'</phone>
</destinations>
<message>'Message'</message>
</sms>';
$CR = curl_init();
curl_setopt($CR, CURLOPT_URL, $url);
curl_setopt($CR, CURLOPT_POST, 1);
curl_setopt($CR, CURLOPT_FAILONERROR, true);
curl_setopt($CR, CURLOPT_POSTFIELDS, $xml);
curl_setopt($CR, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($CR, CURLOPT_HTTPHEADER, array(
'charset=utf-8',
'Content-Type: application/json',
'Authorization: Bearer ' . $key
)
);
$result = curl_exec($CR);
$error = curl_error($CR);
if (!empty($error))
die("Error: " . $error);
else
here is the sample code from carrier, wish to have some help how to add it well.
$url = "https://carrier.com/api";
$key = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
$xml ='
<?xml version="1.0" encoding="UTF-8"?>
<sms>
<user>
<username>UserNmae</username>
</user>
<source>'SourceNumber'</source>
<destinations>
<phone>'DestionationNumber'</phone>
</destinations>
<message>'Message'</message>
</sms>';
$CR = curl_init();
curl_setopt($CR, CURLOPT_URL, $url);
curl_setopt($CR, CURLOPT_POST, 1);
curl_setopt($CR, CURLOPT_FAILONERROR, true);
curl_setopt($CR, CURLOPT_POSTFIELDS, $xml);
curl_setopt($CR, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($CR, CURLOPT_HTTPHEADER, array(
'charset=utf-8',
'Content-Type: application/json',
'Authorization: Bearer ' . $key
)
);
$result = curl_exec($CR);
$error = curl_error($CR);
if (!empty($error))
die("Error: " . $error);
else