Call Statistics from Sonus UX 1000/2000 using the RESTful API

We all love statistics

Posted on August 06, 2015


Challenged to collect call statistics from our Sonus UX 1000 SBC the first thought was to use SNMP. After enabling SNMP and pointing an SNMPwalk tool with MIB to the SBC, I struggled to find anything useful that could be used by our monitoring software with its native SNMP sensor. Why taunt me with your call counters in the web administration interface and not expose them through SNMP?

My colleagues have been using the Sonus UX REST API and PowerShell to load up configurations when deploying so thought I’d give it a go. Not much browsing time later and I had the API calls needed:

This is what I ended up with.

The Script

Nothing much to it.

.\Get-SonusUxCallCounters.ps1 -Username "restuser" -Password "restpassword" -ServerFqdn "" -Type SIP -Id 1

Type can be SIP, ISDN or CAS.


Choose the “EXE/Script Advanced” sensor type and fill in the settings:


I’ve used the Linux username and password of the parent device to pass through the REST credentials.

A little while later…



Guess everyone went home around 5.30 :)


That’ll keep the boss entertained.


Downoad Get-SonusUxCallCounters.ps1