Skip to main content
Glama
LeoGCode

figma-reader-mcp

by LeoGCode

figma_get_styles

Retrieve Figma style values (fill, stroke, text, effect, grid) as JSON or CSS from local .fig files or Figma URLs.

Instructions

Local (and imported library) styles with their values: FILL (color), STROKE, TEXT, EFFECT and GRID. Formats: json (default) or css. A file with no styles, or none of the type asked for, answers empty in that format.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fileYesPath 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.
typeNoOnly styles of this type
formatNo
refreshNoSkip 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.
out_fileNoAlso write the result to this path
css_prefixNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

The description discloses the empty-result behavior, the refresh option to bypass local copies, and the ability to write output via out_file. However, it does not explicitly state whether the tool modifies any state beyond optional file writing, and it omits authentication requirements or network effects. Since annotations provide no read-only guarantee (readOnlyHint=false), the description carries the burden but does not fully clarify.

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?

The description is three short, focused sentences that front-load the core purpose and types before mentioning formats and edge-case behavior. It is efficient and avoids redundancy, though it could be slightly more structured with bullet points for readability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter tool with no output schema, the description explains the main behavior and output formats but leaves css_prefix undefined and does not describe the structure of the returned data. The empty-result note is helpful, but the lack of details on authentication, pagination, or error cases makes it incomplete for an agent needing to call it correctly.

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?

The schema covers 67% of parameters with descriptions. The tool description adds the default format ('json (default)') and lists the style types, complementing the schema. However, css_prefix is entirely undocumented in both schema and description, and the description does not clarify the interaction between type and format beyond what is in the enum.

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 clearly identifies the resource (styles) and the verb (get) along with the supported types (FILL, STROKE, TEXT, EFFECT, GRID) and formats (json/css). It distinguishes itself from siblings like figma_get_variables and figma_get_components by focusing specifically on styles, though it does not name an alternative explicitly.

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?

The description provides context about behavior (e.g., empty result if no styles) and formats, but does not mention when to prefer this tool over related ones like figma_get_variables or figma_get_components. There is no guidance on prerequisites (e.g., authentication) or typical use cases.

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