
mcp db connector
一个支持 MySQL、PostgreSQL 和 SQLite 的 MCP 协议数据库连接插件。
Repository Info
About This Server
一个支持 MySQL、PostgreSQL 和 SQLite 的 MCP 协议数据库连接插件。
Model Context Protocol (MCP) - This server can be integrated with AI applications to provide additional context and capabilities, enabling enhanced AI interactions and functionality.
Documentation
DB Connector - MCP 数据库连接插件
一个 Model Context Protocol (MCP) 插件,提供数据库连接功能,支持 MySQL、PostgreSQL 和 SQLite。
功能特性
- 支持多种数据库类型
- 通过 MCP 协议提供标准化接口
- TypeScript 开发,提供完整类型定义
安装
npm install
使用说明
连接到数据库
通过 MCP 服务器使用 connect 工具:
{
"connectionName": "my-db",
"type": "mysql",
"host": "localhost",
"port": 3306,
"user": "root",
"password": "password",
"database": "test_db"
}
执行查询
使用 query 工具执行 SQL 查询:
{
"connectionName": "my-db",
"sql": "SELECT * FROM users"
}
支持的数据库
- MySQL
- PostgreSQL
- SQLite
开发
安装依赖
npm install
开发模式
npm run dev
构建生产版本
npm run build
运行生产版本
npm run start:prod
贡献
欢迎提交 Pull Request。请确保:
- 代码符合现有风格
- 包含适当的测试
- 更新相关文档
许可证
MIT
Quick Start
Clone the repository
git clone https://github.com/mfangtao/mcp-db-connectorInstall dependencies
cd mcp-db-connector
npm installFollow the documentation
Check the repository's README.md file for specific installation and usage instructions.
Repository Details
Recommended MCP Servers
Discord MCP
Enable AI assistants to seamlessly interact with Discord servers, channels, and messages.
Knit MCP
Connect AI agents to 200+ SaaS applications and automate workflows.
Apify MCP Server
Deploy and interact with Apify actors for web scraping and data extraction.
BrowserStack MCP
BrowserStack MCP Server for automated testing across multiple browsers.
Zapier MCP
A Zapier server that provides automation capabilities for various apps.