Skip to main content
Glama
yhoyoex

OpenCode Figma MCP

by yhoyoex

set_reactions

Replace all prototype reactions on a Figma node with raw Plugin API Reaction objects to handle advanced triggers like SET_VARIABLE, CONDITIONAL, or ON_KEY_DOWN.

Instructions

Replace all prototype reactions of a node with raw Figma Plugin API Reaction objects ({ trigger, actions: [...] }). Use for advanced cases (e.g. SET_VARIABLE, CONDITIONAL, ON_KEY_DOWN). Trigger timeout/delay are in milliseconds, transition duration in seconds.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodeIdYesID of the node
reactionsYesArray of raw Reaction objects; an empty array removes all reactions

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.1

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral load and does disclose the key trait: this REPLACES all existing reactions (destructive of prior state), and it documents non-obvious unit conventions (trigger timeout/delay in ms, transition duration in seconds). It omits anything about permissions, error behavior, or node-state requirements, so it is strong but not exhaustive.

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

Conciseness4/5

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

Three tight sentences, front-loaded with the core action and free of filler. The opening sentence is dense but the payload shape is parenthetically scoped, and the unit caveats are correctly placed as supporting detail rather than preamble.

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 2-parameter mutation tool with full schema coverage and no output schema or annotations, the description covers the essentials: replacement semantics, the raw-object format, when to prefer it, and unit conventions. Remaining gaps (permissions, failure modes, node-state prerequisites) are minor rather than blocking.

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 coverage is 100%, so the two parameters are already documented (including that an empty array clears reactions). The description adds value beyond the schema by specifying the internal shape of each Reaction object and, importantly, the unit semantics of timeout/delay versus transition duration — genuine interpretation aid for freeform nested fields the schema leaves open.

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?

States a specific verb+resource ('Replace all prototype reactions of a node') with the payload type named (raw Figma Plugin API Reaction objects with trigger/actions shape). It implicitly distinguishes itself from the simpler siblings by flagging 'advanced cases (e.g. SET_VARIABLE, CONDITIONAL, ON_KEY_DOWN)', so an agent can tell when this is the right tool versus add_interaction/remove_interactions.

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?

Gives clear context for selecting this tool: it is the escape hatch for advanced reaction features not covered by simpler helpers, with three concrete example triggers. It does not explicitly name the alternative sibling (add_interaction) or state a when-not condition, so it falls short of a full 5.

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