Get Started
The CLI is the scriptable face of the same engine the cloud API runs. By default convert hits the cloud Worker so engine source never ships to clients.
bun install
bun run calque --help
# Figma URL → files (needs FIGMA_TOKEN for URL mode)
export FIGMA_TOKEN=figd_xxx
bun run calque convert \
--figma-url 'https://www.figma.com/design/…?node-id=4368-321208' \
--out ./generated --json
# Node JSON / dump
bun run calque convert design.json --out ./generated --json
# Map onto your library
bun run calque convert design.json --repo ./src --out ./generated
# Pre-scan index for CI / plugin
bun run calque scan-index --repo ./src --out calque.index.json --json
# Convert with cached index + explicit map
bun run calque convert design.json \
--index calque.index.json --map calque.map.json --out ./generated
# Determinism self-check (writes nothing)
bun run calque check design.json --json
# MCP stdio server
bun run calque mcp
Each root node becomes <ComponentName>/<ComponentName>.<ext> under --out
(default generated). JSON mode prints the same files[] shape as the HTTP API.
CALQUE_LOCAL=1 bun run calque convert design.json --out ./generated
Uses the in-process engine from the source tree. Not the production distribution model.
Full local pipeline with incremental writes:
bun run convert → scripts/f2c.ts (includes --incremental).
Prefer bun run calque for product/CLI docs.
Flag tables: CLI flags reference.