Skip to main content
Glama

get_styles

Retrieve all design styles from your current Figma document to maintain consistency and accelerate design workflows.

Instructions

Get all styles from the current Figma document

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The complete handler implementation for the 'get_styles' MCP tool. It registers the tool with an empty input schema and executes by sending a 'get_styles' command to the Figma plugin via sendCommandToFigma, returning the result as a text/JSON content block or an error message.
    // Get Styles Tool server.tool( "get_styles", "Get all styles from the current Figma document", {}, async () => { try { const result = await sendCommandToFigma("get_styles"); return { content: [ { type: "text", text: JSON.stringify(result) } ] }; } catch (error) { return { content: [ { type: "text", text: `Error getting styles: ${error instanceof Error ? error.message : String(error)}`, }, ], }; } } );
  • Higher-level registration where document tools (including get_styles) are registered to the MCP server via registerDocumentTools.
    export function registerTools(server: McpServer): void { // Register all tool categories registerDocumentTools(server); registerCreationTools(server); registerModificationTools(server); registerTextTools(server); registerComponentTools(server); }
  • Top-level server initialization where all tools are registered by calling registerTools.
    registerTools(server);

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/arinspunk/claude-talk-to-figma-mcp'

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