Skip to main content
Glama

mint utilities

SVG to PNG renderer

svg_to_png
Read-onlyIdempotent

Render an SVG document to a PNG at a chosen width, height or scale and background; external files, network references and XML entities are never loaded. Cost: 1 credit per call. File input (file): base64 string, data: URI or {"url": "https://..."}. Output: a file (image/png) returned inline, at most 1 MiB. The rendered PNG

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
svgNoThe SVG markup as text (up to 2 MB). Use `file` instead for a base64 / URL / uploaded .svg or .svgz
fileNoAlternative to `svg`: an .svg or .svgz file as base64, data: URI or {"url": "https://..."}
scaleNoMultiplier of the SVG's own size (default 1); not combinable with width / height
widthNoOutput width in px (height follows the aspect ratio unless given)
heightNoOutput height in px (width follows the aspect ratio unless given)
backgroundNotransparent, #rrggbb or #rrggbbaatransparent

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 declare readOnly/idempotent/destructive=false, but the description adds genuinely useful non-schema behavior: external files, network references and XML entities are never loaded (a security guarantee), cost is 1 credit per call, and output is inline image/png capped at 1 MiB. It stops short of 5 because error/timeout behavior and the exact scope of 'network references never loaded' (given a URL input is accepted) are left unexplained.

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?

It is front-loaded with the core operation and useful constraints, but it contains a dangling, truncated fragment ('The rendered PNG') and restates the output location twice (file input guidance and output description), which blunts its structure.

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 and six parameters, the description does the necessary extra work: it specifies the return type/size cap and the accepted input encodings, which the schema partially covers. It omits failure modes and a clear statement of what the URL input actually does over the network, so it is not fully complete.

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 the schema already documents svg, file, scale, width, height and background with constraints and the width/height/scale exclusivity. The description restates the sizing/background choices without adding format or default detail beyond the schema, so 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?

The description states a specific verb and resource ('Render an SVG document to a PNG'), and the SVG→raster pipeline is distinct from siblings like html_to_image or image_convert. It never names an alternative or clarifies when this beats those siblings, so it stops short of a 5.

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 explicit when-to-use / when-not-to-use guidance and no routing to the closest siblings (html_to_image, image_convert). The only implied usage context is the width/height/scale tradeoff, which is already schema-level detail.

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