Skip to main content
Glama
cshum

Imagor MCP

Official

build_imagor_url

Build a signed imagor image URL from typed transformation parameters. Compositions are validated first, so invalid combinations are refused instead of returned.

Instructions

Build a signed imagor image URL from typed transformation parameters. Requires IMAGOR_SECRET to be configured. The composition is validated before the URL is returned, so an invalid combination is refused rather than emitted. Read get_imagor_skill before composing anything, and call list_imagor_filters for each filter's signature, description and accepted argument forms, which are generated from imagor's own filter reference. Build and verify in a loop: a request returns 200 whether or not a filter did anything, so pass the same parameters to verify_imagor_url rather than assuming it worked. For a composed layout rendered at a canvas size, use render_template.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
metaNoreturn image metadata only, without processing the image
trimNotrim surrounding space using the top-left pixel colour
imageYesthe source to transform, not a composed result: a URL or path such as "example.com/a.jpg", or a synthetic source such as "color:red" or "color:none"
smartNouse content-aware smart crop
widthNotarget width in pixels; 0 means automatic
fit_inNofit inside width x height instead of cropping to fill; the result can be smaller than the box on one side
h_flipNomirror horizontally
heightNotarget height in pixels; 0 means automatic
v_flipNomirror vertically
filtersNoordered filters, applied left to right. Arguments are validated against imagor's catalogue: call list_imagor_filters for a filter's signature, description and accepted argument forms. image() loads its argument as its own canvas, so positions inside it are relative to the overlay
h_alignNohorizontal alignment, either "left" or "right"
stretchNostretch to exactly width x height, ignoring aspect ratio, which distorts the image; use full_fit_in to fill a box of a different shape without distorting it
trim_byNotrim anchor, either "top-left" or "bottom-right"
v_alignNovertical alignment, either "top" or "bottom"
crop_topNocrop top edge: a fraction 0-1 of the height, or absolute pixels when greater than 1
crop_leftNocrop left edge: a fraction 0-1 of the width, or absolute pixels when greater than 1
crop_rightNocrop right edge: a fraction 0-1 of the width, or absolute pixels when greater than 1
crop_bottomNocrop bottom edge: a fraction 0-1 of the height, or absolute pixels when greater than 1
full_fit_inNocover the box without cropping: one side matches width x height and the other exceeds it, keeping the aspect. Use for an image that must fill a panel without cutting into it. Requires fit_in, and add upscale() when the source is smaller than the box
trim_toleranceNotrim tolerance from 0 to 255
adaptive_fit_inNoinvert width and height when that yields better definition; requires fit_in
max_age_secondsNoadd a max_age() filter limiting how long the response may be cached
expire_unix_millisNoadd an expire() filter so the URL stops working after this unix-milliseconds timestamp

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoa request path ready to send to imagor, including its signature or unsafe prefix
modeYeshow the path was produced: signed or unsafe
noteNohuman-readable notes about the result
pathYesthe imagor path, without any signature or unsafe prefix
signedYeswhether the URL carries a signature
warningsNocompositions that are valid but will not do what was intended
absolute_urlNothe full URL to fetch, present only when IMAGOR_BASE_URL is configured

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does: it discloses the IMAGOR_SECRET prerequisite, that invalid compositions are refused rather than emitted, and the critical non-obvious trait that a 200 response does not prove a filter applied, so verification requires verify_imagor_url. It also flags silent failure modes (comma truncation, '?' altering the signed path, 403/404).

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 the purpose and prerequisite, and every sentence is actionable rather than filler. It is dense and runs several guidance clauses together in one long paragraph, which slightly impedes scanning, but no sentence is wasted.

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?

Given 23 parameters, no annotations, and an output schema (so return shape need not be explained), the description supplies the missing pieces: auth requirement, validation behavior, verification loop, and sibling routing. An agent has everything needed to call it correctly and to check its work.

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 the baseline is 3, but the description adds parameter-level meaning the schema does not: composition is validated against imagor's catalogue before emission, and the same parameter set must be replayed through verify_imagor_url to confirm effect. The filter-argument guidance largely duplicates the schema's own notes, which caps it below 5.

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 and resource ('Build a signed imagor image URL from typed transformation parameters'), including the signing constraint that distinguishes it from a plain URL builder. It explicitly routes away from siblings: get_imagor_skill, list_imagor_filters, verify_imagor_url, and render_template for composed layouts. An agent can place it in the toolset without 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 Guidelines5/5

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

Gives explicit sequencing (read get_imagor_skill before composing, call list_imagor_filters per filter), an alternative for a different job ('For a composed layout rendered at a canvas size, use render_template'), and the exact condition that selects the alternative. Nothing about when-to-use is left to inference.

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