Scheduling
Meerkat’s scheduler persists schedules and projects concrete occurrences from them.- A schedule is the durable rule: trigger + target + policies.
- An occurrence is one planned delivery produced from that rule.
- The driver claims due occurrences and delivers them to the target at runtime.
Host APIs vs agent tools
Use the typed host APIs when your application is managing schedules directly:- JSON-RPC:
schedule/create,schedule/list,schedule/get,schedule/update,schedule/pause,schedule/resume,schedule/delete,schedule/occurrences - REST:
POST /schedules,GET /schedules,GET /schedules/{id},PATCH /schedules/{id},POST /schedules/{id}/pause,POST /schedules/{id}/resume,DELETE /schedules/{id},GET /schedules/{id}/occurrences
meerkat_schedule_create, meerkat_schedule_get, and meerkat_schedule_occurrences.
Create a schedule
- JSON-RPC
- REST
- Rust SDK
Trigger types
Once
Fire one time at an exact UTC timestamp.Interval
Fire repeatedly at a fixed cadence.end_at_utc to stop the schedule automatically:
Calendar
Fire at named wall-clock times in a timezone. Omitted fields default to{"kind":"any"}.
Target types
Session targets
target_kind must be "session" with one of these type variants:
exact_session: deliver to one specific existing sessionresumable_session: deliver to a specific session that may be idle/suspendedmaterialize_on_demand_session: create a session on first fire, then reuse it
Mob targets
target_kind must be "mob" with one of these type variants:
member: deliver content to a specific mob memberflow: run a named mob flowspawn_helper: create a helper in a mob and wait for itfork_helper: fork from an existing member and wait for it
Policies
Misfire policy
What happens when an occurrence is materially late:{"type":"skip"}: skip overdue work after the grace window{"type":"catch_up_within","window_seconds":300}: catch up if still within the lateness window
Overlap policy
What happens when the next occurrence fires while previous work is still active:skip_if_running(recommended)allow_concurrent
Missing target policy
What happens when the target is missing at fire time:mark_misfired(recommended)skip
Recommended defaults
For most recurring jobs, start with:Schedule lifecycle
Schedule phase is intentionally small:activepauseddeleted
pendingclaimeddispatchingawaiting_completioncompletedskippedmisfiredsupersededdelivery_failed
schedule/occurrences or GET /schedules/{id}/occurrences to inspect what actually fired and why.
Agent-side schedule tools
When scheduling is exposed inside a running agent, the canonical tool names are:meerkat_schedule_createmeerkat_schedule_getmeerkat_schedule_listmeerkat_schedule_updatemeerkat_schedule_pausemeerkat_schedule_resumemeerkat_schedule_deletemeerkat_schedule_occurrences
schedule/* over RPC and /schedules/* over REST).
