Skip to main content
Glama
LeoGCode

figma-reader-mcp

by LeoGCode

figma_export_image_fills

Export original image fills and strokes from a Figma node or file to a directory. Returns each image's hash, saved path, size, and layers using it, flagging missing assets.

Instructions

Write the original image assets (photos, bitmaps) a node or the whole file uses, in a fill or a stroke paint, to a directory. Answers with an array, one entry per distinct image: hash, the path written, its size in bytes, and up to five of the layers using it (with usedByTotal when there are more). An image whose bytes this export does not carry is reported as {hash, missing: true} and nothing is written for it.

Input Schema

NameRequiredDescriptionDefault
fileYesA local .fig path, a Figma file key or a figma.com/design/... URL (see the server's instructions, or figma-reader help)
node_idNo
out_dirYesDirectory to write the images into, created if it is missing. A relative path is resolved against this process's working directory, which for an MCP server is wherever the client started it
refreshNoExport the live file again rather than read a local or cached copy (see the server's instructions, or figma-reader help)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.4.2
    • changedInput schema / properties / file / description
      Previous value: -"Path to a local .fig file, or a Figma file key / figma.com/design/... URL. A node-id in the URL is used when this tool takes node_id and it is omitted; a tool that answers about the whole file ignores it. A key or URL uses a local '<name> [<key>].fig' from FIGMA_FILES_DIRS when one exists, otherwise exports through the browser."New value: +"A local .fig path, a Figma file key or a figma.com/design/... URL (see the server's instructions, or figma-reader help)"
    • changedInput schema / properties / refresh / description
      Previous value: -"Skip local/cached copies and export the live file through the browser. Has no effect when file is a path to a .fig: that file is read as it is on disk and the result carries refreshIgnored; pass the key or URL to export the live file instead."New value: +"Export the live file again rather than read a local or cached copy (see the server's instructions, or figma-reader help)"
  2. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false and openWorldHint=true, and the description goes further by disclosing write behavior (files land in out_dir), partial-failure handling (missing bytes reported as {hash, missing: true} with nothing written), and the per-image result shape including usedByTotal and the five-layer cap. It omits overwrite behavior and auth/rate-limit context, so it is strong but not exhaustive.

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?

Two tightly packed sentences: the action is front-loaded, then the return contract. Every clause (hash, path, size, layer sample, usedByTotal, missing marker) carries information an agent needs absent an output schema.

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 fully carries the return-value burden and does so well, and it covers the write/partial-failure semantics. It stops short on overwrite behavior for existing files and any permission or refresh-cost considerations for a tool that re-exports the live file.

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 75%, so most parameters are already documented in the schema. The description only adds the node-vs-whole-file distinction for node_id; it does not clarify the effect of refresh or how out_dir interacts with repeated exports. Baseline adequacy, no extra value.

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?

Opens with a specific verb+resource: writing the original image assets used by a node or whole file in fill/stroke paints to a directory. This clearly separates it from rendering-oriented siblings like figma_screenshot and content readers like figma_get_text or figma_get_node.

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

Usage Guidelines3/5

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

The scope ('a node or the whole file', 'fill or a stroke paint') implies when the tool is applicable, but there is no explicit when-to-use vs. when-not, no naming of alternatives such as figma_screenshot, and no prerequisite guidance. Usage is inferable rather than stated.

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