Get Monitor Uptime
getMonitorUptimeRetrieve a monitor's uptime percentage, check counts, ping min/avg/max, and failed periods over a chosen time range to answer questions like "What was uptime this week?"
Instructions
Returns a monitor's uptime percentage, check counts and ping (min/avg/max) over the last N hours, up to a year, with the minutes, hours or days in which checks failed, newest first. Use it for "what was the uptime this week?"; for the current status use getMonitorSummary, and for individual checks listHeartbeats. Counted as Uptime Kuma counts them: PENDING is down, and MAINTENANCE is neither.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"monitorID": "<monitorID>"
},
"name": "getMonitorUptime"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hours | No | How far back, in hours (default: 24; e.g. 168 for a week, 720 for 30 days). Up to 24 is counted per minute, up to 720 per hour, beyond that per whole day. | |
| monitorID | Yes | The monitor to report on. Find IDs with listMonitors. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ping | Yes | ||
| hours | Yes | ||
| checks | Yes | ||
| monitorID | Yes | ||
| granularity | Yes | Size of each bucket in downtimeBuckets | |
| uptimePercent | Yes | up / (up + down) × 100; null when there were no checks | |
| downtimeBuckets | Yes | The newest 50 of them | |
| downtimeBucketCount | Yes | Buckets with at least one failed check |