Skip to main content
Glama

inspect

Summarize a saved Figma .fig node by ID or URL to get layout, typography, text previews, fill colors, annotations, and child counts without opening Figma or using the API.

Instructions

Compact expanded node summary with path, the node's ancestors from the document down ([{id, name}] as in find; for a layer, path[1] is its page), so a pasted link's screen needs no find: bounds, layout, typography, text previews (fullText=true for complete text), Dev Mode annotation label previews and Ready for dev devStatus, and child counts. colors=true adds resolved solid fill colors with bound variables; other paints stay in nodes. A parent without auto-layout has childSpacing "derived": gaps between its children are coordinate differences, not an auto-layout rule; constraints may still pin them. For image decisions, images=true adds original dimensions/bytes and source-pixel rectangles before masks, not blur diagnoses. Depth and a 200-node budget bound the summary; image paints have their own 200-item limit. nodes returns full design data.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "file": "<file>",
      "node": "<node>"
    },
    "name": "inspect"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileYesthe saved .fig: a local path (absolute recommended), or gs://bucket/object using gcloud; remote sources are unavailable with --root
flatNoone line per node instead of node JSON, for scanning a screen against an implementation: id, type, name, @x,y WxH relative to the inspected node, then hidden, rot, component, devStatus=READY_FOR_DEV|COMPLETED, annotations=N (a count; notes are in the JSON form), text, font=family size/weight/lineHeight, fill, stroke=paint/weight, r, visible effects (shadow|inner-shadow=x,y,blur[,spread],color, blur=, bg-blur=), H|V gap or GRID RxC gap=row,col rows=… cols=… (stored track sizes: flexN, px, hug or min..max; ? when unstored), pad=top,right,bottom,left, align=main/cross unless both min, size=w/h (fixed|fill|hug) unless both hug (or spacing=derived without auto-layout), span=rows,cols on grid children, opacity when set; children=N and '… N more' mark omitted nodes; same depth and node limits; not combinable with images, states or compareVariant; default false
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=
depthNo0-10 levels below the node, default 1; text previews up to 200 characters
colorsNoadd solidFills to nodes with visible SOLID fills (TEXT color, frame and shape fills): hex, opacity when the paint is below 1 (paint alpha x paint opacity, not ancestor or node opacity) and the bound color variableId/variableName; with flat, a fill shows a $variable suffix. Gradients, images, strokes, effects and vector geometry are not included (use nodes); default false
imagesNoinclude source bitmap dimensions/bytes and per-paint source-pixel crop rectangles; no files written
statesNoinclude bounded variants and prototype field evidence with exact sources/unknowns; retains instance overrides, infers no business conditions and renders no other variants
compareNocompare node with any other stored node of the file (another frame, breakpoint or state; no component set needed) with the same bounded raw-field differences, per-pair changes, unpaired nodes and exact sources as compareVariant, plus rootDelta (size and parent-relative position); children pair by unique name, then unique main component, then stacking order in equal-sized same-name groups (pairedBy), the rest are reported unpaired as ambiguous-name; instances are not expanded; an ancestor or descendant is rejected; adds comparison
fullTextNoreturn the complete characters of each TEXT node (up to 10000 characters, textTruncated beyond) instead of the 200-character preview; also applies to flat; the node and reply budgets still apply; default false
compareVariantNocompare node with this other stored variant in the same component set; adds bounded raw-field differences, per-pair changes for children paired by unique name, main component or equal-count stacking order (check pairedBy; order is the weakest evidence), other descendants' value multisets, exact sources and bound variable names; no alternate rendering or business inference

Output Schema

NameRequiredDescriptionDefault
flatNothe one-line-per-node text when flat=true, instead of node
nodeNoCompact node with partial layout semantics and type-only property definitions; childSpacing "derived" marks a parent without auto-layout; _figlens.semantics records source and state (a missing entry means the field is not stored); the top-level _figlens.semantics.verification applies to all nodes. Definitions, definition evidence, annotations (plain label previews, labelTruncated when cut; at most 20 properties each) and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries; with colors=true, nodes with visible SOLID fills carry solidFills [{hex, opacity?, variableId?, variableName?}]
pathNothe node's ancestors from the document down to the node itself, find's path shape; an instance sublayer's path continues through its expanded parents; absent with flat=true
imagesNooptional source image evidence when images=true
statesNooptional variants and prototype field evidence when states=true; independent truncation, source file, node/override provenance and unknown markers; no inferred business logic
_figlensNosemantics.verification: whether every node's _figlens.semantics was compared with Figma exports (not-compared-with-figma)
truncatedYes
comparisonNooptional any-two-nodes definition comparison when compare is supplied; same shape as variantComparison without componentSetId, plus rootDelta and a reason on each unpaired node (ambiguous-name, name-truncated, no-counterpart); not a pixel comparison
variantComparisonNooptional same-set definition comparison when compareVariant is supplied; raw fields, paired children, descendant value multisets, unpaired nodes, unknowns and independent truncation; not a pixel comparison
handoffDiagnosticsNooptional known stored semantics not emitted by the projection; counts cover the selected expanded subtree independently of summary depth, with at most five example IDs per feature and explicit coverage limits
annotationCategoriesNooptional {categoryId: {label, isPreset, color?, labelTruncated?}} for the categories the kept annotations name

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.13.1
    • changedInput schema / properties / flat / description
      Previous value: -"one line per node instead of node JSON, for scanning a screen against an implementation: id, type, name, @x,y WxH relative to the inspected node, then hidden, rot, component, text, font=family size/weight/lineHeight, fill, stroke=paint/weight, r, visible effects (shadow|inner-shadow=x,y,blur[,spread],color, blur=, bg-blur=), H|V gap or GRID (grid gaps are not decoded), pad=top,right,bottom,left, align=main/cross unless both min, size=w/h (fixed|fill|hug) unless both hug (or spacing=derived without auto-layout), opacity when set; children=N and '… N more' mark omitted nodes; same depth and node limits; not combinable with images, states or compareVariant; default false"New value: +"one line per node instead of node JSON, for scanning a screen against an implementation: id, type, name, @x,y WxH relative to the inspected node, then hidden, rot, component, devStatus=READY_FOR_DEV|COMPLETED, annotations=N (a count; notes are in the JSON form), text, font=family size/weight/lineHeight, fill, stroke=paint/weight, r, visible effects (shadow|inner-shadow=x,y,blur[,spread],color, blur=, bg-blur=), H|V gap or GRID RxC gap=row,col rows=… cols=… (stored track sizes: flexN, px, hug or min..max; ? when unstored), pad=top,right,bottom,left, align=main/cross unless both min, size=w/h (fixed|fill|hug) unless both hug (or spacing=derived without auto-layout), span=rows,cols on grid children, opacity when set; children=N and '… N more' mark omitted nodes; same depth and node limits; not combinable with images, states or compareVariant; default false"
    • addedOutput schema / properties / _figlens
      Added value: +{
      +  "description": "semantics.verification: whether every node's _figlens.semantics was compared with Figma exports (not-compared-with-figma)",
      +  "type": "object"
      +}
    • addedOutput schema / properties / annotationCategories
      Added value: +{
      +  "description": "optional {categoryId: {label, isPreset, color?, labelTruncated?}} for the categories the kept annotations name",
      +  "type": "object"
      +}
    • changedOutput schema / properties / node / description
      Previous value: -"Compact node with partial layout semantics and type-only property definitions; childSpacing \"derived\" marks a parent without auto-layout; _figlens.semantics records source/verification. Definitions, definition evidence and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries; with colors=true, nodes with visible SOLID fills carry solidFills [{hex, opacity?, variableId?, variableName?}]"New value: +"Compact node with partial layout semantics and type-only property definitions; childSpacing \"derived\" marks a parent without auto-layout; _figlens.semantics records source and state (a missing entry means the field is not stored); the top-level _figlens.semantics.verification applies to all nodes. Definitions, definition evidence, annotations (plain label previews, labelTruncated when cut; at most 20 properties each) and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries; with colors=true, nodes with visible SOLID fills carry solidFills [{hex, opacity?, variableId?, variableName?}]"
    • addedOutput schema / properties / path
      Added value: +{
      +  "description": "the node's ancestors from the document down to the node itself, find's path shape; an instance sublayer's path continues through its expanded parents; absent with flat=true",
      +  "items": {
      +    "properties": {
      +      "id": {
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      }
      +    },
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  2. Changed10 schema fields changedv0.11.3
    • addedInput schema / properties / colors
      Added value: +{
      +  "default": false,
      +  "description": "add solidFills to nodes with visible SOLID fills (TEXT color, frame and shape fills): hex, opacity when the paint is below 1 (paint alpha x paint opacity, not ancestor or node opacity) and the bound color variableId/variableName; with flat, a fill shows a $variable suffix. Gradients, images, strokes, effects and vector geometry are not included (use nodes); default false",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / compare
      Added value: +{
      +  "description": "compare node with any other stored node of the file (another frame, breakpoint or state; no component set needed) with the same bounded raw-field differences, per-pair changes, unpaired nodes and exact sources as compareVariant, plus rootDelta (size and parent-relative position); children pair by unique name, then unique main component, then stacking order in equal-sized same-name groups (pairedBy), the rest are reported unpaired as ambiguous-name; instances are not expanded; an ancestor or descendant is rejected; adds comparison",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • changedInput schema / properties / compareVariant / description
      Previous value: -"compare node with this other stored variant in the same component set; adds bounded raw-field and descendant-multiset differences, exact sources and unknown pairing; no alternate rendering or business inference"New value: +"compare node with this other stored variant in the same component set; adds bounded raw-field differences, per-pair changes for children paired by unique name, main component or equal-count stacking order (check pairedBy; order is the weakest evidence), other descendants' value multisets, exact sources and bound variable names; no alternate rendering or business inference"
    • addedInput schema / properties / flat
      Added value: +{
      +  "default": false,
      +  "description": "one line per node instead of node JSON, for scanning a screen against an implementation: id, type, name, @x,y WxH relative to the inspected node, then hidden, rot, component, text, font=family size/weight/lineHeight, fill, stroke=paint/weight, r, visible effects (shadow|inner-shadow=x,y,blur[,spread],color, blur=, bg-blur=), H|V gap or GRID (grid gaps are not decoded), pad=top,right,bottom,left, align=main/cross unless both min, size=w/h (fixed|fill|hug) unless both hug (or spacing=derived without auto-layout), opacity when set; children=N and '… N more' mark omitted nodes; same depth and node limits; not combinable with images, states or compareVariant; default false",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / fullText
      Added value: +{
      +  "default": false,
      +  "description": "return the complete characters of each TEXT node (up to 10000 characters, textTruncated beyond) instead of the 200-character preview; also applies to flat; the node and reply budgets still apply; default false",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / comparison
      Added value: +{
      +  "description": "optional any-two-nodes definition comparison when compare is supplied; same shape as variantComparison without componentSetId, plus rootDelta and a reason on each unpaired node (ambiguous-name, name-truncated, no-counterpart); not a pixel comparison",
      +  "type": "object"
      +}
    • addedOutput schema / properties / flat
      Added value: +{
      +  "description": "the one-line-per-node text when flat=true, instead of node",
      +  "type": "string"
      +}
    • changedOutput schema / properties / node / description
      Previous value: -"Compact node with partial layout semantics and type-only property definitions; _figlens.semantics records source/verification. Definitions, definition evidence and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries"New value: +"Compact node with partial layout semantics and type-only property definitions; childSpacing \"derived\" marks a parent without auto-layout; _figlens.semantics records source/verification. Definitions, definition evidence and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries; with colors=true, nodes with visible SOLID fills carry solidFills [{hex, opacity?, variableId?, variableName?}]"
    • changedOutput schema / properties / variantComparison / description
      Previous value: -"optional same-set definition comparison when compareVariant is supplied; raw fields, descendant value multisets, unpaired nodes, unknowns and independent truncation; not a pixel comparison"New value: +"optional same-set definition comparison when compareVariant is supplied; raw fields, paired children, descendant value multisets, unpaired nodes, unknowns and independent truncation; not a pixel comparison"
    • changedOutput schema / required
      Previous value: -[
      -  "node",
      -  "truncated"
      -]New value: +[
      +  "truncated"
      +]
  3. Changed2 schema fields changedv0.9.3
    • changedInput schema / additionalProperties
      Previous value: -trueNew value: +false
    • addedOutput schema / properties / handoffDiagnostics
      Added value: +{
      +  "description": "optional known stored semantics not emitted by the projection; counts cover the selected expanded subtree independently of summary depth, with at most five example IDs per feature and explicit coverage limits",
      +  "type": "object"
      +}
  4. Changed13 schema fields changedv0.7.2
    • addedInput schema / additionalProperties
      Added value: +true
    • addedInput schema / properties / compareVariant
      Added value: +{
      +  "description": "compare node with this other stored variant in the same component set; adds bounded raw-field and descendant-multiset differences, exact sources and unknown pairing; no alternate rendering or business inference",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / depth / default
      Added value: +1
    • addedInput schema / properties / depth / maximum
      Added value: +10
    • addedInput schema / properties / depth / minimum
      Added value: +0
    • 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
    • addedInput schema / properties / images / default
      Added value: +false
    • 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="
    • addedInput schema / properties / states
      Added value: +{
      +  "default": false,
      +  "description": "include bounded variants and prototype field evidence with exact sources/unknowns; retains instance overrides, infers no business conditions and renders no other variants",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / node / description
      Added value: +"Compact node with partial layout semantics and type-only property definitions; _figlens.semantics records source/verification. Definitions, definition evidence and _figlens.renderDiagnostics each have at most 20 entries per node; truncated includes omitted nodes or entries"
    • addedOutput schema / properties / states
      Added value: +{
      +  "description": "optional variants and prototype field evidence when states=true; independent truncation, source file, node/override provenance and unknown markers; no inferred business logic",
      +  "type": "object"
      +}
    • addedOutput schema / properties / variantComparison
      Added value: +{
      +  "description": "optional same-set definition comparison when compareVariant is supplied; raw fields, descendant value multisets, unpaired nodes, unknowns and independent truncation; not a pixel comparison",
      +  "type": "object"
      +}
  5. Changed2 schema fields changedv0.5.0
    • addedInput schema / properties / images
      Added value: +{
      +  "description": "include source bitmap dimensions/bytes and per-paint source-pixel crop rectangles; no files written",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / images
      Added value: +{
      +  "description": "optional source image evidence when images=true",
      +  "type": "object"
      +}
  6. First observed

TDQS

A3.6/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 and does so substantively: it discloses the depth cap, the 200-node budget, the separate 200-item image-paint limit, the 200-character preview vs 10000-character fullText cap, and states "no files written". It also flags rejected inputs for `compare` (ancestor/descendant) and inherited limits for flat. It never explicitly says the call is read-only or side-effect free beyond "no files written".

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Every clause carries information, but the description is a single dense run-on block that opens with its return shape rather than its purpose, so the key function is not front-loaded. Length is partly justified by ten parameters, yet readability suffers and the reader must reconstruct the purpose from the feature list.

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?

It covers budgets, depth limits, incompatible flag combinations, comparison pairing rules, and what is deliberately excluded from `colors` (gradients, images, strokes, vector geometry). The extensive return-shape prose is somewhat redundant given a declared output schema, but not harmful; the definition is thorough for a ten-parameter inspection tool.

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 description coverage is 100%, so the schema already documents all ten parameters in equivalent detail, and the description largely restates it (colors, images, fullText, depth). The genuine additions are combination rules not present in the schema, such as flat being incompatible with images/states/compareVariant and pairedBy being "the weakest evidence" for compareVariant. Baseline 3 applies since the schema does the heavy lifting.

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 names a specific artifact (an expanded node summary) and enumerates exactly what it contains: path, ancestors, bounds, layout, typography, text previews, devStatus and child counts. It also distinguishes itself from the sibling `nodes` ("nodes returns full design data"), though the opening is a noun phrase rather than a verb, so the action itself is implicit.

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?

Usage is implied through intent phrases such as "so a pasted link's screen needs no find" and "For image decisions, images=true", and it points to `nodes` as the fallback for gradients/images/strokes/effects. However, there is no explicit when-to-use-this-instead-of-siblings statement, and exclusions are buried mid-sentence (e.g. flat is "not combinable with images, states or compareVariant").

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