# Figma — MCP server on mcp.ai > A collaborative interface design tool. By: mcp.ai · official Page: https://mcp.ai/figma ## Connect (MCP protocol) Remote MCP endpoint (HTTP, streamable): https://api.mcp.ai/p_figma?ms=1781542320000 Add it as a custom/remote MCP connector, then authenticate when prompted. ## REST API (no MCP client required) Every tool is also a REST endpoint, authed with a workspace API key. Discover: GET https://api.mcp.ai/api/figma/_endpoints # public; lists every endpoint Call: POST https://api.mcp.ai/api/figma/ Authorization: Bearer sk_live_… # create one at https://mcp.ai/settings/api-keys Content-Type: application/json Body: { …args } → { "ok": true, "tool": "", "result": { … } } ## Developer docs How to use (MCP or REST), markdown: https://mcp.ai/figma/skill.md Postman collection (v2.1): https://mcp.ai/figma/postman.json ## Tools - figma_add_a_comment_to_a_file(message: string, file_key: string, comment_id?: string, client_meta?: object) — Posts a new comment to a figma file or branch, optionally replying to an existing root comment (replies cannot be nested); `region height` and `region width` in `client meta` must be positive if defin - figma_add_a_reaction_to_a_comment(emoji: string, file_key: string, comment_id: string) — Posts a specified emoji reaction to an existing comment in a figma file or branch, requiring valid file key and comment id. - figma_create_a_webhook(status?: string, team_id: string, endpoint: string, passcode: string, event_type: string, description?: string) — Creates a figma webhook for a `team id` to send post notifications for an `event type` to a publicly accessible https `endpoint`; an initial ping is sent unless `status` is `paused`. - figma_create_dev_resources(dev_resources: object[]) — Creates and attaches multiple uniquely-urled development resources to specified figma nodes, up to 10 per node. - figma_create_modify_delete_variables(file_key: string, variables?: object[], variableModes?: object[], variableModeValues?: object[], variableCollections?: object[]) — Manages variables, collections, modes, and their values in a figma file via batch create/update/delete operations; use temporary ids to link new related items in one request and ensure `variablemodeva - figma_delete_a_comment(file_key: string, comment_id: string) — Deletes a specific comment from a figma file or branch, provided the authenticated user is the original author of the comment. - figma_delete_a_reaction(emoji: string, file_key: string, comment_id: string) — Deletes a specific emoji reaction from a comment in a figma file; the user must have originally created the reaction. - figma_delete_a_webhook(webhook_id: string) — Permanently deletes an existing webhook, identified by its unique `webhook id`; this operation is irreversible. - figma_delete_dev_resource(file_key: string, dev_resource_id: string) — Deletes a development resource (used to link figma design elements to external developer information like code or tasks) from a specified figma file. - figma_design_tokens_to_tailwind(prefix?: string, tokens: object, config_format?: string, include_font_imports?: boolean) — Convert design tokens to tailwind css configuration. takes the output from extractdesigntokens and generates: - tailwind.config.ts/js with theme extensions - optional globals.css with font imports not - figma_detect_background(file_key: string, search_depth?: integer, target_node_ids: string[]) — Detect background layers for selected nodes. uses geometric analysis, z-index ordering, and visual properties to identify potential background layers. - figma_discover_figma_resources(team_id?: string, file_key?: string, figma_url?: string, max_depth?: integer, project_id?: string) — 🔍 smart figma resource discovery - never guess ids again! 🎯 easiest method: just paste any figma url to get all ids: • file urls: https://www.figma.com/file/abc123/design → get file key • design url - figma_download_figma_images(scale?: number, images: object[], file_key: string, svg_include_id?: boolean, svg_outline_text?: boolean, svg_simplify_stroke?: boolean) — Download images from figma file nodes. renders specified nodes as images and downloads them using mercury's filedownloadable infrastructure. supports png, svg, jpg, and pdf formats. - figma_extract_design_tokens(file_key: string, include_variables?: boolean, extract_from_nodes?: boolean, include_local_styles?: boolean) — Extract design tokens from figma files. combines styles, variables, and extracted values to create a comprehensive design token system. - figma_extract_prototype_interactions(file_key: string, analyze_components?: boolean, include_animations?: boolean) — Extract prototype interactions and animations from figma files. analyzes the prototype data to extract: - user interactions (clicks, hovers, etc.) - transition animations - component variant states - - figma_get_a_webhook(webhook_id: string) — Retrieves detailed information about a specific webhook by its id, provided the webhook exists and is accessible to the user. - figma_get_activity_logs(limit?: integer, order?: string, events?: string, end_time?: integer, start_time?: integer) — Retrieves activity log events from figma, allowing filtering by event types, time range, and pagination. - figma_get_comments_in_a_file(as_md?: boolean, file_key: string) — Retrieves all comments from an existing figma file, identified by a valid `file key`, returning details like content, author, position, and reactions, with an option for markdown formatted content. - figma_get_component(node_id: string, file_key: string, simplify?: boolean) — Get component data with automatic simplification. returns clean, ai-friendly component structure. - figma_get_component_set(key: string) — Retrieves detailed metadata for a specific published figma component set using its unique `key`. - figma_get_current_user() — Retrieves detailed information for the currently authenticated figma user. - figma_get_dev_resources(file_key: string, node_ids?: string) — Retrieves development resources (e.g., jira/github links) for a figma main file, optionally filtering by specific node ids. - figma_get_file_component_sets(file_key: string) — Retrieves all published component sets from the specified figma main file (file key must not be for a branch). - figma_get_file_components(file_key: string) — Retrieves published components from a figma file, which must be a main file (not a branch) acting as a library. - figma_get_file_json(ids?: string, depth?: integer, version?: string, file_key: string, geometry?: string, simplify?: boolean, branch_data?: boolean, include_raw?: boolean, plugin_data?: string) — Get figma file data with automatic simplification. this enhanced version automatically transforms verbose figma json into clean, ai-friendly format with: - css-like property names - deduplicated varia - figma_get_file_styles(file_key: string) — Retrieves a list of published styles (like colors, text attributes, effects, and layout grids) from a specified main figma file (not a branch). - figma_get_files_in_a_project(project_id: string, branch_data?: boolean) — Fetches a list of files in a figma project, optionally including branch metadata. - figma_get_image_fills(file_key: string) — Retrieves temporary (14-day expiry) download urls for all image fills in a figma file; requires `imageref` from `paint` objects to map urls. - figma_get_library_analytics_component_action_data(cursor?: string, end_date?: string, file_key: string, group_by: string, start_date?: string) — Retrieves component insertion and detachment analytics for a specified figma library, groupable by 'component' or 'team' and filterable by a date range (yyyy-mm-dd). - figma_get_library_analytics_component_usage_data(cursor?: string, file_key: string, group_by: string) — Retrieves component usage analytics for a specified figma library file (identified by `file key`), with data groupable by 'component' or 'file'. - figma_get_library_analytics_style_action_data(cursor?: string, end_date?: string, file_key: string, group_by: string, start_date?: string) — Retrieves style usage analytics (insertions, detachments) for a figma library, grouped by 'style' or 'team'; if providing a date range, ensure end date is not before start date. - figma_get_library_analytics_style_usage_data(cursor?: string, file_key: string, group_by: string) — Retrieves style usage analytics for a figma library (specified by a valid `file key`), allowing data to be grouped by 'file' or 'style'. - figma_get_library_analytics_variable_action_data(cursor?: string, end_date?: string, file_key: string, group_by: string, start_date?: string) — Retrieves weekly, paginated analytics data on variable insertions and detachments for a specified figma library (identified by `file key`), groupable by 'variable' or 'team', and filterable by an opti - figma_get_library_analytics_variable_usage_data(cursor?: string, file_key: string, group_by: string) — Retrieves paginated analytics data on variable usage from a specified figma library, grouped by 'file' or 'variable', for libraries with enabled analytics. - figma_get_local_variables(file_key: string) — Retrieves all local/remote variables for a figma file/branch; crucial for obtaining mode-specific values which `/v1/files/{file key}/variables/published` omits. - figma_get_payments(user_id?: integer, plugin_id?: integer, widget_id?: integer, community_file_id?: integer, plugin_payment_token?: string) — Retrieves a user's payment information for a figma plugin, widget, or community file; the authenticated identity must own the resource. - figma_get_projects_in_a_team(team_id: string) — Retrieves projects within a specified figma team that are visible to the authenticated user. - figma_get_published_variables(file_key: string) — Retrieves variables published from a specified figma file; this api is available only to full members of enterprise organizations. - figma_get_reactions_for_a_comment(cursor?: string, file_key: string, comment_id: string) — Retrieves reactions for a specific comment in a figma file. - figma_get_style(key: string) — Retrieves detailed metadata for a specific style in figma using its unique style key. - figma_get_team_component_sets(after?: integer, before?: integer, team_id: string, page_size?: integer) — Retrieves a paginated list of published component sets (collections of reusable ui elements) from a specified figma team's library. - figma_get_team_components(after?: integer, before?: integer, team_id: string, page_size?: integer) — Retrieves components published in a specific figma team's library; the team must have published components, otherwise an empty list is returned. - figma_get_team_styles(after?: integer, before?: integer, team_id: string, page_size?: integer) — Retrieves a paginated list of published styles, such as colors or text attributes, from a specified figma team's library. - figma_get_team_webhooks(team_id: string) — Retrieves all webhooks registered for a specified figma team. - figma_get_versions_of_a_file(after?: integer, before?: integer, file_key: string, page_size?: integer) — Retrieves the version history for a figma file or branch, as specified by its `file key`. - figma_get_webhook_requests(webhook_id: string) — Retrieves a history of webhook requests for a specific figma webhook subscription; data is available for requests sent within the last seven days. - figma_render_images_of_file_nodes(ids: string, scale?: integer, format?: string, version?: string, file_key: string, contents_only?: boolean, svg_include_id?: boolean, svg_outline_text?: boolean, svg_include_node_id?: boolean, svg_simplify_stroke?: boolean, use_absolute_bounds?: boolean) — Renders specified nodes from a figma file as images (jpg, pdf, png, svg), returning a map of node ids to image urls (or `null` for failed nodes); images expire after 30 days and are capped at 32 megap - figma_update_a_webhook(status?: string, endpoint: string, passcode: string, event_type: string, webhook_id: string, description?: string) — Updates an existing figma webhook, identified by `webhook id`, allowing modification of its event type, endpoint, passcode, status, or description. - figma_update_dev_resources(dev_resources: object[]) — Updates the name and/or url of one or more existing figma dev resources, each identified by its unique `id`. ## Links Docs: https://mcp.ai/docs/mcps/figma Website: https://mcp.ai/mcps/figma