• Модуль: socialservices
  • Путь к файлу: ~/bitrix/modules/socialservices/lib/apclient.php
  • Класс: BitrixSocialservicesApClient
  • Вызов: ApClient::checkConnection
protected function checkConnection(array $connection)
{
	foreach(static::$requiredKeys as $key)
	{
		if(empty($connection[$key]))
		{
			throw new ArgumentNullException('connection['.$key.']');
		}
	}

	$endpoint = new Uri($connection['ENDPOINT']);
	if(!$endpoint->getHost())
	{
		throw new ArgumentException('Invalid connection[ENDPOINT] value');
	}

	return true;
}