Skip to main content
Glama

mint utilities

HTML to image

html_to_image
Read-onlyIdempotent

Render an HTML snippet to a PNG, JPEG or WEBP image at any width, with retina scaling and transparent background. Cost: 3 credits per call. Output: a file (image/png | image/jpeg | image/webp) returned inline, at most 1 MiB. The rendered image

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
htmlYesThe HTML document or fragment (UTF-8, up to 2 MB). JavaScript is not executed.
widthNoViewport width in CSS px
formatNopng
heightNoViewport height in CSS px; omit for a full-page image that fits the content
qualityNojpeg / webp quality
transparentNoTransparent page background (png / webp only)
device_scale_factorNoPixel density (2 = retina)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.4/5.0
Behavior4/5

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

Annotations already establish the safety profile (readOnlyHint, idempotentHint, non-destructive), so the bar is lower, and the description still contributes real behavioral facts: a 3-credit cost, an inline file return, and a 1 MiB output cap. Retina scaling and transparent-background support are also disclosed, though error/failure behavior and the JS-not-executed caveat (left to the schema) are not mentioned.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The opening sentence and the cost/output sentences are front-loaded and efficient, but the definition ends with the dangling, incomplete fragment 'The rendered image', which is wasted text and looks truncated. Useful content is present, but the trailing orphan costs it.

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 carries the return-value burden, specifying an inline file (image/png | image/jpeg | image/webp) capped at 1 MiB and noting JavaScript is not executed. Combined with 86% schema coverage and full annotations, an agent has enough to call it, though the dangling final sentence and absent sibling routing leave minor gaps.

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 86%, so the schema already documents html, width, height, quality, transparent and device_scale_factor with ranges and defaults. The description's mentions of width, retina scaling and transparent background largely restate that, adding no syntax or format detail beyond it; the baseline 3 applies.

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 (Render) and resource (an HTML snippet) plus the concrete output artifacts (PNG, JPEG or WEBP), so an agent immediately knows this produces a raster image. It implicitly separates itself from html_to_pdf by output format, but never names that or any other sibling, so a choice between this and screenshot still requires inference.

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 when-to-use or when-not-to-use guidance and no named alternative, even though screenshot and html_to_pdf are obvious competitors in the toolset. The cost line ('3 credits per call') hints that cost should factor into tool selection, but no condition is spelled out.

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.

Resources