Back to MCP directory
publicPublicdnsLocal runtime

motherduckdb_mcp-server-motherduck

一个为MotherDuck和本地DuckDB提供服务的MCP服务器,支持连接初始化、模式读取和查询执行功能。

article

README

🚀 MCP 服务器 - 母鸭 DuckDB MCP 服务器

MCP 服务器为母鸭(MotherDuck)和本地 DuckDB 提供支持,借助 MCP 服务器,能更高效地进行相关操作。

🚀 快速开始

将以下代码片段添加到您的 Claude Desktop 配置中,并确保设置 HOME 环境变量为您家目录(DuckDB 所需)。在使用 MotherDuck 时,您还需要设置一个 MotherDuck 访问令牌 环境变量。

  • 在 MacOS 上:~/Library/Application\ Support/Claude/claude_desktop_config.json
  • 在 Windows 上:%APPDATA%/Claude/claude_desktop_config.json

✨ 主要特性

资源

提示语

该服务器提供一个提示:

  • duckdb-motherduck-initial-prompt:一个用于初始化连接到 DuckDB 或 MotherDuck 并开始操作的提示

工具

该服务器提供三个工具: | 工具名称 | 功能 | 输入参数 | | ---- | ---- | ---- | | initialize-connection | 创建与本地 DuckDB 或 MotherDuck 的连接并获取可用数据库 | 接受 "type"(DuckDB 或 MotherDuck)作为输入参数 | | read-schemas | 从特定的 DuckDB/MotherDuck 数据库中获取表结构信息 | 接受 "database_name" 作为必需的字符串参数 | | execute-query | 在 MotherDuck(DuckDB)数据库上执行查询 | 接受 "query" 作为必需的字符串参数 |

📚 详细文档

服务器配置

"mcpServers": {
  "mcp-server-motherduck": {
    "command": "uvx",
    "args": [
      "mcp-server-motherduck"
    ],
    "env": {
      "motherduck_token": "",
      "HOME": ""
    }
  }
}

📄 许可证

该 MCP 服务器根据 MIT 许可证发布。这意味着您可以自由使用、修改和分发软件,但需遵守 MIT 许可证的条款和条件。更多详细信息,请参阅项目仓库中的 LICENSE 文件。

help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client