CLI Reference
Every command and flag in the studio CLI.
Run commands with npx @stdout-design/cli <command> (local install) or studio <command> (global install).
Commands
| Command | Description |
|---|---|
studio init [dir] | Scaffold a new studio project |
studio update [dir] | Update an existing project to the latest CLI |
studio dev [dir] | Start the live preview studio |
studio render <template> | Render a single template or batch |
studio cache stats | Show cache statistics |
studio cache clean | Clear the render cache |
studio lint | Check templates for compatibility (not yet implemented) |
studio skill install | Install the agent skill for AI coding tools |
studio init
Scaffold a new studio project.
studio init [projectDir] [options]| Option | Description |
|---|---|
-y, --yes | Skip prompts, use defaults |
--install-skill | Install the agent skill after setup |
Skips scaffolding if a studio.config.ts already exists. See Getting Started.
studio update
Update an existing studio project to the latest CLI version adds the CLI dependency if missing and merges default config values into studio.config.ts.
studio update [projectDir] [options]| Option | Description |
|---|---|
-y, --yes | Skip confirmation prompts |
studio render
Render a template single, or batch with --data.
studio render <template> [props...] [options]<template> is the template ID from studio.config.ts. Props are passed as key=value pairs:
studio render bento-feature title="Hello" stat="10k users"| Option | Description |
|---|---|
--data <path> | CSV or JSON data file for batch rendering |
--preset <ids> | Comma-separated preset IDs. Defaults to all presets |
--locale <locales> | Comma-separated locale codes. Defaults to config |
--out-dir <path> | Output directory (default: config.outDir or out) |
--concurrency <n> | Max concurrent renders in batch mode (default 4) |
--fail-fast | Stop the batch on the first error |
--json | Output the manifest as JSON |
Examples:
# Single render, all configured presets × locales
studio render stat-card title="50K users"
# Single file, one preset, one locale
studio render stat-card --preset instagram-square --locale en --out-dir out
# Batch from CSV, across two presets and two locales
studio render stat-card --data data/stats.csv --preset instagram-square,x-card --locale en,ar --out-dir outOutput
Each render produces one PNG per (preset × locale × data row), named:
<templateId>.<locale>.<presetId>.<rowKey>.pngFor a single render (no --data) the row key is 0, e.g.:
out/stat-card.en.instagram-square.0.png
out/stat-card.en.x-card.0.png
out/stat-card.ar.instagram-square.0.pngA manifest.json is written to the output directory alongside the images, summarizing status, counts, and per-file results (see Batch Rendering).
Exit code is 1 if any render failed. Use --json to get the manifest as machine-readable output.
Flag notes
--presetand--localeare singular and accept comma-separated values. Omit them to render every configured preset and locale.--concurrencyis accepted but rendering is currently sequential; it has no effect on output.- Unknown template IDs trigger a "Did you mean …?" suggestion based on closest match.
studio dev
Start the live preview studio (see Live Studio).
studio dev [rootDir] [options]| Option | Description |
|---|---|
-p, --port <n> | Port to run on (default 3030) |
--open is accepted but currently a no-op open http://localhost:3030 manually.
studio cache stats
Show cache statistics location, compiled/pixel entry counts, disk usage, and the size limit.
studio cache stats [rootDir] [options]| Option | Description |
|---|---|
--json | Output as JSON |
studio cache clean
Clear the render cache entirely.
studio cache clean [rootDir] [options]| Option | Description |
|---|---|
--json | Output as JSON |
See Caching for how the cache works.
studio lint
Check templates for compatibility. Not implemented yet it always exits with code 1 and a message pointing to a future release.
studio skill install
Install the stdout-design agent skill for AI coding agents.
studio skill install [options]| Option | Description |
|---|---|
-y, --yes | Skip confirmation prompts |
See AI Agents.
Exit codes
0success (including a cancelledinit).1any error, or any failed render in a batch.