Hosted Runs
Hosted runs let agents do longer work while todos.md keeps status, logs, and artifacts.
Lifecycle
- Create a run.
- Queue it with an organization scope.
- Let a worker claim it with a lease.
- Keep the lease alive with heartbeats.
- Recover expired leases or timed out work.
- Review logs and artifacts.
List runs
platform-todos runs listCreate a run
platform-todos runs create example-capability --body '{"goal":"ship"}' --max-attempts 2 --timeout-ms 900000Worker lifecycle
Workers use the hosted API or MCP tools to claim one queued run, report heartbeats, and let todos.md requeue or fail work when the lease or timeout expires.
Claim next run
platform-todos api post /api/v1/runs/claim --body '{"workerId":"worker-a","leaseMs":30000}'Heartbeat
platform-todos api post /api/v1/runs/<run-id>/heartbeat --body '{"workerId":"worker-a","leaseMs":30000}'Artifact layout
Each run can export files:
.todos/
exports/
run_01hy...
manifest.json
receipt.json
result.json
Async status
Long jobs should be resumable by run id.
Check status
platform-todos runs show <run-id>Read logs
platform-todos runs logs <run-id>List artifacts
platform-todos runs artifacts <run-id>