Skip to main content
Glama

Add page numbers

number_pdf_pages

Stamp page numbers onto a PDF and save them to a new file, leaving the original untouched. Use templates like Page {n} of {total} to set the numbering format.

Instructions

Stamp page numbers on a PDF. The template may use {n} for the page number and {total} for the last number, e.g. "Page {n} of {total}". Writes a new PDF and returns its path; the input is not modified and an existing file is never overwritten. Text only, in Helvetica.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYesPath to the PDF.
startNoNumber printed on the first numbered page.
outputNoWhere to write the result. Defaults to a new file beside the input. Existing files are never overwritten; a free name like file-1.pdf is used instead.
passwordNoPassword for a PDF that asks for one when opened. Used only on this machine.
positionNoWhere on each page the number goes: bottom or top, then left, center or right. The text sits 28 points (about 0.4 inch) in from the page edges. Default "bottom-center".bottom-center
templateNoText to print. Default "{n}".{n}
font_sizeNoFont size in points, from 4 to 72. Default 11.
first_pageNoFirst page (1-based) that gets a number; earlier pages, such as a cover, are left blank.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.9/5.0
Behavior4/5

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

Annotations only declare the safety profile (readOnlyHint=false, destructiveHint=false), and the description usefully adds that a new PDF is written, its path is returned, the input is untouched, and existing files are never overwritten. The 'Text only, in Helvetica' constraint is a valuable behavioral detail, though return-format specifics beyond 'path' remain thin.

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 tight sentences, front-loaded with the core action, then template syntax, then write semantics. No sentence is wasted and the most important constraint (non-destructive output) is clearly stated.

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?

With no output schema, the description correctly notes the return value (the new file path) and the non-overwrite guarantee. For an 8-parameter stamping tool this is nearly complete, though edge cases like password-protected inputs are only covered by the schema field itself.

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 already 100%, so the baseline is 3, but the description adds real value by explaining the {n} and {total} placeholders in template, which the schema only labels as 'Text to print'. It does not expand on start, first_page, or position beyond what the schema states.

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?

States a specific verb and resource ('Stamp page numbers on a PDF'), making the operation unambiguous. However, it never names or contrasts with siblings like split_pdf, merge_pdfs, or rotate_pdf, so there is no explicit differentiation for an agent choosing among PDF tools.

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?

Usage is only implied by the purpose; there is no statement of when to prefer this over alternatives or any prerequisite context. An agent can infer intent from the verb, but the description offers no routing guidance or exclusions.

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