Skip to main content
Glama

figma_variable_modes

Idempotent

Sets the variable mode (light or dark) on a node to prevent design system variables from rendering as black. Applies to all variable collections by default, or to a specific collection with collectionName.

Instructions

Sets the variable mode (e.g. light/dark) on a node — required on every new artboard, or DS variables render as black. By default sets the mode on ALL variable collections at once (pass modeIndex only). Pass collectionName to target a single collection instead. Params: nodeId (required, typically the artboard), modeIndex (required, 0=default/light, 1=dark), collectionName (optional). Requires Phase 2.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodeIdYesNode ID (typically the artboard).
modeIndexYesMode index. 0 = default/light, 1 = dark (if available).
collectionNameNoOptional — variable collection name. Omit to set the mode on ALL collections at once (recommended).
Behavior4/5

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

The description discloses that the tool modifies the node (consistent with readOnlyHint=false) and explains the mode-setting behavior for multiple collections. Annotations already provide idempotentHint=true and destructiveHint=false, which are not contradicted. The description adds context about the necessity and scope of changes.

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 very concise: three sentences followed by a param list. Every sentence adds essential information: purpose, necessity, default behavior, and parameter details. No redundant phrasing.

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?

For a simple setter with no output schema, the description adequately covers the operation, necessity, and parameter logic. It could mention return value or confirmation, but the context is sufficient for an agent to use correctly.

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 100% schema coverage, the description adds value by clarifying typical usage for nodeId ('typically the artboard'), explicit values for modeIndex (0=light, 1=dark), and the effect of omitting collectionName. This exceeds the schema descriptions.

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 verb 'Sets' and the resource 'variable mode on a node', with a specific use case ('required on every new artboard'). This distinguishes it from sibling tools like figma_update_node or figma_create_frame.

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 explains when to use ('required on every new artboard') and what happens if not used ('DS variables render as black'). It also covers the default behavior (all collections) and how to target a single collection. It does not explicitly list when not to use or alternatives, but the context is clear.

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/miapre/mimic-ai'

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