figma library

Figma API client library.

To get started, retrieve your Figma access token here and start making requests.

Classes

Action
An action that is performed when a trigger is activated.
AfterTimeoutTrigger
AnnotationsTrait
ArcData
Information about the arc properties of an ellipse.
BaseTypeStyle
BlurEffect
BlurEffectVariables
The variables bound to a particular field on this blur effect.
BooleanOperationNode
Branch
Canvas
ColorStop
A single color stop with its position along the gradient axis, color, and bound variables if any.
ColorStopVariables
The variables bound to a particular gradient stop.
Comment
A comment or reply left by a user.
CommentFragment
An object representing a fragment of a comment left by a user, used in the payload of the FILE_COMMENT event.
CommentsResponse
ComplexStrokesTrait
Component
A description of a main component.
ComponentNode
ComponentPropertiesTrait
ComponentProperty
A property of a component.
ComponentPropertyDefinition
A property of a component.
ComponentPropertyVariables
The variables bound to a particular field on this component property.
ComponentResponse
ComponentSet
A description of a component set, which is a node containing a set of variants of a component.
ComponentSetNode
ComponentSetResponse
ComponentSetsMeta
ComponentSetsResponse
ComponentsMeta
ComponentsResponse
ConditionalAction
Checks if a condition is met before performing certain actions by using an if/else conditional statement.
ConditionalBlock
Either the if or else conditional blocks.
ConnectorEndpoint
Stores canvas location for a connector start/end point.
ConnectorNode
ConnectorTextBackground
Constraint
Sizing constraint for exports.
ContainingComponentSet
The component set node that contains the frame node.
CornerRadiusShapeTraits
CornerTrait
CubicBezier
A cubic bezier curve that defines the easing.
DefaultShapeTraits
DevModeStatusUpdatePayload
DevResource
A dev resource in a file.
DevStatus
Represents whether or not a node has a particular handoff (or dev) status applied to it.
DevStatusTrait
DirectionalTransition
Describes an animation used when navigating in a prototype.
Document
Represents a link to documentation for a component or component set.
DropShadowEffect
DuotoneNoiseEffect
Easing
Describes an easing curve.
Effect
EllipseNode
EmbedNode
ExportSetting
An export setting.
Expression
Defines the Expression(https://help.
FigmaClient
A client for interacting with the Figma API.
FileCommentPayload
FileDeletePayload
FileMeta
FileMetaResponse
FileResponse
FileUpdatePayload
FileVersionUpdatePayload
FlowStartingPoint
A flow starting point used when launching a prototype to enter Presentation view.
Frame
FrameInfo
Data on the frame a component resides in.
FrameOffset
Position of a comment relative to the frame to which it is attached.
FrameOffsetRegion
Position of a region comment relative to the frame to which it is attached.
FrameTraits
GetFile
Returns the document identified by file_key as a JSON object.
GetFileNodes
Returns the nodes referenced to by ids as a JSON object.
GetImages
Renders images from a file.
GetPage
Get a paginated list of published components within a team library.
GetWebhooks
Returns a list of webhooks corresponding to the context or plan provided, if they exist.
GradientPaint
GroupNode
HasBlendModeAndOpacityTrait
HasChildrenTrait
HasEffectsTrait
HasExportSettingsTrait
HasFramePropertiesTrait
HasGeometryTrait
HasLayoutTrait
HasMaskTrait
HasTextSublayerTrait
A link to either a URL or another frame (node) in the document.
ImageFillsMeta
ImageFillsResponse
ImageFilters
Image filters to apply to the node.
ImagePaint
ImagesResponse
IndividualStrokesTrait
IndividualStrokeWeightsVariables
InnerShadowEffect
InstanceNode
InstanceSwapPreferredValue
Instance swap preferred value.
Interaction
An interaction in the Figma viewer, containing a trigger and one or more actions.
IsLayerTrait
LayerTraitVariables
A mapping of field to the variables applied to this field.
LayoutConstraint
Layout constraint relative to containing Frame.
LayoutGrid
Guides to align and place objects within a frames.
LayoutGridVariables
The variables bound to a particular field on this layout grid.
LibraryItemData
An object representing the library item information in the payload of the LIBRARY_PUBLISH event.
LibraryPublishPayload
LineNode
LinkUnfurlNode
LocalVariable
A Variable is a single design token that defines values for each of the modes in its VariableCollection.
LocalVariableCollection
A grouping of related Variable objects each with the same modes.
LocalVariablesMeta
LocalVariablesResponse
Measurement
A pinned distance between two nodes in Dev Mode.
MeasurementOffset
MeasurementOffsetInner
Measurement offset relative to the inside of the start node.
MeasurementOffsetOuter
Measurement offset relative to the outside of the start node.
MeasurementStartEnd
The node and side a measurement is pinned to.
MinimalFillsTrait
MinimalStrokesTrait
Mode
MonotoneNoiseEffect
MultitoneNoiseEffect
Node
NodeAction
An action that navigates to a specific node in the Figma viewer.
NodeMeta
NodesResponse
NoiseEffect
NormalBlurEffect
OnKeyDownTrigger
OnMediaEndTrigger
OnMediaHitTrigger
OnMouseInteractionTrigger
OnMouseMovementTrigger
OpenUrlAction
An action that opens a URL.
Overrides
Fields directly overridden on an instance.
Paint
PaintOverride
Paint metadata to override default paints.
Path
Defines a single path.
PatternPaint
PingPayload
PostComment
PostWebhook
ProgressiveBlurEffect
Project
A Project can be identified by both the Project name, and the Project ID.
ProjectFile
ProjectFilesResponse
PrototypeDevice
The device used to view a prototype.
PublishedComponent
An arrangement of published UI elements that can be instantiated across figma files.
PublishedComponentSet
A node containing a set of variants of a component.
PublishedStyle
A set of published properties that can be applied to nodes.
PublishedVariable
A Variable is a single design token that defines values for each of the modes in its VariableCollection.
PublishedVariableCollection
A grouping of related Variable objects each with the same modes.
PublishedVariablesMeta
PublishedVariablesResponse
PutWebhook
Reaction
A reaction left by a user.
Rectangle
A rectangle that expresses a bounding box in absolute coordinates.
RectangleCornerRadiiVariables
RectangleNode
RectangularShapeTraits
Region
Position of a region comment on the canvas.
RegularPolygonNode
ResponseCursor
Pagination cursor.
ResponsePagination
If pagination is needed due to the length of the response, identifies the next and previous pages.
ReturnAction
Rgba
An RGBA color.
Section
SectionNode
SetVariableAction
Sets a variable to a specific value.
SetVariableModeAction
Sets a variable to a specific mode.
ShadowEffect
ShadowEffectVariables
The variables bound to a particular field on this shadow effect.
ShapeWithTextNode
SimpleTransition
Describes an animation used when navigating in a prototype.
Size
A width and a height.
SizeVariables
SliceNode
SolidPaint
SolidPaintVariables
The variables bound to a particular field on this paint.
Spring
A spring function that defines the easing.
StarNode
StickyNode
StrokeWeights
Individual stroke weights.
Style
A set of properties that can be applied to nodes and published.
StyleResponse
StylesMeta
StylesResponse
SubCanvasNode
TableCellNode
TableNode
TeamProjectsResponse
TextNode
TextPathNode
TextPathPropertiesTrait
TextPathTypeStyle
TextPathTypeStyleVariables
The variables bound to a particular field on this style.
TextureEffect
A texture effect.
TransformGroupNode
TransformModifiersTrait
Transition
TransitionSourceTrait
Trigger
The "ON_HOVER" and "ON_PRESS" trigger types revert the navigation when the trigger is finished (the result is temporary). "MOUSE_ENTER", "MOUSE_LEAVE", "MOUSE_UP" and "MOUSE_DOWN" are permanent, one-way navigation. The delay parameter requires the trigger to be held for a certain duration of time before the action occurs. Both timeout and delay values are in milliseconds. The "ON_MEDIA_HIT" and "ON_MEDIA_END" trigger types can only trigger from a video. They fire when a video reaches a certain time or ends. The timestamp value is in seconds.
TypePropertiesTrait
TypeStyle
TypeStyleVariables
The variables bound to a particular field on this style.
UpdateMediaRuntimeAction
An action that affects a video node in the Figma viewer.
UpdateMediaRuntimePlaybackAction
UpdateMediaRuntimeSkipByAction
UpdateMediaRuntimeSkipToAction
User
A description of a user.
VariableAlias
Contains a variable alias.
VariableCodeSyntax
An object containing platform-specific code syntax definitions for a variable.
VariableData
A value to set a variable to during prototyping.
VariableWidthStrokesTrait
Vector
A 2d vector.
VectorNode
Version
A version of a file.
VersionsResponse
WashiTapeNode
Webhook
A response object containing a file's metadata.
WebhookPayload
WebhooksResponse
WidgetNode

Enums

ActionType
BlendMode
This type is a string enum with the following possible values.
BlurType
BooleanOperation
A string enum indicating the type of boolean operation applied.
CommentPinCorner
The corner of the comment region to pin to the node's corner as a string enum.
ComponentPropertyType
Component property type.
ConnectorLineType
Connector line type.
ConnectorStrokeCap
Connector stroke cap.
ConstraintType
Type of constraint to apply:
CounterAxisAlignContent
Determines how the auto-layout frame’s wrapped tracks should be aligned in the counter axis direction.
CounterAxisAlignItems
Determines how the auto-layout frame's children should be aligned in the counter axis direction.
CounterAxisSizingMode
Whether the counter axis has a fixed length (determined by the user) or an automatic length (determined by the layout engine).
DevModeStatus
EasingType
This type is a string enum with the following possible values:
EditorType
EffectType
ExportFormat
ExpressionFunction
Defines the list of operators available to use in an Expression.
GridChildAlign
Determines how a GRID frame's child should be aligned within its grid area.
HorizontalConstraint
Horizontal constraint (relative to containing frame) as an enum:
HyperlinkType
The type of hyperlink.
InputDevice
InstanceSwapPreferredValueType
Type of node for this preferred value.
LayoutAlign
Determines if the layer should stretch along the parent's counter axis.
LayoutGridAlignment
Positioning of grid as a string enum.
LayoutGridPattern
Orientation of the grid as a string enum.
LayoutGrow
This property is applicable only for direct children of auto-layout frames, ignored otherwise.
LayoutMode
Whether this layer uses auto-layout to position its children.
LayoutPositioning
Determines whether a layer's size and position should be determined by auto-layout settings or manually adjustable.
LayoutSizing
The sizing setting on this auto-layout frame or frame child.
LayoutWrap
Whether this auto-layout frame has wrapping enabled.
LineHeightUnit
The unit of the line height value specified by the user.
LineType
LinkAccess
Access policy for users who have the link to the file.
Magnet
The magnet type is a string enum.
MaskType
If this layer is a mask, this property describes the operation used to mask the layer's siblings.
MeasurementOffsetType
MediaAction
The method of navigation.
NodeType
NoiseType
OverflowDirection
Whether a node has primary axis scrolling, horizontal or vertical.
PaintType
PatternAlignment
PrimaryAxisAlignItems
Determines how the auto-layout frame's children should be aligned in the primary axis direction.
PrimaryAxisSizingMode
Whether the primary axis has a fixed length (determined by the user) or an automatic length (determined by the layout engine).
PrototypeDeviceRotation
PrototypeDeviceType
Role
The role of the user making the API request in relation to the file.
ScaleMode
Image scaling mode.
ScrollBehavior
How layer should be treated when the frame is resized.
SemanticItalic
Indicates how the font style was overridden when there is a text style override.
SemanticWeight
Indicates how the font weight was overridden when there is a text style override.
ShapeType
Geometric shape type.
Side
StrokeAlign
Position of stroke relative to vector outline, as a string enum.
StrokeCap
A string enum describing the end caps of vector paths.
StrokeJoin
A string enum with value of "MITER", "BEVEL", or "ROUND", describing how corners in vector paths are rendered.
StyleType
The type of style.
StyleTypeKey
The type of style as string enum for keys.
TextAlignHorizontal
Horizontal text alignment as string enum.
TextAlignVertical
Vertical text alignment as string enum.
TextAutoResize
Dimensions along which text will auto resize, default is that the text does not auto-resize.
TextCase
Text casing applied to the node, default is the original casing.
TextDecoration
Text decoration applied to the node, default is none.
TextTruncation
Whether this text node will truncate with an ellipsis when the text contents is larger than the text node.
TileType
The tile type for the pattern.
TransitionDirection
TransitionType
TriggerType
VariableDataType
Defines the types of data a VariableData object can hold.
VariableResolvedDataType
Defines the types of data a VariableData object can eventually equal.
VariableScope
Scopes allow a variable to be shown or hidden in the variable picker for various fields.
VerticalConstraint
Vertical constraint (relative to containing frame) as an enum:
WebhookContext
The type of context this webhook is attached to.
WebhookEvent
An enum representing the possible events that a webhook can subscribe to.
WebhookStatus
An enum representing the possible statuses you can set a webhook to:
WindingRule
The winding rule for the path (same as in SVGs).

Extensions

$AfterTimeoutTriggerCopyWith on AfterTimeoutTrigger
$ArcDataCopyWith on ArcData
$BlurEffectVariablesCopyWith on BlurEffectVariables
$BooleanOperationNodeCopyWith on BooleanOperationNode
$BranchCopyWith on Branch
$CanvasCopyWith on Canvas
$ColorStopCopyWith on ColorStop
$ColorStopVariablesCopyWith on ColorStopVariables
$CommentCopyWith on Comment
$CommentFragmentCopyWith on CommentFragment
$CommentsResponseCopyWith on CommentsResponse
$ComponentCopyWith on Component
$ComponentNodeCopyWith on ComponentNode
$ComponentPropertyCopyWith on ComponentProperty
$ComponentPropertyDefinitionCopyWith on ComponentPropertyDefinition
$ComponentPropertyVariablesCopyWith on ComponentPropertyVariables
$ComponentResponseCopyWith on ComponentResponse
$ComponentSetCopyWith on ComponentSet
$ComponentSetNodeCopyWith on ComponentSetNode
$ComponentSetResponseCopyWith on ComponentSetResponse
$ComponentSetsMetaCopyWith on ComponentSetsMeta
$ComponentSetsResponseCopyWith on ComponentSetsResponse
$ComponentsMetaCopyWith on ComponentsMeta
$ComponentsResponseCopyWith on ComponentsResponse
$ConditionalActionCopyWith on ConditionalAction
$ConditionalBlockCopyWith on ConditionalBlock
$ConnectorEndpointCopyWith on ConnectorEndpoint
$ConnectorNodeCopyWith on ConnectorNode
$ConnectorTextBackgroundCopyWith on ConnectorTextBackground
$ConstraintCopyWith on Constraint
$ContainingComponentSetCopyWith on ContainingComponentSet
$CubicBezierCopyWith on CubicBezier
$DevModeStatusUpdatePayloadCopyWith on DevModeStatusUpdatePayload
$DevResourceCopyWith on DevResource
$DevStatusCopyWith on DevStatus
$DirectionalTransitionCopyWith on DirectionalTransition
$DocumentationLinkCopyWith on DocumentationLink
$DocumentCopyWith on Document
$DropShadowEffectCopyWith on DropShadowEffect
$DuotoneNoiseEffectCopyWith on DuotoneNoiseEffect
$EasingCopyWith on Easing
$EllipseNodeCopyWith on EllipseNode
$EmbedNodeCopyWith on EmbedNode
$ExportSettingCopyWith on ExportSetting
$ExpressionCopyWith on Expression
$FileCommentPayloadCopyWith on FileCommentPayload
$FileDeletePayloadCopyWith on FileDeletePayload
$FileMetaCopyWith on FileMeta
$FileMetaResponseCopyWith on FileMetaResponse
$FileResponseCopyWith on FileResponse
$FileUpdatePayloadCopyWith on FileUpdatePayload
$FileVersionUpdatePayloadCopyWith on FileVersionUpdatePayload
$FlowStartingPointCopyWith on FlowStartingPoint
$FrameCopyWith on Frame
$FrameInfoCopyWith on FrameInfo
$FrameOffsetCopyWith on FrameOffset
$FrameOffsetRegionCopyWith on FrameOffsetRegion
$GetFileCopyWith on GetFile
$GetFileNodesCopyWith on GetFileNodes
$GetImagesCopyWith on GetImages
$GetPageCopyWith on GetPage
$GetWebhooksCopyWith on GetWebhooks
$GradientPaintCopyWith on GradientPaint
$GroupNodeCopyWith on GroupNode
$HyperlinkCopyWith on Hyperlink
$ImageFillsMetaCopyWith on ImageFillsMeta
$ImageFillsResponseCopyWith on ImageFillsResponse
$ImageFiltersCopyWith on ImageFilters
$ImagePaintCopyWith on ImagePaint
$ImagesResponseCopyWith on ImagesResponse
$IndividualStrokeWeightsVariablesCopyWith on IndividualStrokeWeightsVariables
$InstanceNodeCopyWith on InstanceNode
$InstanceSwapPreferredValueCopyWith on InstanceSwapPreferredValue
$InteractionCopyWith on Interaction
$LayerTraitVariablesCopyWith on LayerTraitVariables
$LayoutConstraintCopyWith on LayoutConstraint
$LayoutGridCopyWith on LayoutGrid
$LayoutGridVariablesCopyWith on LayoutGridVariables
$LibraryItemDataCopyWith on LibraryItemData
$LibraryPublishPayloadCopyWith on LibraryPublishPayload
$LineNodeCopyWith on LineNode
$LinkUnfurlNodeCopyWith on LinkUnfurlNode
$LocalVariableCollectionCopyWith on LocalVariableCollection
$LocalVariableCopyWith on LocalVariable
$LocalVariablesMetaCopyWith on LocalVariablesMeta
$LocalVariablesResponseCopyWith on LocalVariablesResponse
$MeasurementCopyWith on Measurement
$MeasurementOffsetInnerCopyWith on MeasurementOffsetInner
$MeasurementOffsetOuterCopyWith on MeasurementOffsetOuter
$MeasurementStartEndCopyWith on MeasurementStartEnd
$ModeCopyWith on Mode
$MultitoneNoiseEffectCopyWith on MultitoneNoiseEffect
$NodeActionCopyWith on NodeAction
$NodeMetaCopyWith on NodeMeta
$NodesResponseCopyWith on NodesResponse
$OnKeyDownTriggerCopyWith on OnKeyDownTrigger
$OnMediaHitTriggerCopyWith on OnMediaHitTrigger
$OnMouseInteractionTriggerCopyWith on OnMouseInteractionTrigger
$OnMouseMovementTriggerCopyWith on OnMouseMovementTrigger
$OpenUrlActionCopyWith on OpenUrlAction
$OverridesCopyWith on Overrides
$PaintOverrideCopyWith on PaintOverride
$PathCopyWith on Path
$PatternPaintCopyWith on PatternPaint
$PostCommentCopyWith on PostComment
$PostWebhookCopyWith on PostWebhook
$ProgressiveBlurEffectCopyWith on ProgressiveBlurEffect
$ProjectCopyWith on Project
$ProjectFileCopyWith on ProjectFile
$ProjectFilesResponseCopyWith on ProjectFilesResponse
$PrototypeDeviceCopyWith on PrototypeDevice
$PublishedComponentCopyWith on PublishedComponent
$PublishedComponentSetCopyWith on PublishedComponentSet
$PublishedStyleCopyWith on PublishedStyle
$PublishedVariableCollectionCopyWith on PublishedVariableCollection
$PublishedVariableCopyWith on PublishedVariable
$PublishedVariablesMetaCopyWith on PublishedVariablesMeta
$PublishedVariablesResponseCopyWith on PublishedVariablesResponse
$PutWebhookCopyWith on PutWebhook
$ReactionCopyWith on Reaction
$RectangleCopyWith on Rectangle
$RectangleCornerRadiiVariablesCopyWith on RectangleCornerRadiiVariables
$RectangleNodeCopyWith on RectangleNode
$RegionCopyWith on Region
$RegularPolygonNodeCopyWith on RegularPolygonNode
$ResponseCursorCopyWith on ResponseCursor
$ResponsePaginationCopyWith on ResponsePagination
$ReturnActionCopyWith on ReturnAction
$RgbaCopyWith on Rgba
$SectionCopyWith on Section
$SectionNodeCopyWith on SectionNode
$SetVariableActionCopyWith on SetVariableAction
$SetVariableModeActionCopyWith on SetVariableModeAction
$ShadowEffectVariablesCopyWith on ShadowEffectVariables
$ShapeWithTextNodeCopyWith on ShapeWithTextNode
$SimpleTransitionCopyWith on SimpleTransition
$SizeCopyWith on Size
$SizeVariablesCopyWith on SizeVariables
$SliceNodeCopyWith on SliceNode
$SolidPaintCopyWith on SolidPaint
$SolidPaintVariablesCopyWith on SolidPaintVariables
$SpringCopyWith on Spring
$StarNodeCopyWith on StarNode
$StickyNodeCopyWith on StickyNode
$StrokeWeightsCopyWith on StrokeWeights
$StyleCopyWith on Style
$StyleResponseCopyWith on StyleResponse
$StylesMetaCopyWith on StylesMeta
$StylesResponseCopyWith on StylesResponse
$TableCellNodeCopyWith on TableCellNode
$TableNodeCopyWith on TableNode
$TeamProjectsResponseCopyWith on TeamProjectsResponse
$TextNodeCopyWith on TextNode
$TextPathNodeCopyWith on TextPathNode
$TextPathTypeStyleCopyWith on TextPathTypeStyle
$TextPathTypeStyleVariablesCopyWith on TextPathTypeStyleVariables
$TextureEffectCopyWith on TextureEffect
$TransformGroupNodeCopyWith on TransformGroupNode
$TypeStyleCopyWith on TypeStyle
$TypeStyleVariablesCopyWith on TypeStyleVariables
$UpdateMediaRuntimePlaybackActionCopyWith on UpdateMediaRuntimePlaybackAction
$UpdateMediaRuntimeSkipByActionCopyWith on UpdateMediaRuntimeSkipByAction
$UpdateMediaRuntimeSkipToActionCopyWith on UpdateMediaRuntimeSkipToAction
$UserCopyWith on User
$VariableAliasCopyWith on VariableAlias
$VariableCodeSyntaxCopyWith on VariableCodeSyntax
$VariableDataCopyWith on VariableData
$VectorCopyWith on Vector
$VectorNodeCopyWith on VectorNode
$VersionCopyWith on Version
$VersionsResponseCopyWith on VersionsResponse
$WashiTapeNodeCopyWith on WashiTapeNode
$WebhookCopyWith on Webhook
$WebhooksResponseCopyWith on WebhooksResponse
$WidgetNodeCopyWith on WidgetNode

Typedefs

ClientMeta = Object
Positioning information of the comment.
Emoji = String
The emoji type of reaction as shortcode (e.
Transform = List<List<num>>
A transformation matrix is standard way in computer graphics to represent translation and rotation.
VariableValue = Object
The value for the variable.

Exceptions / Errors

FigmaException
An error from the Figma API docs.