Skip to main content
Glama

flatten_node

Convert Figma nodes, groups, or selections into single vector layers by merging child shapes and vectors. Supports batch processing of up to 100 nodes or current selections.

Instructions

Flatten one or more nodes in Figma, or the current selection, merging all child vector layers and shapes into a single vector layer.

Returns:

  • content: Array of objects. Each object contains a type: "text" and a text field with the results for each node.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodeIdNoID of the node to flatten. Must be a Frame, Group, or node that supports flattening.
nodeIdsNoArray of Figma node IDs to flatten. Must contain 1 to 100 items.
selectionNoIf true, use the current Figma selection for the operation. If true, nodeId and nodeIds are ignored.
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It explains the flattening operation and return format, but misses details like whether this is a destructive mutation (likely, based on 'merging'), permission requirements, error handling, or rate limits. The description adds some value but leaves gaps in behavioral context.

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 the core purpose in the first sentence, followed by return details. Every sentence earns its place with zero waste, making it efficient and easy to parse for an AI agent.

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?

Given the tool's moderate complexity (3 parameters, no output schema, no annotations), the description is mostly complete. It covers the operation and return format, but lacks details on mutation behavior, error cases, or sibling tool differentiation. Without an output schema, the return explanation is helpful but could be more thorough.

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 fully documents the three parameters (nodeId, nodeIds, selection). The description mentions 'one or more nodes' and 'current selection', which aligns with but doesn't add meaning beyond the schema. Baseline 3 is appropriate as the schema does the heavy lifting.

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 clearly states the specific action ('flatten'), target resources ('one or more nodes in Figma, or the current selection'), and outcome ('merging all child vector layers and shapes into a single vector layer'). It distinguishes itself from sibling tools like 'group_node' or 'duplicate_node' by focusing on flattening rather than grouping or copying.

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 description implies usage by mentioning 'one or more nodes' and 'current selection', but lacks explicit guidance on when to use this tool versus alternatives like 'group_node' for organization or 'duplicate_node' for copying. No exclusions or prerequisites are stated, leaving the agent to infer context from the input schema.

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

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/amalinakurniasari/conduit'

If you have feedback or need assistance with the MCP directory API, please join our Discord server