Skip to main content
Glama

AI SENSE Free Public Tools

Claim agent queue job

claim_agent_queue_job

Claim the next pending job using the worker token. Returns job:null immediately when no work is available, otherwise a job containing a new secret receipt. Visibility defaults to 60 seconds and accepts 30-900 seconds. Redelivery is possible: make worker side effects idempotent. Jobs fail after 5 unsuccessful claims. No job is executed by the server.

Input Schema

NameRequiredDescriptionDefault
queue_idYesThe queue_id from create_agent_queue, or from create_agent_run for a run with delegated steps.
worker_tokenYesThe worker_token from create_agent_queue or create_agent_run, shown once. It claims jobs and acknowledges, renews or releases them.
visibility_timeoutNoClaim visibility in seconds, capped by the fixed queue expiry.

Output Schema

NameRequiredDescriptionDefault
okYes
jobYes
queue_idYes
expire_timestampYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / queue_id / description
      Added value: +"The queue_id from create_agent_queue, or from create_agent_run for a run with delegated steps."
    • addedInput schema / properties / worker_token / description
      Added value: +"The worker_token from create_agent_queue or create_agent_run, shown once. It claims jobs and acknowledges, renews or releases them."
  2. Added

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the annotations it discloses several non-obvious traits: an immediate null return when the queue is empty, a new secret receipt embedded in the returned job, at-least-once delivery requiring idempotent worker side effects, a five-failed-claim failure threshold, and the fact that the server never executes the job. These are exactly the behaviors an agent must know before polling in a loop.

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

Conciseness5/5

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

Five short sentences, front-loaded with the purpose, then the return shape, then the timeout rule, then delivery semantics and failure threshold. No filler and nothing that could be dropped without losing an operational fact.

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?

For a claim/poll tool with an output schema present, the description covers the empty-result case, receipt issuance, visibility window, redelivery, and failure threshold — everything an agent needs to call it correctly and handle the response. No material gap remains.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents all three parameters including patterns and min/max. The description's visibility-timeout sentence (default 60, range 30-900) restates what the schema declares rather than adding new meaning, so it sits at the baseline.

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 specific verb and resource ("Claim the next pending job") plus the credential used ("worker token"), which cleanly separates it from siblings like read_agent_queue_job, ack_agent_queue_job, renew_agent_queue_job and release_agent_queue_job. An agent can identify the operation without opening the schema.

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

Usage Guidelines4/5

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

The description gives clear operational context for when to call it (poll for the next pending job) and what to do when the result is empty (job:null means no work). It does not explicitly name alternatives or exclusions, e.g. when to prefer read_agent_queue_job over claiming, so it stops short of full routing guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.