Skip to main content

create_token

Creates a new design token within a specific mode of a tokenset.

Tool Schema

Parameters

Supported Token Types

Response

Example Usage in Claude

Create a Color Token

Create an Alias Token

Create Different Token Types

Token Naming Conventions

Use consistent naming patterns:
  • color.primary, color.secondary
  • spacing.sm, spacing.md, spacing.lg
  • font.size.sm, font.size.lg
  • border.radius.sm, border.radius.lg

Aliases vs Direct Values

  • Direct tokens: Have their own value (e.g., color.primary: "#007AFF")
  • Alias tokens: Reference other tokens by name (e.g., color.brandcolor.primary)

Common Use Cases

1. Brand Colors

2. Spacing System

3. Typography Scale

4. Component Tokens

Notes

  • Token names must be unique within a mode
  • Aliased tokens automatically resolve to their referenced token’s value
  • You can create tokens in any mode, allowing different values per theme
  • Use descriptive names that follow your design system conventions

See Also