# Connect MotherDuck to Your AI Agent (Universal MCP)

> Use your AI to query data, analyze data, and build dashboards in MotherDuck — and much more.

## Quick Connect (CLI / MCP)
- Claude Code: `claude mcp add --transport http motherduck https://api.universalmcp.app/mcp/motherduck`
- Remote MCP URL (ChatGPT, Claude, Cursor, VS Code): `https://api.universalmcp.app/mcp/motherduck` (unified: `https://api.universalmcp.app/mcp`)
- Actions & Discovery: `POST https://universalmcp.app/mcp/directory` (`get_software_actions({ slug: "motherduck", query })` & `search_software`); configs: https://universalmcp.app/install.md

## Key Facts
- Software: MotherDuck | Category: Marketing & Analytics (MotherDuck) | Auth: Encrypted workspace API key
- Pricing: 100% Free (unlimited users, unlimited software, zero task metering)
- Permissions & Security: Per-person, per-area Off/Read/Write across Query history, Table and schema metadata, Drafted tuning notes; 1-click View Only lock; stateless pass-through; zero stored business records
- Connect: https://app.universalmcp.app/connect?system=motherduck | Guide: https://universalmcp.app/mcp/motherduck
- Built by: Alex Myers (Legal entity: Lancaster Agentic LLC; support@lancasteragentic.com)

## Supported Actions (59 actions: 22 Read, 37 Write)
Perform over 50 actions across databases & storage, users & access, instances & compute, tokens & security, queries & SQL, data pipelines, and dives & data apps. Save hours of work each week by utilizing AI rather than using a traditional app interface.
- **Databases & Storage (9):** Check Storage Usage (read), List Databases (read), List Table Columns (read), Create Database (write), Create DuckLake Catalog (write), Create Iceberg Catalog Link (write), Create Table (write), Delete Database (write), Update Snapshot Retention (write)
- **Users & Access (7):** List Organization Users (read), Assign User Role (write), Create Custom Role (write), Create SSO Connection (write), Create Service Account (write), Delete User Account (write), Update SCIM Provisioning (write)
- **Instances & Compute (6):** Compare Pricing Plans (read), Get Instance Configuration (read), List Active Accounts (read), Assign Instance Type (write), Create Read Replica (write), Update Instance Configuration (write)
- **Tokens & Security (6):** Check Compliance Documentation (read), List User Access Tokens (read), Create IP Allowlist Entry (write), Create Short-Lived Token (write), Create User Access Token (write), Delete User Access Token (write)
- **Queries & SQL (6):** Check Failing Query Errors (read), Check Query Performance (read), Export Query Results (read), Query Tables With SQL (read), Create Saved Query (write), Upload Data Files (write)
- **Data Pipelines (6):** List Flight Runs (read), Create Flight Pipeline (write), Create Postgres Sync (write), Create dbt Connection (write), Schedule Flight Run (write), Update Flight Size (write)
- **Dives & Data Apps (6):** List Dives (read), Create Dive (write), Create Dive Embed Session (write), Delete Dive (write), Send Dive Link (write), Update Dive (write)
- **Guides & AI Agents (6):** Check SQL Suggestions (read), List Guides (read), Query Data In Natural Language (read), Create Guide (write), Create MCP Connection (write), Update Guide (write)
- **Monitoring & Support (4):** Audit Query History (read), Check Billing Statement (read), Pull Compute Usage Report (read), Submit Support Ticket (write)
- **Sharing & Collaboration (3):** List Database Shares (read), Create Database Share (write), Delete Database Share (write)

## Example Prompts for MotherDuck
- **Slowest queries:** "Which MotherDuck queries took longest this week, and which compute instance ran them?"
- **Scan volume:** "Summarize bytes scanned per dashboard in MotherDuck for the past 30 days, sorted from highest to lowest."
- **Table usage:** "List MotherDuck tables that no query has touched in 90 days so we can review them for cleanup."
- **Draft tuning note:** "Draft a tuning note for the Harbor Retail team in MotherDuck and hold it for my approval before sharing."
