Get Heartbeat Event History

Retrieve the full event history for a specific heartbeat monitor by providing its heartbeat_id in the path. This endpoint returns a list of recorded heartbeat events, allowing you to track when check-ins were received and whether they were successful or missed.

You can use query parameters like limit to control the number of results and last_received_at to fetch events after a specific timestamp, which is useful for pagination or incremental analysis.

Use cases:
  • Incident analysis — Review missed heartbeats and their timestamps to understand when a job failed to report in.
  • System auditing — Verify whether jobs or scripts checked in during critical time windows.
  • Monitoring history — Build a timeline of all heartbeat events for visualization or reporting.


Authorization: Bearer YOUR_TOKEN


Path Parameters
  • id string
    The unique ID of the heartbeat for which events are being retrieved. Example: '47f84f9f-a742-4ef9-be40-e7d7a6fa4039'
Query Parameters
  • limit (optional) positive integer
    Specifies the maximum number of events to return, such as '10'. You can choose to include this parameter as needed.
  • last_received_at (optional) string
JavaScript
Response codes
const axios = require('axios');

const url = "https://statistic-query.api.pinghome.io/v1/heartbeat/47f84f9f-a742-4ef9-be40-e7d7a6fa4039/events?limit=10&last_received_at=2023-03-27T09:57:54Z";

axios.get(url, {
  headers: {
    'Authorization': 'Bearer YOUR_TOKEN',
    'Content-Type': 'application/json'
  }
})
.then(response => {
  console.log(response.data);
})
.catch(error => {
  console.error(error);
});
ResponseThis section is used to view the possible HTTP response codes returned by the API. These codes indicate the status of a request, such as 201 (Created), 401 (Unauthorized), 409 (Conflict), or 422 (Unprocessable Entity).