What it does
The dbt MCP server connects dbt projects to Claude, exposing project structure, execution, and data access through the Model Context Protocol. It supports dbt Core via local manifest and dbt Cloud/Platform via Discovery, Admin, and Semantic Layer APIs. Within a conversation, an agent can explore lineage, execute dbt commands, run SQL queries, and retrieve metrics.
Who it's for
Analytics engineers and data engineers maintaining dbt projects who want Claude to navigate their transformation logic, generate SQL, or execute dbt runs without leaving the chat. dbt Cloud and dbt Platform users benefit most from Semantic Layer and Admin API access.
Common use cases
- Map a model's upstream sources and downstream dependents using dbt lineage.
- Generate SQL from natural language descriptions using
text_to_sql. - Execute
dbt run,dbt test, ordbt buildon-demand via Claude. - Query the dbt Semantic Layer to fetch metrics and dimension values.
- Check model health: test failures, run status, and source freshness.
Setup pitfalls
- Requires dbt API token in environment (credential found during scan); ensure it has scope for required APIs.
- Filesystem writes: tools like
compile,docs, andclonemodify local and cloud state—sandbox or review Claude's tool access carefully. - dbt CLI tools are destructive:
run,build,clone, and similar change your database and warehouse. Only enable if you fully trust the agent. - Local manifest may drift: keep
manifest.jsonfresh withdbt parsefor accurateget_node_details_devresults.