Skip to main content
Glama

Use as mask

figma_set_mask
Idempotent

Make a shape a mask (or stop it being one). A mask crops the layers ABOVE it in the same parent — put it below the image or shapes it should crop, then group them (figma_group_nodes) so the mask stays local.

Instructions

Make a shape a mask (or stop it being one). A mask crops the layers ABOVE it in the same parent — put it below the image or shapes it should crop, then group them (figma_group_nodes) so the mask stays local. maskType: alpha (default), vector (the shape's outline), luminance. Editors: Design; unverified: FigJam, Slides.

Input Schema

NameRequiredDescriptionDefault
forceNoOverwrite on purpose. A write to a node someone changed after you last read it is refused (STALE); read it again and resend instead. Pass true only when the person said to overwrite their edit.
isMaskNoDefault true; false turns the mask off.
nodeIdYes
sessionNoOptional sessionId or file name, to pick a Figma file when more than one is connected.
maskTypeNo
idempotencyKeyNoCaller-owned retry key, ≤128 chars. Re-calling with the same key never executes twice: it returns the existing result, or waits for the op still in flight. Supply your own for anything large — if the MCP client times out (rather than the bridge), only a key you chose can be used to retry safely.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.0
    • addedInput schema / properties / force
      Added value: +{
      +  "description": "Overwrite on purpose. A write to a node someone changed after you last read it is refused (STALE); read it again and resend instead. Pass true only when the person said to overwrite their edit.",
      +  "type": "boolean"
      +}
  2. First observedv0.1.1

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare it non-read-only, non-destructive, idempotent, so the safety profile is covered. The description adds genuinely useful behavior beyond that: the directional rule (crops layers ABOVE, must sit below them), and editor support scope (Design confirmed; FigJam/Slides unverified). It stops short of detailing what happens on failure, which the schema's force/stale note handles.

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?

Front-loads the core action, then the critical spatial rule, then the maskType variants and editor scope. Dense but every sentence carries distinct, actionable information with no filler.

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 node mutation with no output schema, the description covers action, spatial semantics, grouping workflow, and editor availability, enough to invoke correctly. Only minor gaps remain (e.g., behavior on target nodes already masked), which the schema's isMask default partly addresses.

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 67%, and the description compensates by explaining the most semantically complex parameter, maskType, in detail (alpha default, vector = shape outline, luminance). isMask is implied ('stop it being one') though the schema fully documents it; force/session/idempotencyKey are covered by the schema, so no gap remains.

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 ('make a shape a mask'), covers the inverse case ('stop it being one'), and distinguishes itself from siblings by naming figma_group_nodes as the required companion step. An agent can tell exactly what this does versus reorder_nodes or group_nodes.

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 concrete workflow context: put the mask below the layers it should crop, then group them so it stays local. It names the sibling to use next, but offers no explicit when-not-to-use guidance or error/exclusion conditions.

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

Deploy Server

Other Tools