Skip to main content
Glama

set_auto_layout

Configure a frame's auto layout: disable, enable flex (horizontal/vertical) with padding and spacing, or enable CSS Grid with row/column counts and gaps. Returns success status.

Instructions

Configure a frame's auto layout. layoutMode NONE disables it; HORIZONTAL/VERTICAL enable flex (padding / itemSpacing / alignment / wrap); GRID enables CSS-Grid-style layout (padding / gridRowCount / gridColumnCount / gridRowGap / gridColumnGap). Returns { ok, nodeId }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodeIdYes
gridRowGapNo
layoutModeYes
layoutWrapNo
paddingTopNo
itemSpacingNo
paddingLeftNo
gridRowCountNo
paddingRightNo
gridColumnGapNo
paddingBottomNo
gridColumnCountNo
counterAxisAlignItemsNo
primaryAxisAlignItemsNo
Behavior4/5

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

Annotations indicate readOnlyHint=false and destructiveHint=false, so the tool is a non-destructive write. The description adds value by explaining that the tool modifies auto layout settings and returns { ok, nodeId }. It details behavior per mode, going beyond annotations.

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 sentences: first states purpose, second explains modes and parameters with returns. No fluff, every word earns its place. Highly efficient.

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 14 parameters, no output schema, and no param descriptions, the description covers the core logic and parameter grouping. It lacks details on optionality and exact parameter names but provides a solid high-level understanding. Could mention that nodeId and layoutMode are required.

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?

With 0% schema description coverage, the description must compensate. It groups parameters by mode (e.g., 'padding / itemSpacing / alignment / wrap' for flex; 'gridRowCount / gridColumnCount / gridRowGap / gridColumnGap' for grid), adding semantic meaning. It does not individually document all 14 parameters but provides sufficient context.

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 tool's purpose: 'Configure a frame's auto layout.' It then details the three layout modes (NONE, HORIZONTAL/VERTICAL, GRID) and the parameters associated with each, distinguishing it from sibling tools like set_layout_props which handle other layout properties.

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?

The description provides context on when to use each mode: NONE disables, HORIZONTAL/VERTICAL enable flex, GRID enables CSS-grid. It does not explicitly state when not to use this tool or mention alternatives, but the mode-specific guidance gives clear usage context.

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

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/awdr74100/figwright'

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