$result["CALL_VOTE"] = 'N';
         if ($result["QUEUE_TYPE"] == CVoxImplantConfig::QUEUE_TYPE_ALL) {
             $result["QUEUE_TYPE"] = CVoxImplantConfig::QUEUE_TYPE_EVENLY;
             $result["NO_ANSWER_RULE"] = CVoxImplantIncoming::RULE_VOICEMAIL;
         }
     }
     foreach (GetModuleEvents("voximplant", "onCallInit", true) as $arEvent) {
         ExecuteModuleEventEx($arEvent, array(array('CALL_ID' => $params['CALL_ID'], 'CALL_TYPE' => 2, 'ACCOUNT_SEARCH_ID' => $params['ACCOUNT_SEARCH_ID'], 'PHONE_NUMBER' => $params['PHONE_NUMBER'], 'CALLER_ID' => $params['CALLER_ID'])));
     }
     echo json_encode($result);
 } elseif ($params["COMMAND"] == "OutgoingGetConfig") {
     $result = CVoxImplantOutgoing::GetConfigByUserId($params['USER_ID']);
     CVoxImplantHistory::WriteToLog($result, 'PORTAL GET OUTGOING CONFIG');
     echo json_encode($result);
 } elseif ($params["COMMAND"] == "AddPhoneNumber") {
     $result = CVoxImplantConfig::AddConfigBySearchId($params['PHONE_NUMBER'], $params['COUNTRY_CODE']);
     CVoxImplantHistory::WriteToLog($result, 'CONTROLLER ADD NEW PHONE NUMBER');
     echo json_encode($result);
 } elseif ($params["COMMAND"] == "UnlinkExpirePhoneNumber") {
     $result = CVoxImplantConfig::DeleteConfigBySearchId($params['PHONE_NUMBER']);
     CVoxImplantHistory::WriteToLog($result, 'CONTROLLER UNLINK EXPIRE PHONE NUMBER');
     echo json_encode($result);
 } elseif ($params["COMMAND"] == "UpdateOperatorRequest") {
     $params['OPERATOR_CONTRACT'] = \Bitrix\Main\Text\Encoding::convertEncodingToCurrent($params['OPERATOR_CONTRACT']);
     CVoxImplantPhoneOrder::Update($params);
     $result = array('RESULT' => 'OK');
     CVoxImplantHistory::WriteToLog($result, 'UPDATE OPERATOR REQUEST');
     echo json_encode($result);
 } else {
     if ($params["COMMAND"] == "ExternalHungup") {
         $res = Bitrix\Voximplant\CallTable::getList(array('filter' => array('=CALL_ID' => $params['CALL_ID_TMP'])));