Skip to main content
Glama

pdf_embed_image

Idempotent

Embed PNG or JPEG images into PDF pages with precise positioning and optional scaling while preserving aspect ratios.

Instructions

Embed a PNG or JPEG image into a specific page of a PDF. Supports custom positioning and optional scaling with aspect ratio preservation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filePathYesAbsolute path to the source PDF file
imagePathYesAbsolute path to the PNG or JPEG image file
pageYesTarget page number (1-indexed)
xYesX position in points from the left edge of the page
yYesY position in points from the bottom edge of the page
widthNoImage width in points. Omit to use original width (or scale proportionally if height is set).
heightNoImage height in points. Omit to use original height (or scale proportionally if width is set).
outputPathYesAbsolute path for the output PDF
Behavior4/5

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

Adds valuable behavioral context beyond annotations by describing 'aspect ratio preservation' and 'custom positioning' semantics. Annotations already cover safety (idempotent, non-destructive), but description could clarify that it creates a new file rather than modifying in-place.

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?

Two sentences with zero waste. Front-loaded with core operation (embedding), followed by key capabilities (positioning/scaling). Every word 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?

Sufficient for an 8-parameter mutation tool with complete schema and annotations. Covers core operation and key features. Minor gap: could explicitly state that outputPath creates a new file rather than altering the source PDF in-place.

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?

With 100% schema coverage (baseline 3), the description adds semantic framing by mapping 'custom positioning' to x/y parameters and 'optional scaling with aspect ratio preservation' to width/height interactions, enhancing understanding of how parameters interact.

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?

Specific verb ('Embed'), specific resource ('PNG or JPEG image into a specific page of a PDF'), and distinguishes from sibling pdf_embed_qr_code by explicitly limiting input to PNG/JPEG formats rather than QR codes.

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?

Provides implied usage guidance by specifying supported image formats (PNG/JPEG) and capabilities (positioning, scaling), but lacks explicit when-to-use guidance or named alternatives compared to siblings like pdf_embed_qr_code.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/AryanBV/pdf-toolkit-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server