I have tried below code from here but there is a error called no HttpRequest class found. I am using php version 5.6.8(xampp v3.2.1). Any one please help me.
<?php
$request = new HttpRequest();
$request->setUrl('https://api.infobip.com/sms/1/text/single');
$request->setMethod(HTTP_METH_POST);
$request->setHeaders(array(
'accept' => 'application/json',
'content-type' => 'application/json',
'authorization' => 'Basic sfdsdf==' // name&password
));
$request->setBody('{
"from":"test", //from
"to":"000", // number
"text":your verification code is = 000."
}');
try {
$response = $request->send();
echo $response->getBody();
} catch (HttpException $ex) {
echo $ex;
}