Skip to main content
Glama

claim_funds

Claim earned payment and collateral from a settled or resolved Idios contract after dispute resolution, with automatic duplicate-claim protection.

Instructions

Claim funds from a Settled or Resolved Idios contract.

Call this after the contract reaches one of these states:

  • Settled (status=4): worker claims payment + collateral

  • ResolvedToBob (status=7): worker won the dispute, claims payment + collateral

  • ResolvedToAlice (status=6): requester won the dispute, claims payment + collateral A refunded contract (status=5) returns funds directly and needs no claim.

The dispute winner receives payment + collateral only. The dispute fee is split among the consensus voting arbitrators, never awarded to a party.

A Resolved contract stays at status 6 or 7 forever, even after the winner is paid. This tool checks the winner_paid flag via view_dispute before claiming, and reports "already claimed" instead of firing a call that would halt on chain.

The amounts are read from chain by the contract; only job_id is sent.

Args: job_id: The contract ID to claim from.

Returns confirmation of claim, or error message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
job_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

With no annotations, the description fully bears the behavioral disclosure burden. It explains that the dispute winner receives payment plus collateral, the fee is split among arbitrators, and the contract status remains unchanged even after claiming. It also describes the internal check of the winner_paid flag to prevent chain halting.

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 multi-sentence but highly informative. Each sentence serves a purpose: stating the action, listing conditions, explaining amounts and checks, and describing the parameter. It is front-loaded with the primary action and well-structured.

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?

Given the complexity (multiple contract states, flags, amounts) and the presence of an output schema, the description provides complete context. It covers when to call, what happens, how the flag check works, and what is returned. No gaps are evident.

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?

The only parameter, job_id, is explained as the contract ID. Despite the input schema having full type and requirement info, the description adds context by stating that only job_id is sent and that amounts are read from the chain. This adds sufficient value given low schema coverage.

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 clearly states the tool's purpose: claiming funds from a Settled or Resolved Idios contract. It specifies the action (claim funds) and the resource (Idios contract), and distinguishes from siblings like 'claim_after_timeout' by detailing the required contract states.

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?

The description provides explicit when-to-use guidelines by listing the three eligible contract statuses (Settled, ResolvedToBob, ResolvedToAlice) and explicitly states when not to use (refunded contract needs no claim). It also mentions checking the winner_paid flag via view_dispute to avoid redundant calls.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/honeytones/idios'

If you have feedback or need assistance with the MCP directory API, please join our Discord server