Added agent_status function to the non-agent API

git-svn-id: svn://192.168.202.10@1953 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2013-04-05 21:11:09 +00:00
parent 38001880d9
commit a807133d73
3 changed files with 194 additions and 3 deletions
+35 -1
View File
@@ -1,4 +1,4 @@
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2013-03-28
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2013-04-05
This document describes the functions of an API(Application Programming
Interface) for all functions NOT directly relating to the VICIDIAL Agent screen.
@@ -33,6 +33,7 @@ update_list - updates list settings in the system, reset leads in list, delete l
add_group_alias - adds group alias to the system
user_group_status - real-time status of one or more user groups
in_group_status - real-time status of one or more in groups
agent_status - real-time status of one user
New scripts:
@@ -79,6 +80,7 @@ Changes:
121116-1938 - Added state call time restrictions to add_lead hopper insert function
121125-2210 - Added Other Campaign DNC option and list expiration date option
130328-0949 - Added update_phone_number option to update_lead function
130405-1538 - Added agent_status function
@@ -394,6 +396,38 @@ SALESLINE SUPPORT,31,0,75,54,0,20,1
--------------------------------------------------------------------------------
agent_status - real-time status of one agent user
NOTE: api user for this function must have user_level set to 7 or higher and "view reports" enabled
REQUIRED FIELDS-
source - description of what originated the API call (maximum 20 characters)
agent_user - 2-20 characters, use only for one agent status
SETTINGS FIELDS-
stage - the format of the exported data: csv, tab, pipe(default)
header - include a header(YES) or not(NO). This is optional, default is not to include a header
NOTES-
There is a hard limit of 10000000 records analyzed
Example URL strings for API calls:
http://server/vicidial/non_agent_api.php?source=test&user=6666&pass=1234&function=agent_status&agent_user=1234&stage=csv&header=YES
Example responses:
ERROR: agent_status USER DOES NOT HAVE PERMISSION TO GET AGENT INFO - 6666|0
ERROR: agent_status INVALID SEARCH PARAMETERS - 6666||
ERROR: agent_status AGENT NOT FOUND - 6666||
ERROR: agent_status AGENT NOT LOGGED IN - 6666||
A SUCCESS response will not show "SUCCESS", but instead will just print the results in the following format:
status,call_id,lead_id,campaign_id,calls_today,full_name,user_group,user_level
INCALL,M4050908070000012345,12345,TESTCAMP,12,Test Agent,AGENTS,3
--------------------------------------------------------------------------------
update_log_entry - updates the status of a vicidial_log or vicidial_closer_log entry