• Модуль: imopenlines
  • Путь к файлу: ~/bitrix/modules/imopenlines/lib/rest.php
  • Класс: BitrixImOpenLinesRest
  • Вызов: Rest::operatorFinish
static function operatorFinish($arParams, $n, CRestServer $server)
{
	$arParams = array_change_key_case($arParams, CASE_UPPER);

	$control = new Operator($arParams['CHAT_ID']);
	$result = $control->closeDialog();
	if (!$result->isSuccess())
	{
		$errors = $result->getErrors();
		$error = current($errors);
		throw new RestException($error->getMessage(), $error->getCode(), CRestServer::STATUS_WRONG_REQUEST);
	}

	return true;
}