Skip to content

dft mcp

MCP (Model Context Protocol) server commands for AI assistant integration.

dft mcp [OPTIONS] COMMAND [ARGS]

Subcommands

Command Purpose
dft mcp serve Start the MCP server for AI assistant integration.
dft mcp init Deprecated. Use dft init mcp instead.

dft mcp serve

Starts an MCP server that lets AI assistants like Cursor, Claude Code, Claude Desktop, and ChatGPT interact with your Dataface project. The server runs in stdio mode — the standard transport for MCP-compatible tools.

dft mcp serve [OPTIONS]

Options

Flag Description
--project-dir PATH Dataface or dbt project directory. Default: current directory.

Examples

dft mcp serve
dft mcp serve --project-dir ./my-project

Manual client configuration

In most cases, dft init mcp writes the right config for you. For manual setup of Claude Desktop (~/.config/claude/config.json):

{
  "mcpServers": {
    "dataface": {
      "command": "dft",
      "args": ["mcp", "serve"]
    }
  }
}

For a nested project directory:

{
  "mcpServers": {
    "dataface": {
      "command": "dft",
      "args": ["mcp", "serve", "--project-dir", "/absolute/path/to/project"]
    }
  }
}

What the MCP server exposes

CLI verbs wrapped as MCP tools that agents call directly. The canonical registry is dataface/ai/tools/__init__.py (TOOL_HANDLERS):

Face authoring & validation

  • check_dashboard — fast YAML schema + cross-reference validation
  • render_dashboard — produce SVG / HTML / PNG / PDF
  • explain_dashboard — describe a face's queries, charts, variables
  • explain_error — look up an error code with remediation guidance
  • scaffold_face_from_skill — generate a face from a packaged skill template

Data discovery

  • schema — browse the data hierarchy: source → schema → table → column
  • schema_search — full-text + filter search across the schema corpus
  • search_dashboards — keyword search across face files
  • docs — read packaged YAML docs

Query inspection

  • execute_query — run a query and return the result rows
  • describe_query — return resolved SQL, dialect, and column schema
  • query_face — inspect a query defined inside a face file

Agent skills

  • list_skills — enumerate packaged agent skill recipes
  • get_skill — read a specific skill

See dft skills for the agent-facing skill catalog that ships alongside.