Skip to main content
Glama

It's back

loan_returned

Close a loan when an item is returned to its owner; history remains and borrower reminders stop. Supply the loan ID from list_loans.

Instructions

Closes a loan: a lent thing is back, or a borrowed one was given back. Use it when the person says so ("Sam returned the ladder"); the loanId comes from list_loans. The loan stays in the item's history and the borrower's reminder emails stop; nothing else about the item changes. Calling it again for the same loan is refused (it's already back).

Input Schema

NameRequiredDescriptionDefault
onNoThe day it came back, yyyy-mm-dd; today if left out
loanIdYesThe loan's id, from list_loans

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.1.1
    • addedInput schema / properties / loanId / description
      Added value: +"The loan's id, from list_loans"
    • addedInput schema / properties / on / description
      Added value: +"The day it came back, yyyy-mm-dd; today if left out"
  2. First observedv0.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Above the annotations (which only say it is a non-destructive write), the description discloses the side effects an agent cannot infer: the loan is retained in the item's history, the borrower's reminder emails stop, and nothing else about the item changes. It also warns that a repeated call for the same loan is refused because it is already back, which prevents a common retry error.

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?

Three short sentences: purpose first, then when to use, then consequences. Nothing is padded, and the most decision-relevant framing leads the description.

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?

For a two-parameter mutation with no output schema, the description covers preconditions, side effects, and the idempotency refusal, which is nearly everything an agent needs. The only gap is that it does not indicate what the call returns on success, leaving the agent to infer the response shape.

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 both loanId and the optional 'on' date are already documented, and the description's note that loanId comes from list_loans merely restates the schema. The 'on' parameter (default today, yyyy-mm-dd) is not mentioned at all, so the description adds little beyond the schema 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?

'Closes a loan: a lent thing is back, or a borrowed one was given back' gives a specific verb (closes) and resource (loan) and covers both directional cases. It is immediately distinguishable from the sibling lend_item, which performs the opposite transition.

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 states the triggering condition with a concrete example ('Use it when the person says so ("Sam returned the ladder")') and points to list_loans as the source of the loanId, which is real routing guidance. It also gives a when-not via the repeat-call refusal, though it never names an alternative for correcting a mistaken return.

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