Viewing the statistical data
Server statistics details
GET https://service.whatap.io/open/json/stat/sm_stat?stitme
&etime
&filter
&oid
command
$ curl -L -w "\n" -H "x-whatap-token: {{PROJECT API TOKEN}}" -H "x-whatap-pcode: {{projectCode}}" "https://service.whatap.io/open/json/stat/sm_stat?stime=startUTC&etime=endUTC&filter=m5&oid=0"
Parameter | Description |
---|---|
stime | Start time UTC (UNIX epoch time, millisecond) |
etime | End time UTC (UNIX epoch time, millisecond) |
filter | Automatic setting of m5 by default; if 5-minute statistics are fetched within the time range, m5 is used. For 5-second statistics, s5 is used and for 1-hour statistics, h1 is used. |
oid | Add if monitoring is required for a specific server. |
Note
- Search time (
stime
,etime
) is limited to one hour, and its unit is in ms (millisecond). - Parameters other than
oid
are not allowed.
response
{
"servers":[
{
"oid": -1030311093 ,
"timeData":[
{
"usedPercent": 69.1,
"trafficIn": 12113.57,
"trafficOut": 24781.08,
"cpu": 4.08,
"memory_swappused": 15.41,
"time": 1572341400000,
"memory_pused": 47.6,
"ioPercent": 0.26
},
{
"usedPercent": 69.1,
"trafficIn": 12183.97,
"trafficOut": 25600.59,
"cpu": 7.89,
"memory_swappused": 15.5,
"time": 1572341700000,
"memory_pused": 47.79,
"ioPercent": 0.22
},
(...)
],
},
(...)
]
}