ru en de fr pt es it zh ar nl sv
API интерфейсСпециально для наших партнеров разработан API интерфейс
get_service_info

Получить информацию о сервисе

Параметры запроса
Parameter Type Description Required
action string get_service_info Обязательный
hash string Ваш хеш для работы с API Обязательный
userid int Ваш номер клиента Обязательный
serviceid int ID сервиса Обязательный
Example Request (CURL)
$postfields = array(
				"userid"=>$userid,
				"hash"=>$hash,
				"action"=>"get_service_info",
				"serviceid"=>3
				);
$result = connect_client_api_o2proxycom($postfields);

function connect_client_api_o2proxycom($postfields){
	 $url = "https://my.virty.io/includes/client_api/index.php"; # URL to o2proxy.com API
	 $ch = curl_init();
	 curl_setopt($ch, CURLOPT_URL, $url);
	 curl_setopt($ch, CURLOPT_POST, 1);
	 curl_setopt($ch, CURLOPT_TIMEOUT, 1000);
     curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
     curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
	 curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
	 curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);
	 $data = curl_exec($ch);
	 curl_close($ch);
	 return $data;
}

Ответ:
string(480) "{"code":"2001","status":"successful","ips":"192.168.1.1,192.168.1.2","login":"loginforproxy","password":"hM8sdf7sdf","socks5_port":"24532","http_port":"24531","expired_time":1556139600,"service_status":"active","socks5_url_proxylist":"https:\/\/my.virty.io\/proxy_list\/proxies.php?hash=fghfg45fgdfgfddfgdf16ab7&type=socks5&format=format1","http_url_proxylist":"https:\/\/my.virty.io\/proxy_list\/proxies.php?hash=fghfg45fgdfgfddfgdf16ab7&type=http&format=format1"t=format1","invoices":[{"id":"56641","status":"Paid","date":"2019-10-18","datepaid":"2019-10-18 19:34:58","duedate":"2019-10-18"}]}"