CLI & MCP Reference
Every CLI subcommand returns deterministic JSON with stable exit codes. Run
dui mcp to expose the exact same operations to AI coding agents over stdio.
Commands
| CLI Command | MCP Tool | Behavior |
|---|---|---|
dui map [PROJECT] |
map(project) |
Auto-discover routes & modals (Vite, Next.js, static HTML), merge optional
dui.json, and capture every width.
|
dui run [PROJECT] [MANIFEST] |
run(project, manifest) |
Execute an explicit dui.json manifest directly. |
dui scan [PROJECT] |
scan(project) |
Print official compiler facts, framework controls, and auto-mocks without launching a browser. |
dui open [RUN_DIR] |
— | Open the embedded 2D web canvas viewer in the browser. |
dui desktop |
— |
Open the native GPUI desktop viewer directly over ~/.dui/dui.db.
|
dui diff --base BRANCH [--markdown] |
diff(before, after) |
Compare runs with element-level renderDiff and lazy PNG pixel diff.
|
dui audit RUN_DIR [--goal N] |
audit(run, goal?) |
Report verification coverage, gap reasons, and unresolved review comments. |
dui comment <add|list|resolve|reopen> |
comment_* |
Manage review comments anchored to screens, states, widths, or transitions. |
dui auth login URL --out FILE |
— |
Launch Chromium for interactive login and save 0600
storageState.json.
|
dui toolchains |
— |
Probe installed official compilers (tsc, rustc,
go, swiftc, kotlinc, dart).
|
MCP Server Configuration
{
"mcpServers": {
"dui": {
"command": "/Users/you/.local/bin/dui",
"args": ["mcp"]
}
}
}