API reference

List heartbeat runs

List a heartbeat's recent runs with the Uptenna API: when each cron job run started and finished, how long it took, its exit code and output.

GET https://uptenna.com/v1/monitors/{id}/runs

A heartbeat's recent runs, newest first: start and finish times, duration, outcome, exit code and the output the job sent.

Path parameters

NameTypeRequiredDescription
idstringyesThe monitor's id (mon_…).

Query parameters

NameTypeRequiredDescription
limitintegerno1 to 100. Default 50.

Example request

curl
curl "https://uptenna.com/v1/monitors/mon_Q2fk8LtW5nVa/runs?limit=20" \
  -H "Authorization: Bearer $UPTENNA_API_KEY"
Node.js (fetch)
const res = await fetch("https://uptenna.com/v1/monitors/mon_Q2fk8LtW5nVa/runs?limit=20", {
  method: "GET",
  headers: {
    Authorization: `Bearer ${process.env.UPTENNA_API_KEY}`,
  },
});
if (!res.ok) throw new Error((await res.json()).error.message);
const { data } = await res.json();

Response

Returns 200 OK with data, a list of heartbeat run objects.

200 OK
{
  "data": [
    {
      "id": 4812,
      "started_at": "2026-12-01T08:00:02.000Z",
      "ended_at": "2026-12-01T08:03:41.000Z",
      "duration_ms": 219000,
      "state": "fail",
      "exit_code": 1,
      "message": "pg_dump: error: connection to server failed"
    }
  ]
}

Errors

Errors look like { "error": { "code", "message" } } (see Errors).

StatusCodeWhen
400invalid_parameterlimit isn't valid.
400not_heartbeatThe monitor is an HTTP monitor: only heartbeats have runs.
404not_foundNo monitor with this id in your account.
401unauthorizedThe Authorization header is missing, malformed, or the key is unknown or revoked.
429rate_limitedMore than 120 requests in 60 seconds with this key. Wait for the Retry-After header's seconds.