What is the canvas-document MCP server?
canvas-document, built as ai-canvas, is a monorepo combining a document model, a renderer and code generators behind one MCP server. Set up with corepack pnpm install and pnpm dev, it gives an agent 47 tools over stdio or SSE: query and render a document, mutate it, undo and redo, generate React or Tailwind code, and build a brand book.
canvas-document treats a design as a semantic, type-safe document rather than a flat image or a pile of layers, so an agent can query, change and undo it the same way it works with code.
The project bundles a document model, a renderer and several code generators behind the one MCP server, covering the path from a design document to real React or Tailwind output.
What it changes in your workflow
- An agent queries nodes and gets a layout back as structured data, instead of parsing a rendered screenshot.
- Every mutation can be undone or redone, with checkpoints marking a known-good state to return to.
- The same document generates a style guide, a brand book, a React component or a Tailwind config.
- Mockups and print collateral, such as posters, can be produced from the same underlying document.
What the 47 tools cover
| Group | Tools |
|---|---|
| Document | open, save, get_document, query_nodes, get_layout, get_screenshot |
| Mutation and history | apply_operations, undo, redo, create_checkpoint |
| Codegen and tokens | generate_react, generate_tailwind_config, generate_brand_tokens |
| Collateral | create_mockup, create_poster_template, generate_collateral_kit, export_pptx |
Who it is for
Best for
- Agents that need to query and change a design the same structured way they work with code.
- Workflows that want undo, redo and checkpoints on design changes, not just on code changes.
- Projects that want one document to drive a style guide, a brand book and generated code together.
Not for
- Pulling design tokens straight from an existing live page rather than starting from a document built in this project, is the job designlang MCP does from any URL.
- Generating color, type and shape tokens on demand without the fuller document, render and codegen stack, is the narrower scope Standby Design MCP covers.
- Keeping a visible local design editor beside the canvas for a person to watch, rather than a document an agent queries headlessly, is what Figmaboy MCP sets up instead.
- Animated React component output from a short prompt, rather than a full document model with undo and codegen, is the narrower product AI Canvas MCP offers for an agent.
Use it with UiChemy
This server generates design documents and code for your own project. Once a layout is settled, UiChemy Composer or AI to WordPress can turn it into an editable Elementor or Gutenberg page. Click Get Started on uichemy.com.
Connect Canvas Document MCP: Semantic Design Documents for Agents to your AI client
corepack pnpm install && corepack pnpm devEnable corepack
Run corepack enable once, then corepack pnpm install inside the cloned monorepo.
Start the stack
Run corepack pnpm dev to start the document model, renderer and MCP server together.
Add the server entry
Point your client's MCP config at the server's start command, matching the project's own scripts.
Restart and open a document
Restart your client, then ask it to open or create a document before querying or mutating it.
Client configuration
{
"mcpServers": {
"canvas-document": {
"command": "pnpm",
"args": ["--filter", "mcp-server", "start"]
}
}
}What you can do with it
- Semantic document modelTreats a design as structured, type-safe data rather than a flat image, so an agent can query and reason about it like code.
- Full history supportUndo, redo and named checkpoints apply to design mutations the same way they would to a code change.
- Multi-target code generationThe same document can generate React components, a Tailwind configuration or brand tokens without redoing the design work.
- Collateral generationMockups, poster templates and a full collateral kit can be produced from the same underlying document.
- Two transportsThe MCP server runs over stdio or SSE, giving a choice between a local process and a networked connection.
- Presentation exportexport_pptx turns the document into a PowerPoint deck, useful for sharing a design outside a code-focused tool.
Tools it exposes
open_document
Opens an existing design document for reading or editing.
get_document
Returns the full structured content of the open document.
query_nodes
Queries nodes in the document by type, name or other criteria.
apply_operations
Applies one or more structured edit operations to the document.
undo
Reverts the most recent mutation.
create_checkpoint
Marks the current document state as a checkpoint to return to later.
generate_react
Generates React component code from the document.
generate_tailwind_config
Generates a Tailwind configuration matching the document's tokens.
generate_brand_tokens
Produces brand-level tokens, such as color and type scale, from the document.
create_mockup
Builds a mockup from the document for review.
export_pptx
Exports the document's content as a PowerPoint presentation.
Frequently asked questions
What is the canvas-document MCP server?
It is an MCP server, built as ai-canvas, that treats a design as a semantic, type-safe document. It gives an agent 47 tools to query, mutate, undo and generate code or collateral from that document.
How do I install the canvas-document MCP server?
Clone the monorepo, run corepack enable and corepack pnpm install, then corepack pnpm dev to start the document model, renderer and MCP server together before connecting a client to it.
Can it undo a design change?
Yes. The undo and redo tools revert or reapply the most recent mutation, and create_checkpoint marks a known-good state the document can return to later in the same session, well after many edits.
What code can it generate from a document?
generate_react produces React component code and generate_tailwind_config produces a matching Tailwind setup, both derived straight from the same open document rather than needing a wholly separate design-to-code pass done by hand.
Can it produce a brand book?
Yes. generate_brand_tokens and the collateral tools can build brand-level tokens and a style guide from the document, giving a team a shared reference beyond raw component code sitting in a repository.
Does it support a presentation export?
Yes. export_pptx turns the document's content into a PowerPoint deck, which matters when a design needs to be shared with people who are not working directly inside a codebase every day.
How does it connect to a client?
The MCP server runs over stdio for a local process or SSE for a networked connection, and the project also documents deployment through Docker, a desktop assistant client, Cursor or a static web host.


