Skip to content
DreamUI Connectors
Get started

Reference

Live

MCP adapter

The DreamUI connector. A child process your harness launches that speaks MCP over stdio and connects to DreamUI cloud.

How it runs

Your harness — Claude Code, Codex, Cursor, Windsurf, VS Code, Muse, or any MCP client — launches the adapter on the same machine. Register it with the generated configuration from the ZIP guide; it keeps process paths on the host and connects to https://dreamui.com. See Getting started for where each harness reads its config.

Before calling generation, sign the host in with device login.

Discover tools

Clients discover the adapter’s current tools and input schemas at runtime with MCP tools/list. Tool names, accepted agent values, and optional fields come from that schema (source: scripts/mcp/uicopilot-mcp-server.mjs) — treat it as authoritative over any example here.

Call a tool

Each invocation uses the standard MCP tools/call envelope. Most MCP clients only need the name and arguments:

MCP · tools/callRun a generation with uicopilot_agent_run
{
  "name": "uicopilot_agent_run",
  "arguments": {
    "agent": "code",
    "prompt": "Create a responsive product landing page with a pricing section.",
    "localDir": "/absolute/path/on/the-mcp-host/project",
    "writeFiles": false,
    "timeoutSec": 180
  }
}
May use credits. writeFiles: false previews local output without writing files.

For reference, the raw JSON-RPC transport envelope looks like this:

MCP · tools/call · JSON-RPCRaw tools/call envelope over stdio
{
  "jsonrpc": "2.0",
  "id": 3,
  "method": "tools/call",
  "params": {
    "name": "uicopilot_agent_run",
    "arguments": {
      "agent": "code",
      "prompt": "Create a responsive product landing page.",
      "localDir": "/absolute/path/on/the-mcp-host/project",
      "writeFiles": false,
      "timeoutSec": 180
    }
  }
}
Key arguments
ArgumentMeaning
localDirA path on the machine running the MCP process — not the end user’s computer by implication.
writeFilesfalse previews local output; true lets the tool write generated files when the user authorized that change. Not a universal dry-run for managed sessions or other network actions.
timeoutSecHow long the call waits. A timeout does not mean the job failed.

Managed sessions

Dispatch is not completion. Follow the sequence and confirm state before reporting a result.

  1. List sessions

    uicopilot_sessions_list — choose an actual session.

  2. Run against that session

    uicopilot_agent_run with that exact session. Never invent a session ID.

  3. Inspect the command

    uicopilot_commands — a queued receipt is still pending.

  4. Refresh state

    uicopilot_session_snapshot — only a fresh snapshot proves completion.