Skip to main content
Glama

Images to PDF

images_to_pdf

Combine JPG and PNG images into a single PDF, one image per page in order. No re-compression; writes a new file without overwriting existing.

Instructions

Put JPG and PNG images into one PDF, one image per page, in the order given. Images are embedded as they are, without re-compression. HEIC and WebP are rejected with an error that says how to convert them. Writes a new PDF and returns its path; an existing file is never overwritten.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputsYesJPG or PNG paths, in page order.
marginNoMargin in points (72 = 1 inch).
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.
page_sizeNo"fit" makes each page the size of its image; "a4" and "letter" centre the image on a standard page.fit

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.5/5.0
Behavior5/5

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

With annotations only covering the safety profile, the description adds substantial behavior: images are embedded without re-compression, unsupported formats fail with an actionable error, the tool writes a new file and returns its path, and existing files are never overwritten. This is consistent with destructiveHint=false and gives the agent real operational context.

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 with no filler, front-loading what the tool does before constraints and return behavior. Every clause carries information (formats, embedding policy, error behavior, return value, overwrite policy).

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?

No output schema exists, and the description compensates by explaining the return value (a new PDF path) and the no-overwrite naming policy. Combined with format limits and page ordering, an agent has everything needed to invoke 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 description coverage is 100%, so all four parameters are already documented, including ordering for 'inputs' and the 72-points-per-inch margin convention. The description's 'in the order given' largely restates what the schema already says, so baseline 3 applies.

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 and resource ('Put JPG and PNG images into one PDF') plus the output structure ('one image per page, in the order given'). This clearly distinguishes it from merge_pdfs and the other PDF siblings, which operate on PDFs rather than images.

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?

Gives clear applicability conditions: accepted formats (JPG/PNG), rejected formats (HEIC/WebP) with a helpful error, and ordering expectations. It never names an alternative sibling (e.g. use merge_pdfs for PDFs, or a converter for HEIC), so the when-not guidance is implied rather than explicit.

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