Skip to content

Heartbeat

A heartbeat is a per-domain scheduled routine that keeps a domain alive without you opening it — re-score it on a cadence, run a weekly pulse, alert you when context goes stale. Routines are declared in each domain’s manifest.json (manifest.heartbeat) and installed by the engine into the OS scheduler (cron on Linux, launchd on macOS).

Terminal window
prevail heartbeat install --json

Installs the OS scheduler hooks for all enabled domain heartbeat routines. The engine returns the ids it wired up:

{ "ok": true, "installed": ["wealth-op-weekly-pulse", "health-op-daily-check"] }
Terminal window
prevail heartbeat status --json

Reports whether the hooks are installed and the state of every routine — schedule, enabled flag, last run, next run:

{ "ok": true,
"installed": true,
"routines": [
{ "domain": "wealth", "id": "wealth-op-weekly-pulse",
"schedule": "weekly mon 08:00", "enabled": true,
"lastRun": 1749220200000, "nextRun": 1749825000000 } ] }

Prevail has three scheduling surfaces, from highest- to lowest-level:

SurfaceScopeDeclared in
HeartbeatPer-domain routines (re-score, pulse, staleness alert)manifest.heartbeat
BriefingsScheduled domain briefings (council or single, delivered to log/Telegram).briefings.json
ScheduleArbitrary recurring prevail commands.schedule.json

Run heartbeats on the always-on machine that holds your vault — the same machine you’d run the Telegram daemon on. Both lastRun/nextRun are epoch-millisecond machine fields per the JSON API conventions.