Skip to main content
Glama

MCPFax Agent Continuity

Give a work item back, or fail it for good

work_fail
DestructiveIdempotent

Report that an item did not work out. FREE. THIS IS ALSO THE CORRECT WAY TO HAND AN ITEM BACK WHEN NOTHING WENT WRONG — there is no work_release; retry:true (the default) returns it immediately for another worker instead of waiting out the lease. When its attempts are exhausted it is DEAD-LETTERED and SURFACED in work_status, never silently dropped. With retry:false it is marked permanently failed, stops consuming attempts, and CANNOT BE UNDONE. PASS fence: exactly like work_done, if your lease already expired and the item went back to the queue we REFUSE with lease_lost, a stale fence is refused as not_holder, and a fence-less call on an item that has been handed out more than once is refused as fence_required — because accepting it would let a revived worker dead-letter an item another worker is processing right now. FREE — this tool never charges. Authenticate with Authorization: Bearer , or pass agent_key as an argument if your host cannot set headers. Equivalent HTTP route: POST /v1/work/fail.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNoOptional short reason, <=512 chars, surfaced on the dead letter so a human can see WHY it exhausted. Example: 'upstream 503'.
fenceNoThe fence token from work_take, for THIS item. Checked exactly when supplied; when omitted we accept the call only while the item has been handed out exactly once, and otherwise refuse with fence_required. Every item on a queue draws its own token independently, so the fence you hold for one item is not one step away from the fence another worker holds for another. The example below is a shape, not a usable value. Example: '3170294857216913'.
retryNoPut it back for another attempt (default true), or fail it permanently (false). Example: 'true'.
item_idYesThe item you were given. Example: 'P-1'.
queue_idYesThe queue. Alias: job_id. Example: 'permit-batch-2026-08'.
agent_keyNoYour agent_secret, if your MCP host cannot set the Authorization header. Prefer the header.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / agent_key / examples
      Added value: +[
      +  "the agent_secret that register returned"
      +]
  2. Changed5 schema fields changed
    • addedInput schema / properties / error / examples
      Added value: +[
      +  "upstream 503"
      +]
    • addedInput schema / properties / fence / examples
      Added value: +[
      +  3170294857216913
      +]
    • addedInput schema / properties / item_id / examples
      Added value: +[
      +  "P-1"
      +]
    • addedInput schema / properties / queue_id / examples
      Added value: +[
      +  "permit-batch-2026-08"
      +]
    • addedInput schema / properties / retry / examples
      Added value: +[
      +  "true"
      +]
  3. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Adds substantial behavioral context beyond annotations: dead-lettering and surfacing in work_status, permanent failure when retry:false, 'CANNOT BE UNDONE', refusal codes (lease_lost, not_holder, fence_required), and the never-silently-dropped guarantee. DestructiveHint true is consistent and expanded with concrete consequences.

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?

The description is dense and information-rich, with purpose front-loaded. However, it repeats 'FREE' twice and uses heavy capitalization that adds noise. Though a bit sprawling, every major behavioral clause earns its place.

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

Completeness4/5

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

Covers authentication, side effects, error/failure modes, and dead-lettering thoroughly, including edge cases. The only gap is the absence of any mention of the success response shape, which matters because there is no output schema; still, for invocation and failure handling, it is nearly complete.

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

Parameters5/5

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

Schema coverage is 100%, but the description adds valuable runtime semantics beyond the schema: the default and effect of retry, the fence validation rules with specific refusal conditions, the error's role on the dead letter, and the agent_key/Authorization header alternative. This materially helps an agent set parameters correctly.

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?

The description states a specific verb and resource: 'Report that an item did not work out.' It clearly distinguishes itself from siblings by explicitly noting 'there is no work_release' and positioning itself as the correct way to hand an item back even when nothing went wrong, in contrast with work_done and other work-family tools.

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?

Gives explicit when-to-use guidance: it is also the correct way to return an item when nothing went wrong because there is no work_release. It also explains when to use retry:true vs retry:false and references work_done's fence behavior, giving clear routing across sibling tools.

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.

Resources