Get Design Context
get_design_contextLoad design system context from a Figma file before generating UI code so output uses correct tokens, reuses components, and follows established patterns.
Instructions
Load design system context (tokens, components, patterns, rules) from a Figma file.
Call this before generating UI code to ensure the output uses correct design tokens, reuses existing components, and follows established patterns.
Args:
figma_file_key (string): The Figma file key
task_description (string, optional): Task context for relevance filtering
sections (string[], optional): Specific sections to include (default: all)
refresh (boolean): Force re-fetch from Figma (default: false)
Returns: Markdown document with design system tokens, components, patterns, and rules.
Examples:
"Load full design system" -> get_design_context with just figma_file_key
"Get context for a login form" -> get_design_context with task_description: "login form"
"Refresh tokens only" -> get_design_context with sections: ["tokens"], refresh: true
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"figma_file_key": "<figma_file_key>"
},
"name": "get_design_context"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| refresh | No | Force cache invalidation and re-fetch from Figma API | |
| sections | No | Specific sections to include. Omit to include all sections. | |
| figma_file_key | Yes | The Figma file key | |
| task_description | No | Optional task context for relevance filtering, e.g. 'build a login form' |