My Data

Get most recent heartbeat

Returns the most recent heartbeat for the authenticated user. Useful for checking if the user is currently active. Authenticate with an OAuth access token with the read scope or an API key as a Bearer token in the Authorization header (HTTP Basic auth with the API key is also accepted).

get/api/v1/my/heartbeats/most_recent

Query parameters

source_typestring

Filter by source type (e.g. "direct_entry"). If omitted, results exclude heartbeats with source_type "test_entry" by default.

editorstring

Filter by editor name (e.g. "VSCode"). Matched case-insensitively.

Response

successful

has_heartbeatboolean required

Whether a matching heartbeat was found.

heartbeatobject nullable required

The most recent matching heartbeat, or null when none is found.

editorstring nullable required

Editor of the matching heartbeat, or null.

time_agostring nullable required

Human-readable time since the heartbeat (e.g. "5 minutes ago"), or null.

Example response

{
  "has_heartbeat": true,
  "editor": "VS Code",
  "time_ago": "5 minutes ago"
}

Changes