Check file extensions
This commit is contained in:
@@ -7,7 +7,6 @@ use Illuminate\Support\Facades\Log;
|
||||
|
||||
/**
|
||||
* Un mask phone from "+(993)-xx-xx-xx-xx"
|
||||
* @param string|int $phone
|
||||
*/
|
||||
function unMaskPhone(string|int $phone): string
|
||||
{
|
||||
@@ -23,8 +22,8 @@ function sendSMS(string|int $phone, string|int $message)
|
||||
{
|
||||
$client = new Client();
|
||||
$headers = [
|
||||
'Content-Type' => 'application/json;charset=utf-8;',
|
||||
'Charset' => 'UTF-8'
|
||||
'Content-Type' => 'application/json;charset=utf-8;',
|
||||
'Charset' => 'UTF-8',
|
||||
];
|
||||
$body = 'JSON={
|
||||
"SendRequest": {
|
||||
@@ -32,11 +31,11 @@ function sendSMS(string|int $phone, string|int $message)
|
||||
"Version": "1",
|
||||
"Lang": "EN",
|
||||
"MobilePhone": "993'.$phone.'",
|
||||
"Text": "'. $message .'"
|
||||
"Text": "'.$message.'"
|
||||
}
|
||||
}';
|
||||
$request = new Request('POST', 'http://10.3.158.103:8080/kpsmsroute/online.request', $headers, $body);
|
||||
|
||||
|
||||
try {
|
||||
$res = $client->sendAsync($request)->wait();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user