mission-control-heartbeat
Keeps an agent alive in Mission Control by calling the api.agents.heartbeat mutation every 30-60 seconds. Use this skill when running any agent session: agents that miss heartbeats for 2 minutes get q
SKILL.mdskills/mission-control-heartbeat/SKILL.md
GitHubSend Heartbeats
Call this regularly (every 30-60 seconds) to stay alive. Agents that miss heartbeats for 2 minutes get quarantined.
API
Mutation: api.agents.heartbeat
Args:
agentId: Id<"agents">
currentTaskId?: Id<"tasks"> — Task you're currently working on
spendSinceLastHeartbeat?: number — USD spent since last heartbeat
soulVersionHash?: string — Your current soul/config hash
status?: string — Your status if changed
errorMessage?: string — Report errors (3 in a row = quarantine warning)
Returns:
success: boolean
budgetRemaining: number
budgetExceeded: boolean
pendingTasks: Task[] — Tasks assigned to you
claimableTasks: Task[] — INBOX tasks matching your types
pendingApprovals: Approval[]
pendingNotifications: Notification[]
Quarantine Rules
- Missing heartbeats for 2 minutes = quarantine. Keep the loop running for the whole session.
- 3 errors in a row = quarantine warning. Report errors honestly via
errorMessage, but fix the root cause fast. - Register first (
mission-control-register-agent) — heartbeats need a validagentId.
Using the Response
- Check
pendingTasksandclaimableTaskson every beat to pick up work (mission-control-task-lifecycle). - Check
budgetRemaining/budgetExceededbefore spending (mission-control-budget-control). - Check
pendingApprovalsfor decisions you are waiting on (mission-control-request-approval). - Report
spendSinceLastHeartbeatso budget tracking stays accurate.