- https://www.figma.com/developers/api
- REST APIなのかFigma APIなのか
- Figma APIぽい
-
Figma's mission is to make design accessible to everyone.
- Figma APIは読み取りとインタラクション?をサポートしている
- オブジェクトやレイヤーのプロパティーを抽出して、Figmaの外部で扱うことができる
- 認証
- アクセストークン or OAuth2
- パーソナルアクセストークンを生成するのがAccount Settingsからできる
X-Figma-Token
をリクエストヘッダーに入れて使う
- 推奨されているのはOAuth2
- アプリケーションを登録する必要がある
- パーソナルアクセストークンを生成するのがAccount Settingsからできる
- アクセストークン or OAuth2
- HTTPのエンドポイントを介してアクセス
- files, images, file versions, users, comments, team projects, project files
- アクセス許可されると、ファイルをJSONで表現されたデータで見れる
- GET or POSTでファイルやレイヤーへのコメントの取得、追加などもできる
- scopes
files:read
file_variables:read
/file_variables:write
file_comments:write
file_dev_resources:read
/file_dev_resources:write
webhooks:write
files
- ノードツリー
DOCUMENT
がルートCANVAS
がはえる。これはPAGEを示している?- CANVASには任意の子ノードがはえる
- ノードにはグローバルなものとノード固有のものがある?
- ノードの種別
DOCUMENT
CANVAS
FRAME
GROUP
SECTION
VECTOR
BOOLEAN_OPERATION
STAR
LINE
ELLIPSE
REGULAR_POLYGON
RECTANGLE
TABLE
TABLE_CELL
TEXT
SLICE
COMPONENT
COMPONENT_SET
INSTANCE
STICKY
SHAPE_WITH_TEXT
CONNECTOR
WASHI_TAPE
- プロパティ
Color
ExportSetting
Constraint
Rectangle
ArcData
BlendMode
MaskType
EasingType
FlowStartingPoint
LayoutConstraint
LayoutGrid
Effect
Hyperlink
DocumentationLink
Paint
Vector
Size
Transform
ImageFilters
FrameOffset
ColorStop
PaintOverride
TypeStyle
Component
ComponentSet
Style
ShapeType
ConnectorEndpoint
ConnectorLineType
ConnectorTextBackground
ComponentPropertyDefinition
ComponentProperty
ComponentPropertyType
InstanceSwapPreferredValue
PrototypeDevice
StrokeWeights
Overrides
VariableAlias
- ノードツリー
- comments
- users
- version history
- projects
- component and styles
- file styles
GET/v1/files/:file_key/styles
- https://forum.figma.com/t/get-file-styles-why-there-are-no-values-properties/19900
- stylesの情報が欲しくても、これでは得られる感じがしない?
- file styles
- REST APIなのかFigma APIなのか
Last active
November 9, 2023 15:39
-
-
Save makotot/6aa84631a746b1b0764792d033031bf4 to your computer and use it in GitHub Desktop.
figma rest api
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment