Skip to main content
Glama

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

NameRequiredDescriptionDefault
idYestask id to claim
sessionNothe 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_idNothe acting agent's session ULID; takes precedence over session and the bound session
lease_secondsNolease duration in seconds before the claim lapses and the task becomes reclaimable (default 900)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.7.4
    • changedInput schema / properties / session / description
      Previous value: -"the acting agent's session: the cc/<id> or cx/<id> on your briefing's 'Seam session' line, or a session name. Defaults to the connection's bound session, then a sole active ambient. Pass it whenever you have not run session_start and several agents are active -- the bare call is then ambiguous and fails rather than guesses."New value: +"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."
  2. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations (readOnlyHint=false, idempotentHint=false, destructiveHint=false) by disclosing atomicity, lease lifecycle (refresh on re-claim, expiry makes a task reclaimable), the literal refusal messages, and the release paths. That is exactly the behavioral context an agent needs to act on a failed claim.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and effect, and every sentence carries information. It is somewhat dense with nested parentheticals in the refusal-cause clause, which costs a little readability without wasting words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, so the description carries the return-side burden and does so: it names the success effect, every failure mode with its literal message, and the release/heartbeat cycles. Nothing an agent needs in order to call this correctly or interpret a refusal is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3; the description adds meaning by explaining how the lease behaves over time (heartbeat on re-claim, lapse then reclaim) and how releasing works, which contextualizes the lease_seconds and session parameters. It stops short of adding format or precedence detail for id/session beyond the schema text.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a precise verb+resource+state transition: 'Atomically claim a task for the current session, moving it to in_progress with a lease.' An agent can distinguish this from tasks_release, tasks_update, and tasks_ready without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It enumerates exactly when the call is refused and why ('task already claimed', 'task blocked', 'task closed'), tells the agent what to do about blockers ('finish those first'), and routes to the alternatives: tasks_release or tasks_update done/dropped for release, session_end for bulk release.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.