get_tokens
Extract design tokens (colors, spacing, typography) from a Paper file, filter by type or name pattern, and export as JSON, CSS, or Tailwind theme.
Instructions
List the file's design tokens (colors, spacing, typography, etc).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| types | No | Filter by design token type(s). Omit to include all types. | |
| fileId | No | Optional. The Paper file ID this call should act on. Pass it to reliably target a specific file when several are open at once (e.g. multiple agents from the same session working in parallel). Omit to use the most recently opened file in the session. | |
| format | No | Output format. "json" (default) returns structured tokens. "css" returns a vanilla `:root { ... }` stylesheet. "tailwind" returns a Tailwind v4 `@theme { ... }` block with namespaced variables. | |
| namePattern | No | Glob pattern matched against the full CSS variable name (case-insensitive). Use "*" as a wildcard. Examples: "--color-primary", "--color-*", "*-500", "*brand*". Omit to skip name filtering. |