Added PARK_XFER|GRAB_XFER options for park_call Agent API function

git-svn-id: svn://192.168.202.10@3833 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2024-04-29 14:52:26 +00:00
parent 42f98a2e69
commit a6304da154
4 changed files with 27 additions and 8 deletions
+3 -1
View File
@@ -1,4 +1,4 @@
AGENT API DOCUMENT Started: 2008-07-03 Updated: 2024-04-27
AGENT API DOCUMENT Started: 2008-07-03 Updated: 2024-04-29
This document describes the functions of an API(Application Programming Interface)
for the VICIDIAL Agent screen. This functionality will be rather limited at first
@@ -668,6 +668,8 @@ VALUES:
GRAB_CUSTOMER - grab customer from the park extension and send them to the agent session
PARK_IVR_CUSTOMER - send customer to the park ivr as defined in the campaign the agent is logged into, customer will come back after finishing IVR
GRAB_IVR_CUSTOMER - grab customer from the park ivr and send them to the agent session
PARK_XFER - send third party call to the park extension as defined in the campaign the agent is logged into
GRAB_XFER - grab third party call from the park extension and send them to the agent session
EXAMPLE URLS:
http://server/agc/api.php?source=test&user=6666&pass=1234&agent_user=1000&function=park_call&value=PARK_CUSTOMER
+4 -3
View File
@@ -115,10 +115,11 @@
# 240219-1500 - Added daily_limit setting to change_ingroups function
# 240425-1901 - Added md_check option for transfer_conference function
# 240427-0809 - Added tw_check option for transfer_conference function
# 240429-2220 - Added PARK_XFER|GRAB_XFER options for park_call function
#
$version = '2.14-80';
$build = '240427-0809';
$version = '2.14-81';
$build = '240429-2220';
$php_script = 'api.php';
$startMS = microtime();
@@ -3897,7 +3898,7 @@ if ($function == 'send_dtmf')
################################################################################
if ($function == 'park_call')
{
if ( (strlen($value)<10) or ( (strlen($agent_user)<1) and (strlen($alt_user)<2) ) )
if ( (!preg_match("/PARK_CUSTOMER|GRAB_CUSTOMER|PARK_IVR_CUSTOMER|GRAB_IVR_CUSTOMER|PARK_XFER|GRAB_XFER/",$value)) or ( (strlen($agent_user)<1) and (strlen($alt_user)<2) ) )
{
$result = _QXZ("ERROR");
$result_reason = _QXZ("park_call not valid");
+13 -2
View File
@@ -155,10 +155,11 @@
# 230418-1022 - Added dial_override_limit options.php setting
# 230726-0857 - Fix for rare vicidial_closer_log issue on Voicemail transfers
# 240420-2233 - ConfBridge code added
# 240430-1046 - Allow for park/grab of xfer line through API
#
$version = '2.14-102';
$build = '240420-2233';
$version = '2.14-103';
$build = '240430-1046';
$php_script = 'manager_send.php';
$mel=1; # Mysql Error Log enabled = 1
$mysql_log_count=161;
@@ -1775,6 +1776,11 @@ if ($ACTION=="RedirectToParkXfer")
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02141',$user,$server_ip,$session_name,$one_mysql_log);}
$ACTION="Redirect";
$stmt="UPDATE vicidial_live_agents SET external_park='' where user='$user';";
if ($format=='debug') {echo "\n<!-- $stmt -->";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02091',$user,$server_ip,$session_name,$one_mysql_log);}
# $fp = fopen ("./vicidial_debug.txt", "a");
# fwrite ($fp, "$NOW_TIME|MS_LOG_0|$queryCID|$stmt|\n");
# fclose($fp);
@@ -1811,6 +1817,11 @@ if ($ACTION=="RedirectFromParkXfer")
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02142',$user,$server_ip,$session_name,$one_mysql_log);}
$ACTION="Redirect";
$stmt="UPDATE vicidial_live_agents SET external_park='' where user='$user';";
if ($format=='debug') {echo "\n<!-- $stmt -->";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02091',$user,$server_ip,$session_name,$one_mysql_log);}
}
}
}
+7 -2
View File
@@ -739,10 +739,11 @@
# 240415-1852 - Added script_tab_height campaign option
# 240416-1750 - Fix for HotKey issue #1518
# 240420-2228 - ConfBridge code added
# 240429-2237 - Added PARK_XFER|GRAB_XFER options for park_call API function
#
$version = '2.14-705c';
$build = '240420-2228';
$version = '2.14-706c';
$build = '240429-2237';
$php_script = 'vicidial.php';
$mel=1; # Mysql Error Log enabled = 1
$mysql_log_count=103;
@@ -8273,6 +8274,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{mainxfer_send_redirect('ParKivr',lastcustchannel,lastcustserverip);}
if (api_parkcustomer == 'GRAB_IVR_CUSTOMER')
{mainxfer_send_redirect('FROMParKivr',lastcustchannel,lastcustserverip);}
if (api_parkcustomer == 'PARK_XFER')
{mainxfer_send_redirect('ParKXfeR',lastxferchannel,server_ip,'','','','YES');}
if (api_parkcustomer == 'GRAB_XFER')
{mainxfer_send_redirect('FROMParKXfeR',lastxferchannel,server_ip,'','','','YES');}
if (api_dtmf.length > 0)
{
var REGdtmfPOUND = new RegExp("P","g");