Skip to main content
Glama

export

Converts a Figma node into SVG, PNG, JPG, WebP, or AVIF with scale/quality controls, returning metadata and inline raster images. Create the output directory first.

Instructions

Export a node to SVG, PNG, JPG, WebP or AVIF. Create the output directory first. Returns metadata and, for raster formats, an inline image. PNG suits inline references. For website assets, follow the target project's existing image pipeline; otherwise start with WebP for bitmaps, sized for display dimensions and DPR using scale/maxSize and quality/maxKb. SVG embeds original images and can be large; keep it for vector artwork. scale, quality and maxSize affect raster formats only; maxSize defaults to 1600. Check returned dimensions/bytes and isError; read content on failure.

Input Schema

NameRequiredDescriptionDefault
outYesoutput path ending in .png, .jpg, .jpeg, .webp, .avif or .svg; create the parent directory first
fileYesthe saved .fig: a local path (absolute recommended), or gs://bucket/object using gcloud; remote sources are unavailable with --root
nodeYesa stored node id (12:345 or 12-345), full instance sublayer id (I12:345;67:89) from inspect/nodes, or a Figma URL with ?node-id=
maxKbNoKiB (1024 bytes) budget; lower lossy quality until it fits; PNG/SVG fail if over budget
scaleNodefault 1
maxSizeNolongest side in pixels, default 1600; 0 keeps the scaled size
qualityNo1-100, default 80

Output Schema

NameRequiredDescriptionDefault
pathYes
bytesYes
widthYes
heightYes
qualityYesthe quality used; --max-kb may lower it

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed17 schema fields changedv0.7.2
    • addedInput schema / additionalProperties
      Added value: +true
    • changedInput schema / properties / file / description
      Previous value: -"the .fig file (File > Save local copy): an absolute path, or gs://bucket/object"New value: +"the saved .fig: a local path (absolute recommended), or gs://bucket/object using gcloud; remote sources are unavailable with --root"
    • addedInput schema / properties / file / minLength
      Added value: +1
    • changedInput schema / properties / maxKb / description
      Previous value: -"lower lossy quality until the file fits; PNG/SVG fail if over budget"New value: +"KiB (1024 bytes) budget; lower lossy quality until it fits; PNG/SVG fail if over budget"
    • addedInput schema / properties / maxKb / maximum
      Added value: +18014398509481984
    • addedInput schema / properties / maxKb / minimum
      Added value: +0
    • addedInput schema / properties / maxSize / default
      Added value: +1600
    • addedInput schema / properties / maxSize / maximum
      Added value: +4294967295
    • addedInput schema / properties / maxSize / minimum
      Added value: +0
    • changedInput schema / properties / node / description
      Previous value: -"a node id (12:345 or 12-345) or a Figma URL with ?node-id="New value: +"a stored node id (12:345 or 12-345), full instance sublayer id (I12:345;67:89) from inspect/nodes, or a Figma URL with ?node-id="
    • changedInput schema / properties / out / description
      Previous value: -"absolute path ending in .png, .jpg, .webp, .avif or .svg"New value: +"output path ending in .png, .jpg, .jpeg, .webp, .avif or .svg; create the parent directory first"
    • addedInput schema / properties / out / minLength
      Added value: +1
    • addedInput schema / properties / quality / default
      Added value: +80
    • addedInput schema / properties / quality / maximum
      Added value: +100
    • addedInput schema / properties / quality / minimum
      Added value: +1
    • addedInput schema / properties / scale / default
      Added value: +1
    • addedInput schema / properties / scale / exclusiveMinimum
      Added value: +0
  2. Changed1 schema field changedv0.5.0
    • addedInput schema / properties / maxSize
      Added value: +{
      +  "description": "longest side in pixels, default 1600; 0 keeps the scaled size",
      +  "type": "integer"
      +}
  3. First observed

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations, the description carries the burden well: it states the output-directory prerequisite, that raster formats return an inline image, that SVG can embed originals and become large, and that callers should check returned dimensions/bytes and isError. It does not discuss overwrite behavior or permissions, leaving some side-effect detail unstated.

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?

The description is front-loaded with purpose and then moves through prerequisites, format guidance, raster-only caveats, and error checking without filler. Every sentence contributes actionable information.

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 seven parameters and an existing output schema, the description supplies the missing decision context: format choice, raster-only parameters, directory creation, and failure handling. An agent has enough to call the tool correctly without further prose.

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 description coverage is 100%, so the baseline is 3, but the description adds cross-parameter meaning: 'scale, quality and maxSize affect raster formats only' and ties quality/maxKb to sizing for DPR. That is useful beyond the schema's per-field descriptions.

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?

The description opens with a specific verb and resource: 'Export a node to SVG, PNG, JPG, WebP or AVIF.' It makes the tool's action and output formats unmistakable, and the sibling names do not include a competing export tool.

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

Usage Guidelines4/5

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

It gives clear format-selection guidance, including 'PNG suits inline references,' WebP for website bitmaps, and SVG for vector artwork. It does not explicitly compare against sibling tools or state when not to use export, so it stops short of full alternative routing.

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

Deploy Server

Other Tools