REST API (ACD Info)

Get List of ACDs

After logging into the PBX and getting the session Id (either admin or domain admin), you can use the following API to get the list of ACDs in a particular domain. This information is obtained from an extension account in the domain (given below in the example as user@mydomain) which has been set as "Queue manager" for the ACDs.

Method:  POST

URL:  https://PBXURL/rest/user/user@mydomain/wallboard

Return:  List of ACDs

Example:

POST https://192.168.1.11/rest/user/45@example/wallboard

Returns:

[{display: "Marketing", name: "73"}, {display: "Sales", name: "80"}]

JSON object break down:

Array(2):

0:{display: "Marketing", name: "73"}
1:{display: "Sales", name: "80"}

 

Get Live Information about an ACD

After logging into the PBX and getting the session Id (either admin or domain admin), you can use the following API to get the the live information and status of an ACD in a particular domain. This information is obtained from an extension account in the domain (given below in the example as user@mydomain) which has been set as "Queue manager" for that ACD.

Method:  POST

URL:  https://PBXURL/rest/user/user@mydomain/wallboard/ACD-ACCOUNT

Return:  ACD information as JSON

Example:

POST https://192.168.1.11/rest/user/45@example/wallboard/73

Returns:

{acds: {…}, logged_agents: Array(3), agents: Array(3), current: Array(0), history: Array(3)}

 

JSON object break down:

acds: 

         73: Object
               calls: {count: 3, completed: 1}
               duration: {sum: {…}, average: {…}}
               exit: {user: 0, admin: 0, application: 0, other: 0}
               hangup: {waiting: 2, ringing: 0}
               redirect: {waiting: 0, ringing: 0, anonymous: 0}

         agents: Array(3)

            0:
               account:"40"
               average:{talk: 0, hold: 0, idle: 0}
               calls:0
               dnd:false
               duration:{talk: 0, hold: 0, idle: 0}
               jumpin:true
               name:"Jeff McCormick"
               work:{begin: 1546578000, end: 1546664400, now: 1546619595.65, segments: Array(0)}

             1:{account: "43", name: "Penny Cooper", dnd: false, jumpin: true, work: {…}, …}
             2:{account: "42", name: "Kyle Mason", dnd: false, jumpin: true, work: {…}, …}

         current: []
         history: Array(3)
            0:{start: "1546619207.836", from: ""Jeff McCormick" <sip:40@localhost>", duration: 0, agent: ""}
            1:{start: "1546619244.462", from: ""Jeff McCormick" <sip:40@localhost>", duration: 0, agent: ""}
            2:{start: "1546619595.631", from: ""Jeff McCormick" <sip:40@localhost>", duration: 18, agent: "43"}

         logged_agents: Array(3)
            0:40
            1:42
            2:43