Skip to main content
Glama
Figma Vector MCP

Figma Vector MCP

by workingmodel

set_auto_layout

Enable auto-layout on a Figma frame and configure direction, spacing, padding, alignment, wrapping, and sizing. Set direction to NONE to disable layout.

Instructions

Enable auto-layout on a frame and configure direction, spacing, padding, and alignment. Set direction to NONE to disable auto-layout.

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": {
      "nodeId": "<nodeId>"
    },
    "name": "set_auto_layout"
  }
}

Input Schema

NameRequiredDescriptionDefault
wrapNoEnable wrapping (WRAP)
nodeIdYesFigma node ID
paddingNoPadding — single number (all sides) or {top, right, bottom, left}
spacingNoGap between children in pixels
directionNoLayout directionHORIZONTAL
counterAxisAlignNoAlignment along cross axisMIN
primaryAxisAlignNoAlignment along main axisMIN
counterAxisSizingModeNoSizing along cross axis — FIXED holds the frame size, AUTO hugs children (default AUTO)
primaryAxisSizingModeNoSizing along main axis — FIXED holds the frame size, AUTO hugs children (default AUTO)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.3

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It discloses mutation behavior, the frame target, and a disable mechanism via direction NONE, but it omits side effects on children, frame resizing implications, permissions, error behavior, and response details.

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 two short sentences, front-loaded with purpose and followed by a critical special-case instruction. There is no unnecessary wording.

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?

The schema fully documents all 9 parameters, and the description covers the main purpose plus the NONE disable behavior. However, for a mutation tool with no annotations or output schema, it does not say enough about side effects, preconditions, or errors to be fully complete.

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. The description adds important meaning beyond the schema by explaining that direction NONE disables auto-layout and by naming key configurable fields, though it does not mention wrap or sizing-mode parameters that are documented in the schema.

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 uses a specific verb and resource: 'Enable auto-layout on a frame' and names configurable settings such as direction, spacing, padding, and alignment. It is clear about what the tool does, but it does not explicitly distinguish itself from the sibling set_layout_grid.

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 usage context by targeting a frame and provides an explicit disable path: 'Set direction to NONE to disable auto-layout.' It does not name alternatives such as set_layout_grid, so it lacks full when-to-use-versus-alternative guidance.

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