MCP needs the desktop app or CLI. The browser editor on this site can’t be driven by an agent; for images and copy in the browser, use the AI panel.
Two ways to run it
| Mode | What the agent drives | Use it for |
|---|---|---|
Headless (mcp) | An in-process engine with no window. It starts with an empty Letter document, or the sample magazine with --sample | Batch jobs, pipelines, servers |
Connected (mcp --connect 7979) | The running desktop app, through its local control channel | Watching each step happen in the window, and tools that need the window |
Get designcraft-cli
| Install | Where the CLI is |
|---|---|
| Windows (MSI) | C:\Program Files\DesignCraft\designcraft-cli.exe by default, not on PATH |
| Linux (deb, rpm) | /usr/bin/designcraft-cli |
| macOS | The separate designcraft-cli-0.6.0-macos-universal.zip release asset (the .app holds only the desktop app) |
| From source | cargo build --release -p designcraft-cli |
Set up with Claude Code
# Headless: an in-process engine, no window
claude mcp add designcraft -- designcraft-cli mcp
# Drive the running desktop app (start it first with a control port)
designcraft --control 7979
claude mcp add designcraft-app -- designcraft-cli mcp --connect 7979Other MCP clients use the same command line in their JSON config:
{
"mcpServers": {
"designcraft": { "command": "/path/to/designcraft-cli", "args": ["mcp"] }
}
}What the agent gets
- Documents:
new_document(preset, size, pages, facing pages, columns, margins, bleed),open_documentandsave_documentfor .designcraft files,inspect_documentfor pages, items, stories, styles, swatches and selection. - Content:
set_story_text,get_story,place_imageinto a frame or at a position, andtype_textat the insertion point. - Seeing the result:
render_pagereturns a page as a PNG the model can look at;export_pngwrites one to disk. - Everything else:
list_commandsto discover commands and their parameters,executefor one,batchfor several in order, plusselect_tool,pointerandkeyto work the tools the way a user would. - Connected mode only:
screenshotof the whole window,clickanddrag, menu and UI inspection, and filling in dialogs.
Coordinates are in points (1/72 inch) in spread space, with the page’s top-left corner at (0, 0) on a single-page spread. Text positions are UTF-8 byte offsets, so an accented letter counts as two.
Prompts to try
- “Create an A4 document with 36 pt margins, add a headline frame that says ‘Summer Fair’ at 28 pt, place
photo.jpgunder it, and show me the page.” - “Open the sample magazine, list the paragraph styles, and render page 3.”
- “Replace the text of the story in the first frame with this copy, then tell me if anything is overset.”
Without MCP: the CLI on its own
# Render every page of the sample magazine to PNG
designcraft-cli run --sample --all-pages out/
# List commands about footnotes, or describe one
designcraft-cli commands footnote
designcraft-cli describe xref.insert
# Run a script of commands and export the result
designcraft-cli script page.dcs --save page.designcraft --export page.pdfFAQ
Can an AI agent control the browser version on this site?
No. The MCP server is part of designcraft-cli and drives either its own headless engine or the desktop app through a local control channel. The web build has no control channel, because a browser page can’t listen on a network port. In the browser, use the AI panel for images and copy instead.
Which agents work with it?
Any MCP client that can start a local stdio server: Claude Code, Claude Desktop, Cursor, VS Code agents and others. The project documents the Claude Code command; other clients take the same command and arguments in their JSON config.
Is the control port safe to leave open?
Turn it on only while you use it. It listens on 127.0.0.1 only and rejects anything that isn’t a JSON request line, so a web page can’t send it commands, but it has no authentication for programs on your own machine.
Source: DesignCraft’s MCP server, agents and control protocol docs. Flags can change between releases.