Setup
← DashboardEvery collector uploads to with its own API key. Create one key per device or browser below, then follow that collector's steps. You only see a key once.
Devices and API keys
Browser (Violentmonkey)
Records time on the focused tab, per site (tab_focus, labelled by hostname). A tab counts only while it's the selected tab of the focused browser window, and it stops counting after 5 minutes without input unless video or audio is playing.
- Create a key with kind
browser. Use one key per browser, e.g.laptop-firefox. - Install Violentmonkey: Firefox · Chrome / Chromium.
- Open and click Install. Violentmonkey checks this URL for updates.
- Click the Violentmonkey toolbar icon, then Activity Tracker → Set server and API key. Enter
and the key. - Check it: Status / upload now in the same menu shows the queue and the last upload. Browse for a few minutes and the site appears on the dashboard.
Other menu options turn full URLs and page titles on or off (both off by default), set a regexp of hosts to ignore, and change the idle timeout. Browser pages such as about: and the new tab page, extension stores and the PDF viewer can't run scripts, so they aren't recorded. Hyprland still counts them as browser time.
Hyprland desktop
Records the focused window (app_focus, labelled by window class, with the title), plus idle and locked time.
- Create a key with kind
hyprland. - Build and install the agent from a clone of the repo:
git clone ssh://git@stppi.tailf20278.ts.net:2222/adamf/ccp.git && cd ccp make install-agent # ~/.local/bin/hypr-agent and the systemd user unit
- Configure it:
mkdir -p ~/.config/hypr-agent cat > ~/.config/hypr-agent/env <<EOF TRACKER_URL= TRACKER_API_KEY=trk_… # HYPR_AGENT_TITLES=false # don't send window titles at all # HYPR_AGENT_REDACT=(?i)bank|private # replace matching titles with [redacted] EOF chmod 600 ~/.config/hypr-agent/env systemctl --user enable --now hypr-agent - To record idle and locked time, add this to
~/.config/hypr/hypridle.conf:general { lock_cmd = hypr-agent lock; pidof hyprlock || hyprlock unlock_cmd = hypr-agent unlock } listener { timeout = 300 on-timeout = hypr-agent idle on-resume = hypr-agent resume } - Check it:
journalctl --user -u hypr-agent -f. Events upload every minute and wait in~/.local/state/hypr-agent/buffer.jsonlwhile the server can't be reached.
Apple Health
Walks, runs and other workouts become activities; step counts, sleep and other metrics become samples.
- Create a key with kind
health. - In the Health Auto Export iOS app, create a REST API automation:
- URL:
/api/v1/health/hae - Header:
Authorization=Bearer trk_… - Format: JSON
- Data: Workouts, plus metrics such as Step Count and Sleep Analysis
- Sync cadence: hourly
- URL:
Manual events and scripts
Any script can post intervals with a manual key:
curl -X POST /api/v1/manual/events \
-H 'Authorization: Bearer trk_…' -H 'Content-Type: application/json' \
-d '{"events":[{"id":"run-2026-10-14","kind":"reading","label":"book",
"started_at":"2026-10-14T20:00:00Z","ended_at":"2026-10-14T20:45:00Z"}]}'
The id makes re-sending safe: a duplicate is ignored. Webcam presence (/api/v1/presence/events) has an endpoint but no agent yet.
Goals
Goals are daily targets checked on the dashboard. Manage them on the Pi:
docker exec activity-tracker tracker goal add --kind tab_focus --label youtube.com --op '<=' --target 1h docker exec activity-tracker tracker goal add --kind walk --op '>=' --target 30m # empty label = any walk docker exec activity-tracker tracker goal list docker exec activity-tracker tracker goal rm --id 2