Skip to main content
Glama

Create text style

figma_create_text_style
Idempotent

A local TEXT style. lineHeight and letterSpacing are STRINGS, as in figma_set_text_properties: "auto", "32" (px) or "150%"; "0.5" or "-2%" — a bare JSON number is no longer accepted here. case (e.g.

Instructions

A local TEXT style. lineHeight and letterSpacing are STRINGS, as in figma_set_text_properties: "auto", "32" (px) or "150%"; "0.5" or "-2%" — a bare JSON number is no longer accepted here. case (e.g. upper for labels), decoration, paragraph spacing and indent are set on the style too. Change it later in place with figma_update_style. Editors: Design only.

Input Schema

NameRequiredDescriptionDefault
caseNo
nameYes
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.
weightNoFont weight as a number ("600") or a Figma style name ("Semi Bold" — Inter uses spaces, not "SemiBold").
sessionNoOptional sessionId or file name, to pick a Figma file when more than one is connected.
fontSizeYesRequired: a text style with no size is not usable.
decorationNo
fontFamilyNoDefault Inter (create); the style's own family (update).
lineHeightNo"auto", px ("32") or percent ("150%"). A string, not a number.
descriptionNoWhat the style is for — shown in Figma's style picker.
letterSpacingNopx ("0.5") or percent ("-2%"). A string, not a number.
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.
paragraphIndentNopx of first-line indent.
paragraphSpacingNopx between paragraphs.

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

A3.8/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnlyHint=false, destructiveHint=false, idempotentHint=true), so the description earns credit for adding what annotations cannot: the style is local (not a library/published style) and requires a Design-seat editor. It also flags a hard input constraint — lineHeight/letterSpacing must be strings, bare JSON numbers are rejected — which would otherwise cause a failed call.

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?

Dense and mostly front-loaded: the resource and the highest-risk parameter formats come first, then the update path, then the editor constraint. A few clauses restate schema facts (case, decoration, paragraph spacing) and the leading noun fragment is slightly awkward, but there is 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 14-parameter creation tool with no output schema and strong annotations, the description covers the things most likely to break a call: the string-encoded metrics, the editor-seat requirement, and the mutation follow-up path. It does not say what the call returns (e.g. the new style's id) or whether styles are file-scoped via the session parameter, which is a modest remaining gap.

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 79%, so the baseline is 3; the description exceeds it by spelling out the exact accepted string grammar for lineHeight ('auto', '32', '150%') and letterSpacing ('0.5', '-2%') and by flagging the breaking change that numbers are no longer accepted. It also enumerates the secondary properties (case, decoration, paragraph spacing/indent) so an agent knows the style carries more than size and weight.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening fragment 'A local TEXT style' plus the enumeration of typography properties makes clear this defines a text style, and the sibling differentiation from figma_update_style ('Change it later in place with figma_update_style') and from paint/effect styles is implicit in 'TEXT style'. It stops short of an explicit creation verb, so the reader infers 'create' from the title/name rather than the sentence itself.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It names one alternative and its condition ('change it later in place with figma_update_style') and states an access constraint ('Editors: Design only'), which is real guidance. But it gives no criteria for choosing a reusable style here versus setting text properties directly with figma_set_text_properties or placing text via figma_create_text, and no when-not guidance.

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