opencolor-cli
v0.1.0
Published
AI-powered design token generator — generate OKLCH-based color tokens for CSS, JSON, and Tailwind from a natural-language prompt or hex colors.
Maintainers
Readme
opencolor-cli
AI-powered design token generator. Get a complete set of OKLCH-based color tokens for CSS, JSON, and Tailwind from a natural-language description or hex colors.
Install
npm install -g opencolor-cliAuthenticate
Get your API key at https://colors3.vercel.app/cli-settings, then:
opencolor auth opencolor_YOUR_KEYGenerate
From a natural-language description:
opencolor "warm coral brand"From hex colors:
opencolor --primary="#0054DC" --secondary="#FF6B6B"Options
| Flag | Description |
|---|---|
| --primary=HEX | Primary color |
| --secondary=HEX | Secondary color |
| --tertiary=HEX | Tertiary color |
| --neutral=HEX | Neutral color |
| --format=FORMAT | Output formats: css, json, tailwind (default: all three) |
| --output=DIR | Output directory (default: ./tokens) |
| --dark=false | Skip dark-mode tokens |
Output
Three files in ./tokens (or your --output directory):
colors.css— CSS variables withoklch()valuescolors.json— Light + dark OKLCH values per tokencolors.tailwind.js— Tailwind config withvar(--token)references
Other commands
opencolor whoami # Check auth status
opencolor --help # Show helpLicense
MIT
