import_design_tokens
Import design tokens from Figma Tokens JSON, Style Dictionary, or CSS custom properties into the active token store to style components generated by generate_component.
Instructions
Import design tokens from Figma Tokens JSON, Style Dictionary, or CSS custom properties into the active token store. Imported tokens are used by generate_component for styling.
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": {
"tokens_json": "<tokens_json>",
"format": "<format>"
},
"name": "import_design_tokens"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| format | Yes | Format of the provided token data | |
| namespace | No | Optional prefix for all imported tokens (e.g., 'brand' produces --brand-color-primary) | |
| tokens_json | Yes | Raw JSON string of design tokens. Supports Figma Tokens, Style Dictionary, or flat CSS custom properties format. | |
| merge_strategy | No | How to handle conflicts with existing tokens. 'replace' clears all. 'merge-overwrite' overwrites conflicts. 'merge-keep' keeps existing. | replace |