Skip to main content
Glama

pdf_crop

Crop PDF — Crop the visible area of all pages in a PDF by setting new margins. Margins are in PostScript points; EVERY omitted edge defaults to 36pt — send 0 to leave an edge uncropped. [category: pdf]

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topNoHow much to cut off the top edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error.
fileYesInput PDF (max 25MB)
leftNoHow much to cut off the left edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error.
rightNoHow much to cut off the right edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error.
bottomNoHow much to cut off the bottom edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error.
outputFilenameNoOptional custom output filename.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / outputFilename / x-ui
      Added value: +{
      +  "unset_label": "Named after your file"
      +}
  2. Changed4 schema fields changed
    • addedInput schema / properties / bottom / x-ui
      Added value: +{
      +  "unit": "pt"
      +}
    • addedInput schema / properties / left / x-ui
      Added value: +{
      +  "unit": "pt"
      +}
    • addedInput schema / properties / right / x-ui
      Added value: +{
      +  "unit": "pt"
      +}
    • addedInput schema / properties / top / x-ui
      Added value: +{
      +  "unit": "pt"
      +}
  3. Changed8 schema fields changed
    • changedInput schema / properties / bottom / description
      Previous value: -"Bottom crop in points."New value: +"How much to cut off the bottom edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error."
    • changedInput schema / properties / bottom / maximum
      Previous value: -14400New value: +288
    • changedInput schema / properties / left / description
      Previous value: -"Left crop in points."New value: +"How much to cut off the left edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error."
    • changedInput schema / properties / left / maximum
      Previous value: -14400New value: +288
    • changedInput schema / properties / right / description
      Previous value: -"Right crop in points."New value: +"How much to cut off the right edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error."
    • changedInput schema / properties / right / maximum
      Previous value: -14400New value: +288
    • changedInput schema / properties / top / description
      Previous value: -"Top crop in points. 0 = no crop on this edge."New value: +"How much to cut off the top edge, in points - 72 points is one inch. 0 leaves this edge alone. Cut away more than the page holds and you get a 1-point page rather than an error."
    • changedInput schema / properties / top / maximum
      Previous value: -14400New value: +288
  4. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations indicate readOnlyHint=false (mutation) and destructiveHint=false. The description adds valuable behavioral context beyond annotations: omitted edges default to 36pt, 'send 0 to leave an edge uncropped', and over-cropping yields a 1-point page rather than an error. This complements the annotations without contradiction.

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?

The description is two sentences with no filler. It front-loads the action and key constraints (defaults, units, edge behavior) efficiently. Every sentence 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?

For a simple crop tool with full schema coverage and no output schema, the description covers essential edge cases and defaults. The only minor omission is whether the output overwrites the original or creates a new file, but the optional outputFilename parameter implies a new file. Overall, an agent has enough to call it correctly.

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 coverage is 100% with detailed per-parameter descriptions including default, min, max, and behavior of 0. The description adds the 'PostScript points' unit context and reiterates the default rule, but mostly restates schema information. Baseline 3 is appropriate given high 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 states a specific verb ('Crop'), resource ('PDF'), scope ('all pages'), and method ('setting new margins'). It clearly differentiates from sibling tools like photo_crop (images) and other pdf_* tools that perform different operations.

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

Usage Guidelines3/5

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

The description explains what the tool does and its key defaults, but it does not explicitly state when to use this tool vs alternatives or when not to use it. No exclusions or alternative tool references are provided. The intended use is implied by the name and sibling context, but explicit guidance is missing.

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