Skip to main content
Glama

set_strokes

Apply SOLID or gradient strokes to a Figma node, adjusting weight, alignment, dash pattern, and per-side weights. Returns ok and nodeId.

Instructions

Set a node's strokes (SOLID or gradient paints, same shape as set_fills) plus optional strokeWeight, strokeAlign (INSIDE / OUTSIDE / CENTER), dashPattern (dashes), and per-side weights (strokeTopWeight / strokeRightWeight / strokeBottomWeight / strokeLeftWeight — for nodes that support individual stroke weights, e.g. a border-bottom-only divider). A per-side weight overrides strokeWeight for that side. Any field may be omitted to leave it unchanged. Returns { ok, nodeId }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nodeIdYesFigma node id
strokesYesStroke paints
dashPatternNoDash/gap lengths in px, e.g. [4, 2]; [] for a solid stroke
strokeAlignNoStroke position relative to the geometry
strokeWeightNoUniform stroke thickness in px
strokeTopWeightNoTop side weight in px
strokeLeftWeightNoLeft side weight in px
strokeRightWeightNoRight side weight in px
strokeBottomWeightNoBottom side weight in px
Behavior4/5

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

Describes mutation (consistent with readOnlyHint=false), notes per-side weight override behavior, and returns { ok, nodeId }. Does not specify which nodes support individual stroke weights or mention authorization.

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?

Well-structured with front-loaded main purpose, followed by optional parameters, special behavior, and return type. Every sentence is informative with no unnecessary words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Comprehensive coverage of the 9-parameter tool: explains strokes array, all optional parameters, per-side weight interaction, and return format. No output schema needed since return is simple.

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%, but description adds value by clarifying the relationship between strokeWeight and per-side weights (overrides), referencing set_fills for strokes array format, and providing an example (border-bottom-only divider).

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?

Clearly states it sets node strokes, listing specific types (SOLID/gradient) and optional parameters including per-side weights. Distinguishes from sibling set_fills by referencing 'same shape as set_fills' and specifying stroke-specific parameters.

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?

States that any omitted field leaves it unchanged, providing partial update guidance. Does not explicitly mention when not to use or alternative tools, but the context of setting strokes 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/awdr74100/figwright'

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