Skip to main content
Glama

Images to PDF

pdf_from_images
Read-onlyIdempotent

Converts JPEG, PNG, WebP, GIF, TIFF, AVIF, or SVG images into a PDF with one image per page, in the order provided, with selectable page size, orientation, margins, and quality.

Instructions

Make a PDF from images (JPEG, PNG, WebP, GIF, TIFF, AVIF, SVG…), one image per page, in the order given. Page size A4, Letter, or "fit" (page = image size at 96 dpi); orientation auto/portrait/landscape; margin in mm; quality "original" (JPEG/PNG kept as-is), high (≤3000 px, JPEG 90), medium (≤2000 px, 75) or small (≤1400 px, 60). Photos are turned upright from their EXIF orientation. Web version: https://s3eidat.github.io/images-to-pdf/

Input Schema

NameRequiredDescriptionDefault
imagesYesImages in page order: path/base64 strings, or {file, rotate}.
marginNoMargin around each image in mm. Default 10.
outputNoWhere to write the result: a file path, or a folder ending in "/". Default: the server output folder (a temp folder unless --out-dir is set).
qualityNoImage quality / size trade-off. Default "high".high
pageSizeNoPage size. Default "a4".a4
orientationNo"auto" turns the page to match each image. Ignored for "fit".auto
returnBase64NoAlso return the output as base64 in the result (only for small files). Default false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

Goes well past the annotations (readOnlyHint, idempotentHint, openWorldHint) by disclosing EXIF auto-uprighting, what "original" quality means (JPEG/PNG kept as-is), the downscaling ceilings behind high/medium/small, and that "fit" means page = image at 96 dpi with orientation ignored. Minor tension: annotations mark it read-only while the tool plainly writes a PDF artifact, and the description never states what the result contains (path? bytes?).

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 verb, resource, and output shape, then packed with high-density parenthetical detail; almost every clause carries real information. Slightly over-dense as one run-on sentence, and the trailing web-version URL contributes nothing to tool selection.

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?

Covers the essentials for a 7-parameter, mutation-style tool with no output schema: formats, ordering, page geometry, quality trade-offs. Gaps remain around what is returned (path vs. base64 depending on returnBase64), file naming, and failure behavior for unsupported or unreadable images.

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 100%, so 3 is the floor; the description earns above that by giving concrete semantics the terse enum labels omit — pixel caps and JPEG quality numbers per quality tier, the 96 dpi meaning of "fit", and orientation being ignored under "fit". It does not add anything for `output` or `returnBase64` beyond the schema.

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+resource ("Make a PDF from images") plus the key structural rule (one image per page, in the order given). This cleanly distinguishes it from pdf_to_images, image_convert, and ai_markdown_to_pdf in the sibling list without the agent opening any schema.

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 accepted input formats and page-size/quality options imply when the tool applies, and ordering semantics are stated. However there is no explicit when-to-use vs. alternative guidance (e.g., vs. image_convert, ai_markdown_to_pdf, or pdf_merge), and no prerequisites or exclusions beyond what the option list implies.

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

Deploy Server

Other Tools