Admin Utils
Get heartbeats matching a user_agent segment
Returns heartbeats whose user_agent contains the given substring (e.g. "Godot_Super-Wakatime/2.0.0"). Useful for monitoring how a specific editor/plugin behaves over time. Use count_only=true to avoid streaming rows when only the total is needed.
get/api/admin/v1/heartbeats/by_user_agent_segment
Query parameters
segmentstring required
Substring of user_agent to match (case-insensitive). Min length 3.
user_idstring
Optional user ID to scope the query to a single user.
start_datestring
Start date (YYYY-MM-DD or epoch seconds)
end_datestring
End date (YYYY-MM-DD or epoch seconds)
limitinteger
Page size (default 1000, max 5000)
offsetinteger
Pagination offset
count_onlyboolean
If true, return only total_count and skip row payload
Response
successful
Example response
{
"segment": "Godot_Super-Wakatime",
"limit": 10,
"heartbeats": [
{
"id": 987654,
"user_id": 42,
"time": 1710946200,
"project": "demo",
"language": "GDScript",
"entity": "res://player.gd",
"branch": "main",
"category": "coding",
"editor": "Godot",
"machine": "Orpheus-MacBook-Pro",
"operating_system": "Mac",
"user_agent": "Godot/4.2 Godot_Super-Wakatime/2.0.0",
"ip_address": "203.0.113.7",
"is_write": true,
"lineno": 42,
"cursorpos": 12,
"lines": 350,
"source_type": "direct_entry"
}
]
}