Skip to main content
Glama

Print and Mail Company

Fix document margins

fix_document_margins
DestructiveIdempotent

Use this when an uploaded PDF fails the print check because content is too close to the edge or pages are not A4. mode "shrink" (default) scales the affected pages down slightly and centres them on A4; nothing is lost. mode "crop" keeps pages at 100 % and removes everything inside the margin band, so that content is NOT printed (non-A4 pages are first fitted onto A4). The original upload is kept; calling again with the other mode replaces the earlier fix. If content touches the edge, ask the user which mode they prefer and tell them what changed. Not possible once the letter is paid. Needs the user's account.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoshrink = scale pages down slightly, nothing lost; crop = keep 100 % size and cut off everything inside the margin (that content is not printed)shrink
document_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=true, and the description enriches this with what is actually destroyed (crop removes content inside the margin band so it is NOT printed) and what is safe (shrink loses nothing), plus that the original upload is retained and re-calling replaces the prior fix. It also discloses the auth dependency and a life-cycle restriction.

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 triggering condition, then mode semantics, then lifecycle and interaction caveats. Every sentence carries information, but the mode explanation is repeated from the schema verbatim, which is mild redundancy rather than filler.

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 no-output-schema mutation tool with rich annotations, the description supplies everything an agent needs: trigger, mode trade-offs, destructive vs non-destructive outcomes, idempotent/replacement behavior, payment gating, and the need to consult the user. No material gap remains.

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 50%, with mode fully documented in the schema and document_id undocumented. The description compensates by explaining both mode values and their consequences (shrink scales/centres on A4; crop keeps 100% and cuts the margin band) beyond the schema's terse gloss, though it adds nothing about document_id's expected format.

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 (fix) and resource (document margins) and frames the exact triggering condition: an uploaded PDF failing the print check due to edge proximity or non-A4 pages. This clearly distinguishes it from the sibling check_pdf_margins, which only inspects rather than repairs.

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?

Explicitly says when to use it ('when an uploaded PDF fails the print check'), when it is unavailable ('Not possible once the letter is paid'), and how to route a decision ('ask the user which mode they prefer'). Prerequisites (needs the user's account) and re-invocation semantics are also stated.

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.