Added PJSIP option for add_phone & update_phone in Non-Agent API
git-svn-id: svn://192.168.202.10@4023 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2026-08-22
|
||||
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2026-09-07
|
||||
|
||||
This document describes the functions of an API(Application Programming
|
||||
Interface) for all functions NOT directly relating to the VICIDIAL Agent screen.
|
||||
@@ -237,6 +237,7 @@ Changes:
|
||||
260506-1525 - small fix for campaign changes
|
||||
260519-1647 - Code updates for PHP8 compatibility, and json output format
|
||||
260822-0841 - Added agent_ingroup_availability function
|
||||
260907-1702 - Added PJSIP option for add_phone & update_phone
|
||||
|
||||
|
||||
API Functions use the 'function' variable
|
||||
@@ -1861,7 +1862,7 @@ voicemail_id - 1-10 digits
|
||||
phone_login - 1-20 characters
|
||||
phone_pass - 1-20 characters
|
||||
server_ip - 7-15 characters, must be a valid server_ip
|
||||
protocol - Must be one of these: 'IAX2','SIP','Zap','EXTERNAL'
|
||||
protocol - Must be one of these: 'IAX2','SIP','PJSIP','Zap','EXTERNAL'
|
||||
registration_password - 1-20 characters
|
||||
phone_full_name - 1-50 characters
|
||||
local_gmt - timezone setting, not adjusting for DST, default: '-5.00'
|
||||
@@ -1912,7 +1913,7 @@ dialplan_number - 1-20 digits
|
||||
voicemail_id - 1-10 digits
|
||||
phone_login - 1-20 characters
|
||||
phone_pass - 1-20 characters
|
||||
protocol - Must be one of these: 'IAX2','SIP','Zap','EXTERNAL'
|
||||
protocol - Must be one of these: 'IAX2','SIP','PJSIP','Zap','EXTERNAL'
|
||||
registration_password - 1-20 characters
|
||||
phone_full_name - 1-50 characters
|
||||
local_gmt - timezone setting, not adjusting for DST, default: '-5.00'
|
||||
|
||||
@@ -232,10 +232,11 @@
|
||||
# 260611-2256 - Fix for input variable filtering
|
||||
# 260822-0841 - Added agent_ingroup_availability function
|
||||
# 260902-1709 - Fix for PJSIP
|
||||
# 260907-1702 - Added PJSIP option for add_phone & update_phone
|
||||
#
|
||||
|
||||
$version = '2.14-207';
|
||||
$build = '260902-1709';
|
||||
$version = '2.14-208';
|
||||
$build = '260907-1702';
|
||||
$php_script='non_agent_api.php';
|
||||
$api_url_log = 0;
|
||||
$camp_lead_order_random=1;
|
||||
@@ -6129,7 +6130,7 @@ if ($function == 'add_phone')
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( (strlen($extension)<2) or (strlen($dialplan_number)<2) or (strlen($voicemail_id)<1) or (strlen($phone_login)<1) or (strlen($phone_pass)<1) or (strlen($server_ip)<1) or (strlen($protocol)<1) or (strlen($registration_password)<1) or (strlen($phone_full_name)<1) or (strlen($local_gmt)<1) or (strlen($outbound_cid)<1) or ( ($protocol != 'IAX2') and ($protocol != 'SIP') and ($protocol != 'Zap') and ($protocol != 'EXTERNAL') ) )
|
||||
if ( (strlen($extension)<2) or (strlen($dialplan_number)<2) or (strlen($voicemail_id)<1) or (strlen($phone_login)<1) or (strlen($phone_pass)<1) or (strlen($server_ip)<1) or (strlen($protocol)<1) or (strlen($registration_password)<1) or (strlen($phone_full_name)<1) or (strlen($local_gmt)<1) or (strlen($outbound_cid)<1) or ( ($protocol != 'IAX2') and ($protocol != 'SIP') and ($protocol != 'PJSIP') and ($protocol != 'Zap') and ($protocol != 'EXTERNAL') ) )
|
||||
{
|
||||
$result = 'ERROR';
|
||||
$result_reason = "add_phone YOU MUST USE ALL REQUIRED FIELDS";
|
||||
@@ -6526,7 +6527,7 @@ if ($function == 'update_phone')
|
||||
}
|
||||
if (strlen($protocol) > 0)
|
||||
{
|
||||
if ( ($protocol != 'IAX2') and ($protocol != 'SIP') and ($protocol != 'Zap') and ($protocol != 'EXTERNAL') )
|
||||
if ( ($protocol != 'IAX2') and ($protocol != 'SIP') and ($protocol != 'PJSIP') and ($protocol != 'Zap') and ($protocol != 'EXTERNAL') )
|
||||
{
|
||||
$result = 'ERROR';
|
||||
$result_reason = "update_phone YOU MUST USE A VALID PROTOCOL";
|
||||
|
||||
Reference in New Issue
Block a user