#!/usr/bin/php -q
<?php
include("phpagi.php");
$agi = new AGI();
$agi->answer();
$text = 'تست';
$url = "https://ippanel.com/services.jspd";
$rcpt_nm = '1111';
$param = array
(
'uname'=>'1111',
'pass'=>'1111',
'from'=>'500010401589116',
'message'=>$text,
'to'=>json_encode($rcpt_nm),
'op'=>'send'
);
$handler = curl_init($url);
curl_setopt($handler, CURLOPT_CUSTOMREQUEST, "POST");
curl_setopt($handler, CURLOPT_POSTFIELDS, $param);
curl_setopt($handler, CURLOPT_RETURNTRANSFER, true);
$response2 = curl_exec($handler);
$response2 = json_decode($response2);
$res_code = $response2[0];
$res_data = $response2[1];
?>