get_figma_design_from_url
Read a Figma design from a URL or file key through the Figma REST API, returning a code-oriented spec for a selected node or a file outline to choose frames.
Instructions
Read a Figma design through the Figma REST API (no plugin needed, requires FIGMA_ACCESS_TOKEN). Pass a Figma URL (figma.com/design//...?node-id=1-2) or fileKey + nodeId. With a node it returns the code-oriented spec; without a node it returns the file outline (pages and top-level frames) so you can pick one. Spec format: each node references shared values in styles by id (layout*, fill*, stroke*, effect*, text*). Layout values are CSS-like (flex, gap, padding, sizing fill/hug/fixed). exportAs: svg marks icons/vectors to export as assets instead of rebuilding them; assets lists icons and image fills to download with download_design_assets. designStyles and variables give design-token names to map onto the project's theme.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Figma file/design URL, optionally with ?node-id= | |
| nodeId | No | Node ID such as 1:2 or 1-2 (overrides node-id in url) | |
| fileKey | No | Figma file key (alternative to url) | |
| maxDepth | No | Maximum depth of children to include (default: unlimited) | |
| includeHidden | No | Include hidden layers (default: false) |