Skip to main content
Glama

Compress an image from a URL

tinypng_compress_image

WRITE (uses quota): ask TinyPNG (Tinify) to fetch a public image by URL and compress it (JPEG, PNG, WebP, AVIF or JPEG XL). Returns the output_url (Tinify's Location address of the compressed image), the compressed size and type, the savings when the input size is known, and the Compression-Count header (compressions used this month). The image is stored by Tinify for about 48 hours; output_url needs your API key, so use tinypng_download_image to get the bytes and tinypng_transform_image to resize, convert or keep metadata. Each compression counts against the monthly quota of your Tinify API key (the free plan includes 500 per month); resizing and converting count one extra compression each. POST /shrink.

Input Schema

NameRequiredDescriptionDefault
urlYesPublic http(s) URL of the image to compress. Tinify's servers fetch it, so it must be reachable from the internet.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations only mark this as a non-read-only, non-idempotent, open-world write; the description adds substantial context beyond them: resulting output_url is key-gated, Tinify retains the image ~48 hours, each call decrements a monthly quota (500 free), and resize/convert each cost an extra compression. That is rich operational disclosure.

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?

It front-loads the most decision-relevant fact ('WRITE (uses quota)') then packs purpose, return shape, retention, and sibling routing into tight sentences with no filler.

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?

With no output schema, the description carries the return-value burden and discharges it: output_url, compressed size and type, savings, and Compression-Count header. Quota, retention, and alternatives are all covered, so an agent can call this correctly without further lookup.

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 coverage is 100% and the lone 'url' parameter is fully described there, including the internet-reachability requirement. The description restates that Tinify's servers fetch the URL but adds no syntax or formatting detail beyond the schema, so baseline 3 is correct.

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?

Names a specific write operation ('ask TinyPNG to fetch a public image by URL and compress it'), enumerates the supported formats, and distinguishes itself from siblings by delegating resizing/converting to tinypng_transform_image and byte retrieval to tinypng_download_image.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent: use tinypng_download_image for bytes and tinypng_transform_image for resize/convert/metadata. It also states the costs (quota consumption, extra compression per resize/convert), which is exactly the when-to-use-wisely guidance an agent needs.

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.