Skip to main content
Glama

Organize PDF pages

organize_pdf
Read-onlyIdempotent

Reorder, rotate, or drop PDF pages. Each entry names a 1-based source page and a rotation of 0, 90, 180, or 270. The same page may be listed twice. Send base64 or a public URL. Private addresses are refused.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "pages": "<pages>"
    },
    "name": "organize_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoPublic URL of a PDF. Private and local addresses are refused. Provide data or url.
dataNoPDF bytes as base64 or a data URI. Decoded size is capped at 10 MB. Provide data or url.
pagesYes
filenameNo
mimeTypeNo

Output Schema

NameRequiredDescriptionDefault
dataYesOrganized PDF as base64.
bytesYes
pageCountYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / additionalProperties
      Added value: +false
  2. First observed

TDQS

B3.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and openWorldHint, so the safety bar is lower, and the description still adds real value: it discloses that duplicate source pages are permitted ('The same page may be listed twice') and that private/local addresses are refused, which is an SSRF-style constraint an agent must respect before choosing a URL. It does not describe the returned artifact, but an output schema exists to cover that.

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?

Four short sentences, front-loaded with the core action and followed by the page semantics and transport constraints in priority order. Minor redundancy exists between 'Send base64 or a public URL. Private addresses are refused.' and the url parameter's own description, which repeats the private-address refusal verbatim.

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

Completeness3/5

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

With an output schema present, the description needn't explain return values, and it covers the essential page-list semantics and source constraints. Gaps remain for a moderate-complexity file-transformation tool: no guidance on the output filename/mimeType parameters and no routing against sibling PDF tools, which an agent must infer.

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 only 40%, so the description must add meaning, and it does for the two most consequential parameters: source is '1-based' and rotation values are limited to 0/90/180/270. However, it says nothing about filename, mimeType, or the 500-item/10 MB caps, leaving half the surface to the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb list and resource: 'Reorder, rotate, or drop PDF pages.' An agent can immediately tell this manipulates page order/orientation rather than merging, splitting, or rendering. It stops short of naming how it differs from siblings like merge_pdf or split_pdf, so it lands at 4 rather than 5.

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

Usage Guidelines2/5

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

There is no explicit when-to-use or when-not-to-use guidance. The nearest thing is the mechanical instruction 'Send base64 or a public URL,' which describes input format, not tool selection. Nothing tells an agent whether to reach for this versus merge_pdf (combining documents) or split_pdf (extracting documents).

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.