我有一个有点问题停止smsgateway,我创建了以下功能:我怎么能发送任何更多的消息
function sendQuedMessagesByDeviceAndDate($deviceId){
require_once 'php/classes/smsGateway.php';
$smsGateway = new SmsGateway(SMS_GATEWAY_EMAIL, SMS_GATEWAY_PASSWORD);
$result = $smsGateway->getQuedMessages($deviceId);
$arr = $result['response']['result'];
$data = array();
$options = [
'expires_at' => strtotime('+24 hours') // Cancel the message in 24 hours if the message is not yet sent
];
foreach($arr as $res){
if($res['status'] == 'queued' && $res['device_id'] == $deviceId && $res['queued_at'] > 1475452800 && $res['queued_at'] < 1475539200){
array_push($data, $res);
}
}
//$nrs = array();
foreach($data as $mes){
$smsGateway->sendMessageToNumber($mes['contact']['number'], $mes['message'], $deviceId, $options);
}
//return $data;
}
,我已经叫起作用的错误5-6次,怎么能我告诉服务器来自smsgateway停止发送消息,我找不到任何API调用来停止消息,并且来自他们网站的电子邮件是错误的,我不能给他们发送任何电子邮件,并且我没有任何国际拨打电话。