Wowza Community

Problem with REST AP Ifor historic data

Good morning all,

I have just started to play with the wowza REST API and I am interested, in particular, in the

historic data such as /v2/servers/defaultServer/monitoring/historic and /v2/servers/defaultServer/vhosts/defaultVHost/applications/live/monitoring/historic

I noticed that, sometimes, the “actual” array is empty (on the contrary, the “min”, “max” and

the “average” arrays are always set).

Maybe I am missing the meaning of this array? Is it expected to be empty?

thank you very much

Bruno

Hello Bruno,

The REST API command for historic monitoring is outlined in this tutorial:

https://www.wowza.com/docs/statistics-query-examples#historicalstats

Here’s a description of the returned array:

index 0 = Bandwidth Usage coming Into the application in KB/s (where 1024 bytes per KB)
index 1 = Bandwidth Usage going out of the application in KB/s (where 1024 bytes per KB)
index 2 = RTMP Connection Count in and out of the application
index 3 = RTSP Connection Count in and out of the application
index 4 = HDS Connection Count in and out of the application
index 5 = HLS Connection Count in and out of the application
index 6 = SmoothStreaming Connection Count in and out of the application
index 7 = WEB RTC Connection Count in and out of the application
index 8 = WEM Connection Count in and out of the application
index 9 = DASH Connection Count in and out of the application

If you are still seeing an empty array please do submit a Support ticket so that we can investigate this issue.

Regards,

Jason Hatchett

Hi Bruno,

You would also need to ensure you are passing date parameters with your REST API command, and that there is historic data for that period.

curl -X GET --header 'Accept:application/json; charset=utf-8' "http://localhost:8087/v2/servers/_defaultServer_/vhosts/_defaultVHost_/applications/testlive/monitoring/historic?start=2015-11-01T15:00:00&end=2015-11-01T15:01:00"

Michelle

Hi, where is the documentation for the date parameter and how exactly to define that date? Does it have to be in UTC?

Also the linked documentation is not what I get in a real live server - instead of a formated date I get java millies - is it possible to configure that output and if yes, where?

Thanks!

Hi John, the start/end date querystring parameters are not currently documented right now, but I have asked our Docs team to add it to our article. It would need to be in UTC, in the format yyyy-MM-ddTHH:mm:ss. You also need to make sure the URL, including the start and end parameters, are enclosed in quotes.

In order to receive the dateTime format similar to what is in the docs, do make sure that you are specifying the response to be in JSON format instead of XML.