tasks_claim
Claim a task for the current session, moving it to in_progress with a lease. Refusals name the cause—held, blocked, or closed—so you can act.
Instructions
Atomically claim a task for the current session, moving it to in_progress with a lease. A refused claim names its cause: held by another live claim ('task already claimed'), waiting on unfinished dependencies ('task blocked', naming the blockers -- finish those first), or already done/dropped ('task closed'). Re-claiming a task you already hold refreshes (heartbeats) the lease; a task whose lease has expired can be reclaimed. Release it with tasks_release or by closing it (tasks_update done/dropped); session_end releases all of a session's claims.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | task id to claim | |
| session | No | the acting agent's session: the cc/<id> or cx/<id> on your briefing's 'Seam session' line, another session name, or a session ULID. Defaults to this connection's session -- bound automatically for Claude Code and Codex agents -- then a sole active ambient. Pass it when a call reports the agent as ambiguous: the bare call then fails rather than guesses. | |
| session_id | No | the acting agent's session ULID; takes precedence over session and the bound session | |
| lease_seconds | No | lease duration in seconds before the claim lapses and the task becomes reclaimable (default 900) |