/wire:dbt-mcp-serverfrom wire
Guides setup and configuration of the dbt MCP server for Claude Code and Claude Desktop. Covers local vs remote server modes, credential handling, and Wire project setup for accessing dbt Semantic Layer, Discovery API, and CLI commands.
Ships in wire. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Before proceeding, append a one-line entry to .wire/execution_log.md:
| YYYY-MM-DD HH:MMZ | skill | dbt-mcp-server | dbt MCP server work triggered this skill | <by> | <session> | n/a | n/a | n/a |
If .wire/execution_log.md does not exist, create it with the standard header first (see specs/utils/execution_log.md). If no .wire/ directory exists in the current repo, skip this step.
The dbt MCP server connects Claude Code (and Claude Desktop) to dbt's CLI, Semantic Layer, Discovery API, and Admin API. Once configured, other dbt skills (dbt-analytics-qa, dbt-semantic-layer, dbt-dag) can use MCP tools like list_metrics, get_lineage, get_mart_models, and dbt_build directly rather than falling back to manifest parsing.
This skill guides users through choosing the right server type, generating the correct configuration, and verifying the connection.
Keywords: "dbt MCP", "dbt-mcp", "dbt MCP server", "dbt semantic layer MCP", "dbt Discovery API", "dbt tools", "uvx dbt-mcp"
Activate when:
.mcp.json or ~/.claude.json are being edited in a Wire projectAsk: "Do you want to use the local or remote dbt MCP server?"
| Local server | Remote server | |
|---|---|---|
| How it runs | On your machine via uvx dbt-mcp | HTTP endpoint at dbt Cloud |
| dbt CLI access | Yes (dbt run, build, test, show) | No |
| Semantic Layer | Yes (if dbt Cloud connected) | Yes |
| Discovery API | Yes (if dbt Cloud connected) | Yes |
| Requires dbt Cloud | No (CLI-only mode works without it) | Yes |
| Credits consumed | No | Yes (dbt Copilot credits) |
| Best for | Wire project development work | Consumption/analytics Q&A only |
Recommendation for Wire projects: Use local server. It gives Claude access to dbt CLI commands during development and connects to dbt Cloud for Semantic Layer / Discovery when needed.
Defaults are sensible for Wire projects:
| Category | Default | Disable with |
|---|---|---|
dbt CLI (run, build, test, compile) | Enabled | DISABLE_DBT_CLI=true |
| Semantic Layer (metrics, dimensions) | Enabled | DISABLE_SEMANTIC_LAYER=true |
| Discovery API (models, lineage) | Enabled | DISABLE_DISCOVERY=true |
| Admin API (jobs, runs) | Enabled | DISABLE_ADMIN_API=true |
SQL (text_to_sql, execute_sql) | Disabled | DISABLE_SQL=false to enable |
| Codegen (generate models/sources) | Disabled | DISABLE_DBT_CODEGEN=false to enable |
Before generating the configuration, gather:
DBT_PROJECT_DIR: Absolute path to the folder containing dbt_project.yml
# From inside your dbt project:
pwd
DBT_PATH: Path to the dbt executable
which dbt # dbt Core in venv
which dbtf # dbt Fusion
dbt Cloud credentials (only needed for Semantic Layer, Discovery, Admin API):
DBT_HOST: your dbt Cloud host (e.g. https://your-account.us1.dbt.com or cloud.getdbt.com)DBT_TOKEN: personal access token (Settings → API Access in dbt Cloud)DBT_ACCOUNT_ID: from your dbt Cloud URL (cloud.getdbt.com/accounts/XXXXX)DBT_PROD_ENV_ID: from Orchestration → Environments in dbt Cloud{
"mcpServers": {
"dbt": {
"command": "uvx",
"args": ["dbt-mcp"],
"env": {
"DBT_PROJECT_DIR": "/path/to/your/dbt/project",
"DBT_PATH": "/path/to/dbt"
}
}
}
}
{
"mcpServers": {
"dbt": {
"command": "uvx",
"args": ["dbt-mcp"],
"env": {
"DBT_HOST": "cloud.getdbt.com",
"DBT_TOKEN": "${DBT_TOKEN}",
"DBT_ACCOUNT_ID": "${DBT_ACCOUNT_ID}",
"DBT_PROD_ENV_ID": "${DBT_PROD_ENV_ID}",
"DBT_PROJECT_DIR": "/path/to/project",
"DBT_PATH": "/path/to/dbt"
}
}
}
}
.env file (recommended for teams){
"mcpServers": {
"dbt": {
"command": "uvx",
"args": ["--env-file", "/path/to/.env", "dbt-mcp"]
}
}
}
.env file:
DBT_HOST=cloud.getdbt.com
DBT_TOKEN=<set-via-env-or-secret-manager>
DBT_ACCOUNT_ID=<your-account-id>
DBT_PROD_ENV_ID=<your-prod-env-id>
DBT_PROJECT_DIR=/path/to/project
DBT_PATH=/path/to/dbt
Add .env to .gitignore — never commit literal tokens.
{
"mcpServers": {
"dbt": {
"url": "https://cloud.getdbt.com/api/ai/v1/mcp/",
"headers": {
"Authorization": "Token ${DBT_TOKEN}",
"x-dbt-prod-environment-id": "${DBT_PROD_ENV_ID}"
}
}
}
}
Option A — Project-specific (recommended for Wire projects, shareable with team):
Add to .mcp.json at the repo root. /wire:new already creates .mcp.json with Atlassian, Fathom, and Context7 servers — merge the dbt entry rather than replacing:
{
"mcpServers": {
"atlassian": { ... },
"fathom": { ... },
"context7": { ... },
"dbt": {
"command": "uvx",
"args": ["dbt-mcp"],
"env": {
"DBT_PROJECT_DIR": "/path/to/project",
"DBT_PATH": "/path/to/dbt"
}
}
}
}
If using token auth, use ${DBT_TOKEN} references (not literal values) so .mcp.json is safe to commit.
Option B — User-global (your machine only):
claude mcp add dbt -s user -- uvx dbt-mcp
Option C — Project-scoped via CLI:
claude mcp add dbt -s project -- uvx dbt-mcp
Config location:
~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.json${DBT_TOKEN}) in config files that may be committed.env files with .gitignore for local development; use Secret Manager or env var injection in CI/CDTest the local server before configuring a client:
export DBT_PROJECT_DIR=/path/to/project
export DBT_PATH=/path/to/dbt
uvx dbt-mcp
# No errors = server starts successfully; Ctrl+C to stop
After setting up in Claude Code, ask Claude:
DBT_PROJECT_DIR to the repo root (where dbt_project.yml lives, typically the repo root for Wire projects).mcp.json already exists — always add the dbt server entry rather than creating a new filedbt_cloud), the remote server gives Claude visibility into job status via the Admin APIAdapted from https://github.com/dbt-labs/dbt-agent-skills (Apache-2.0). Modified by Rittman Analytics Ltd. See NOTICE.md and LICENSE.txt in this folder.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub rittmananalytics/wire-plugin --plugin wire74 skills in this plugin
/add-analytics-instrumentationEnd-to-end analytics instrumentation workflow for a PR, branch, file, directory, or feature. Reads the code, discovers what events should be tracked, and produces a concrete instrumentation plan — all in one shot. Use this skill whenever a user wants to add analytics to a PR, asks "instrument this PR", "add tracking to this branch", "what analytics does this file need", "instrument the checkout flow", "run the full instrumentation workflow", or any request that implies going from code changes to a tracking plan. Also trigger when the user gives you a PR link, branch name, file path, or feature description and mentions analytics, events, or instrumentation. This is the main entry point for the analytics workflow — prefer it over calling the individual steps (diff-intake, discover-event-surfaces, instrument-events) separately.
/agents-schemaPublish and read warehouse metadata through dbt Labs' Agents Schema (the AGENTS schema inside Snowflake, Databricks or BigQuery, written by the agents-schema CLI from a dbt manifest, LookML, Omni, OSI, Sigma and markdown skills). Activates when the user mentions Agents Schema, agents_schema, AGENTS.ROOT, the agents-schema CLI or its GitHub workflows, warehouse-delivered skills, or asks how an AI agent should find governed context for a warehouse. Used by /wire:agents_schema-generate, -validate and -review, and for ad-hoc work against an AGENTS schema.Other plugins' skills for the same job