listAllCalls

This application returns list of calls in any state. Calls are limited to those belonging to the current customer. Root customer receives full list.


Parameters:

  • recursive - Should the calls of subcustomers be included in the returned list (new in post 1.7.1). Boolean. Optional. Default: True
  • i_customer - Return only calls which belong to the specified sub-customer. Available only in trusted mode. Integer. (Available since 5.3)
  • i_account - Return only calls which belong to the specified account. Integer. Optional. (Available since 5.3)
  • i_vendor - Return only calls which are currently routed via a connection belonging to the specified vendor. Integer. Optional. (Available since 5.3)
  • i_connection - Return only calls which are currently routed via the specified connection. This parameter takes precedence over the i_vendor parameter. Integer. Optional. (Available since 5.3)


Trusted Mode:

In trusted mode the i_customer integer parameter can be used to specify under which access rights this application should execute.

Returns:

  • list of dictionaries. Here is an example of returned value in Python syntax:


     [
       {
         'B2BUA_TAG' : '',
         'CLI' : '801',
         'I_CONNECTION' : 1,
         'CLD' : '812',
         'CALL_ID' : 'd84b2a8b-44f79741@192.168.0.11',
         'DELAY' : 2,
         'DURATION' : 0,
         'CC_STATE' : 'ARComplete',
         'I_ACCOUNT' : 3,
         'ID' : '960',
       {
         'CALLER_MEDIA_IP' : '192.168.22.7',
         'CALLEE_MEDIA_IP' : '192.168.22.54'
       },
       },
       {
         'B2BUA_TAG' : '2',
         'CLI' : '10545',
         'I_CONNECTION' : 1,
         'CLD' : '123456',
         'CALL_ID' : 'c80634fb-6f7ad6fd@192.168.0.22',
         'DELAY' : 2,
         'DURATION' : 10,
         'CC_STATE' : 'Connected',
         'I_ACCOUNT' : 223,
         'ID' : '944',
       {
         'CALLER_MEDIA_IP' : '192.168.22.2',
         'CALLEE_MEDIA_IP' : '192.168.22.49'
       },
       }
     ]



  • XMLRPC fault in case of any error.

Data types of values in the dictionary:


B2BUA_TAG
String
CLI
String
I_CONNECTION
Integer
CLD
String
CALL_ID
String
DELAY
Integer
DURATION
Integer
CC_STATE
String
I_ACCOUNT
Integer
ID
String
CALLER_MEDIA_IP*
String in Array
CALLEE_MEDIA_IP*
String in Array
DIRECTION **
String


* Available since 5.0 version.

** Available since 5.2 version.


     listActiveCalls

This is the same as the listAllCalls application, but returns the call list containing calls in states Connected, ARComplete or WaitRoute? only.


     disconnectCall

This application is used to disconnect an active call.


Parameters:

  • ID - ID of the call to disconnect (see the listAllCalls application). String. Required.

Returns:

  • result - OK means that disconnect request was sent successfully
  • result - Call not found or not accessible - means that disconnect cannot be initiated
  • XMLRPC fault in case of any error.

     disconnectAccount (new in post 1.7.1)

This application is used to disconnect all active calls of a given account. 


Top level customer could also issue this API call for any account in his hierarchy, including accounts of his subcustomers.


Parameters:

  • i_account - Integer. Required.

Returns:

  • result - OK means that disconnect request was sent successfully
  • count - number of disconnected sessions
  • XMLRPC fault in case of any error.

     getAccountCallStats (new in 2.1)

This application is used to get aggregated statistics of active calls in the softswitch. This is a lightweight API call and it is recommended to be used instead of listAllCalls() or listActiveCalls() when summary only is needed.


Parameters:

None

Returns:

  • result - OK
  • data - dictionary of the following format:

    {
i_account1 : [ <total calls>, <connected calls> ],
i_account2 : [ <total calls>, <connected calls> ],
    }

  • XMLRPC fault in case of any error.

     disconnectCustomer (since 5.2)

This application is used to disconnect all active calls of a given customer. All calls of accounts that belong to the customer and all descendant subcustomers will be dropped.

Top level customer could also issue this API call for any subcustomer in his hierarchy, including customers of his subcustomers.


Parameters:

  • i_customer - ID of customer. Integer. Required.


Trusted mode:

In trusted mode the i_wholesaler integer parameter can be used to specify under which access rights this application should execute.


Returns:

  • result - OK means that all calls were disconnected successfully
  • count - number of disconnected calls
  • XMLRPC fault in case of any error