Skip to content
Talk to an Engineer Dashboard

Figma

Connect to Figma API v1. Read and write files, manage components, styles, variables, webhooks, and dev resources. Enterprise features include library analytics and activity logs.

Connect to Figma API v1. Read and write files, manage components, styles, variables, webhooks, and dev resources. Enterprise features include library analytics and activity logs.

Figma logo

Supports authentication: OAuth 2.0

Register your Figma app credentials with Scalekit so it can manage the OAuth 2.0 authentication flow and token lifecycle on your behalf. You’ll need a Client ID and Client Secret from the Figma Developers portal.

  1. Create a Figma connection in Scalekit

    • In Scalekit dashboard, go to Agent AuthCreate Connection. Search for Figma and click Create.

      Search for Figma and create a new connection

    • In the Configure Figma Connection panel, copy the Redirect URI. It looks like https://<SCALEKIT_ENVIRONMENT_URL>/sso/v1/oauth/<CONNECTION_ID>/callback. You’ll paste this into Figma in the next step.

      Copy the Redirect URI from the Configure Figma Connection panel

  2. Create an app in the Figma Developers portal

    • Go to the Figma Developers portal and sign in. Click + Create a new app.

      Figma Developers portal showing the My apps list and Create a new app button

    • Fill in your app name and description, then click Save.

  3. Add the redirect URI and copy credentials

    • Open your app and click the OAuth credentials tab.

    • Under Redirect URLs, click Add a redirect URL and paste the Redirect URI you copied from Scalekit.

    • Copy the Client ID from the same tab.

    • Copy the Client Secret. Store it securely — never commit it to source control.

      Figma app OAuth credentials tab showing Client ID, Client Secret, and Redirect URLs

  4. Add credentials in Scalekit

    • In Scalekit dashboard, go to Agent AuthConnections and open the Figma connection you created.

    • Enter your credentials:

      • Client ID — from the Figma OAuth credentials tab
      • Client Secret — copied in the previous step
      • Scopes — select the permissions your app needs:
        • files:read — read files, nodes, images, components, and styles
        • file_variables:read — read local and published variables
        • file_variables:write — create, update, and delete variables
        • webhooks:write — create, update, and delete team webhooks

      Scalekit Figma connection with Client ID, Client Secret, and scopes filled in

    • Click Save.

Connect a user’s Figma account and make API calls on their behalf — Scalekit handles OAuth and token management automatically.

You can interact with Figma in two ways — via direct proxy API calls or via Scalekit optimized tool calls. Scroll down to see the list of available Scalekit tools.

Proxy API calls

import { ScalekitClient } from '@scalekit-sdk/node';
import 'dotenv/config';
const connectionName = 'figma'; // get your connection name from connection configurations
const identifier = 'user_123'; // your unique user identifier
// Get your credentials from app.scalekit.com → Developers → Settings → API Credentials
const scalekit = new ScalekitClient(
process.env.SCALEKIT_ENV_URL,
process.env.SCALEKIT_CLIENT_ID,
process.env.SCALEKIT_CLIENT_SECRET
);
const actions = scalekit.actions;
// Step 1: Generate an authorization link and present it to your user
const { link } = await actions.getAuthorizationLink({
connectionName,
identifier,
});
console.log('Authorize Figma:', link);
process.stdout.write('Press Enter after authorizing...');
await new Promise(r => process.stdin.once('data', r));
// Step 2: Make API requests via the Scalekit proxy — no token management needed
const me = await actions.request({
connectionName,
identifier,
path: '/v1/me',
method: 'GET',
});
console.log('Authenticated user:', me);
// Example: fetch a file's document tree
const file = await actions.request({
connectionName,
identifier,
path: '/v1/files/YOUR_FILE_KEY',
method: 'GET',
});
console.log('File:', file);

Scalekit tools

Returns the authenticated user’s profile information including name, email, handle, and profile image URL. No parameters required.

Returns a Figma file’s full document tree including all nodes, components, styles, and metadata.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file (found in the file URL)
versionstringNoA specific version ID to retrieve; omit for the latest version
idsstringNoComma-separated list of node IDs to limit the response to specific nodes
depthintegerNoMaximum depth of the document tree to return
geometrystringNoSet to paths to export vector path data for nodes
plugin_datastringNoComma-separated list of plugin IDs to include plugin-specific data
branch_databooleanNoWhether to include branch metadata in the response

Returns specific nodes from a Figma file by their node IDs, along with their children and associated styles and components.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
idsstringYesComma-separated list of node IDs to fetch
versionstringNoA specific version ID to retrieve
depthintegerNoMaximum depth of the subtree to return
geometrystringNoSet to paths to export vector path data
plugin_datastringNoComma-separated list of plugin IDs for plugin-specific data

Renders nodes from a Figma file as images (PNG, JPG, SVG, or PDF) and returns download URLs.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
idsstringYesComma-separated list of node IDs to render
scalenumberNoImage scale factor between 0.01 and 4 (default: 1)
formatstringNoOutput format: png, jpg, svg, or pdf (default: png)
svg_include_idbooleanNoWhether to include node IDs as attributes in SVG output
svg_simplify_strokebooleanNoWhether to simplify inside/outside strokes in SVG output
use_absolute_boundsbooleanNoWhether to use the node’s absolute bounding box for cropping
versionstringNoA specific version ID to render

Returns download URLs for all image fills used in a Figma file. Image fills are images applied as fills to nodes.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Returns the version history of a Figma file, including version IDs, labels, descriptions, and creation timestamps.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
page_sizeintegerNoNumber of versions to return per page
beforeintegerNoCursor for backward pagination; returns versions before this version ID
afterintegerNoCursor for forward pagination; returns versions after this version ID

Returns all comments on a Figma file, including their text, author, position, and resolved status.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
as_mdbooleanNoWhether to return comment text formatted as Markdown

Posts a new comment on a Figma file. Can be placed at a specific canvas position or anchored to a specific node.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
messagestringYesThe text content of the comment
client_metaobjectNoCoordinates or node anchor for placing the comment on the canvas
comment_idstringNoID of the parent comment to reply to an existing thread

Deletes a specific comment from a Figma file. Only the comment author or file owner can delete a comment.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
comment_idstringYesThe ID of the comment to delete

Returns a list of emoji reactions on a specific comment in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
comment_idstringYesThe ID of the comment to list reactions for
cursorstringNoPagination cursor for fetching the next page of results

Adds an emoji reaction to a comment in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
comment_idstringYesThe ID of the comment to react to
emojistringYesThe emoji to add as a reaction (e.g., :heart:, :+1:)

Removes the authenticated user’s emoji reaction from a comment in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
comment_idstringYesThe ID of the comment to remove the reaction from
emojistringYesThe emoji reaction to remove (e.g., :heart:, :+1:)

Returns a list of all published components in a Figma file, including their keys, names, descriptions, and thumbnails.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Returns metadata for a published component by its key, including name, description, thumbnail, and containing file information.

NameTypeRequiredDescription
keystringYesThe key of the published component (from figma_file_components_list)

Returns all published component sets in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Returns metadata for a published component set (a group of related component variants) by its key.

NameTypeRequiredDescription
keystringYesThe key of the published component set

Returns all published components in a Figma team library, with pagination support.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team
page_sizeintegerNoNumber of components to return per page
afterintegerNoCursor for forward pagination
beforeintegerNoCursor for backward pagination

Returns all published component sets in a Figma team library, with pagination support.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team
page_sizeintegerNoNumber of component sets to return per page
afterintegerNoCursor for forward pagination
beforeintegerNoCursor for backward pagination

Returns all published styles in a Figma file, including color, text, effect, and grid styles.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Returns metadata for a published style by its key, including name, description, style type, and containing file information.

NameTypeRequiredDescription
keystringYesThe key of the published style

Returns all published styles in a Figma team library, with pagination support.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team
page_sizeintegerNoNumber of styles to return per page
afterintegerNoCursor for forward pagination
beforeintegerNoCursor for backward pagination

Returns all local variables and variable collections defined in a Figma file. Requires the file_variables:read scope.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Returns all published variables and variable collections from a Figma file’s library. Requires the file_variables:read scope.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file

Creates, updates, or deletes variables and variable collections in a Figma file. Accepts a JSON payload describing the changes. Requires the file_variables:write scope.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
variableCollectionsarrayNoVariable collection changes: create, update, or delete collections
variableModesarrayNoVariable mode changes: create, update, or delete modes within collections
variablesarrayNoVariable changes: create, update, or delete individual variables

Returns metadata about a Figma team, including its name and member count.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team

Returns all projects within a Figma team that the authenticated user has access to.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team

Returns all files in a Figma project, including file keys, names, thumbnails, and last modified timestamps.

NameTypeRequiredDescription
project_idstringYesThe ID of the Figma project
branch_databooleanNoWhether to include branch metadata for each file

Returns dev resources (links to external tools like Storybook, Jira, etc.) attached to nodes in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
node_idstringNoFilter results to dev resources attached to a specific node ID

Creates a dev resource (external link) attached to a node in a Figma file, such as a link to Storybook, Jira, or documentation.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
node_idstringYesThe ID of the node to attach the dev resource to
namestringYesDisplay name for the dev resource link
urlstringYesThe URL of the external resource

Updates an existing dev resource attached to a node in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
dev_resource_idstringYesThe ID of the dev resource to update
namestringNoUpdated display name for the dev resource
urlstringNoUpdated URL for the dev resource

Permanently deletes a dev resource from a node in a Figma file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the Figma file
dev_resource_idstringYesThe ID of the dev resource to delete

Creates a new webhook that sends events to the specified endpoint URL when Figma events occur in a team. Requires the webhooks:write scope.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team to register the webhook for
event_typestringYesThe event type that triggers the webhook (e.g., FILE_UPDATE, FILE_VERSION_UPDATE, FILE_DELETE, LIBRARY_PUBLISH, FILE_COMMENT)
endpointstringYesThe HTTPS URL that receives webhook POST requests
passcodestringYesA secret string included in each webhook payload for request verification
statusstringNoWebhook status: ACTIVE or PAUSED (default: ACTIVE)
descriptionstringNoA human-readable description of the webhook’s purpose

Returns details of a specific Figma webhook by its ID, including event type, endpoint, and status.

NameTypeRequiredDescription
webhook_idstringYesThe ID of the webhook to retrieve

Updates an existing Figma webhook’s endpoint, passcode, status, or description.

NameTypeRequiredDescription
webhook_idstringYesThe ID of the webhook to update
endpointstringNoUpdated HTTPS URL to receive webhook events
passcodestringNoUpdated secret for verifying webhook payloads
statusstringNoUpdated status: ACTIVE or PAUSED
descriptionstringNoUpdated description for the webhook

Permanently deletes a Figma webhook. This stops all future event deliveries for this webhook.

NameTypeRequiredDescription
webhook_idstringYesThe ID of the webhook to delete

Returns all webhooks registered for a Figma team.

NameTypeRequiredDescription
team_idstringYesThe ID of the Figma team

Returns the delivery history for a webhook, including request payloads, response codes, and timestamps.

NameTypeRequiredDescription
webhook_idstringYesThe ID of the webhook to fetch request history for

Returns payment and plan information for a Figma user or resource, including subscription status and plan type.

NameTypeRequiredDescription
user_idstringNoThe ID of the user to check payment status for
community_file_idstringNoThe ID of a community file to check resource payment status
plugin_idstringNoThe ID of a plugin to check payment status for

Returns activity log events for an organization. Includes events for file edits, permissions changes, and user actions.

NameTypeRequiredDescription
org_idstringYesThe ID of the Figma organization
eventsstringNoComma-separated list of event types to filter by
start_timeintegerNoUnix timestamp (seconds) for the start of the time range
end_timeintegerNoUnix timestamp (seconds) for the end of the time range
limitintegerNoNumber of events to return per page
next_pagestringNoPagination cursor returned by the previous response

figma_library_analytics_component_actions_get

Section titled “figma_library_analytics_component_actions_get”

Returns analytics data on component insertion, detachment, and usage actions from a library file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: component or team
start_datestringNoStart date for the analytics range (ISO 8601 format, e.g., 2024-01-01)
end_datestringNoEnd date for the analytics range (ISO 8601 format)
orderstringNoSort order for results: asc or desc
cursorstringNoPagination cursor for the next page of results

figma_library_analytics_component_usages_get

Section titled “figma_library_analytics_component_usages_get”

Returns a snapshot of how many times each component from a library is used across the organization.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: component or team
cursorstringNoPagination cursor for the next page of results

Returns analytics data on style insertion and detachment actions from a library file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: style or team
start_datestringNoStart date for the analytics range (ISO 8601 format)
end_datestringNoEnd date for the analytics range (ISO 8601 format)
orderstringNoSort order for results: asc or desc
cursorstringNoPagination cursor for the next page of results

Returns a snapshot of how many times each style from a library is used across the organization.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: style or team
cursorstringNoPagination cursor for the next page of results

figma_library_analytics_variable_actions_get

Section titled “figma_library_analytics_variable_actions_get”

Returns analytics data on variable actions from a library file.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: variable or team
start_datestringNoStart date for the analytics range (ISO 8601 format)
end_datestringNoEnd date for the analytics range (ISO 8601 format)
orderstringNoSort order for results: asc or desc
cursorstringNoPagination cursor for the next page of results

figma_library_analytics_variable_usages_get

Section titled “figma_library_analytics_variable_usages_get”

Returns a snapshot of how many times each variable from a library is used across the organization.

NameTypeRequiredDescription
file_keystringYesThe unique key identifying the library file
group_bystringYesDimension to group results by: variable or team
cursorstringNoPagination cursor for the next page of results