IoTDB MCP 服务器
概述
模型上下文协议 (MCP) 服务器实现,通过 IoTDB 提供数据库交互和商业智能功能。此服务器支持运行 SQL 查询。
Related MCP server: Microsoft SQL Server MCP Server
成分
资源
服务器不公开任何资源。
提示
服务器没有提供任何提示。
工具
IoTDB 服务器提供了针对树形模型和表模型的不同工具。您可以通过将“IOTDB_SQL_DIALECT”配置设置为“tree”或“table”来选择。
树模型
metadata_query执行 SHOW/COUNT 查询以从数据库读取元数据
输入:
query_sql(字符串):要执行的 SHOW/COUNT SQL 查询
返回:查询结果作为对象数组
select_query执行 SELECT 查询以从数据库读取数据
输入:
query_sql(字符串): 要执行的 SELECT SQL 查询
返回:查询结果作为对象数组
表格模型
查询工具
read_query执行 SELECT 查询以从数据库读取数据
输入:
query(字符串):要执行的 SELECT SQL 查询
返回:查询结果作为对象数组
架构工具
list_tables获取数据库中所有表的列表
无需输入
返回:表名称数组
describe-table查看特定表的架构信息
输入:
table_name(字符串):要描述的表的名称
返回:具有名称和类型的列定义数组
Claude 桌面集成
先决条件
Python 与
uv包管理器IoTDB 安装
MCP 服务器依赖项
发展
# Clone the repository
git clone https://github.com/apache/iotdb-mcp-server.git
cd iotdb_mcp_server
# Create virtual environment
uv venv
source venv/bin/activate # or `venv\Scripts\activate` on Windows
# Install development dependencies
uv sync在Claude Desktop的配置文件中配置MCP服务器:
MacOS
位置: ~/Library/Application Support/Claude/claude_desktop_config.json
视窗
位置: %APPDATA%/Claude/claude_desktop_config.json
您可能需要在命令字段中输入 uv 可执行文件的完整路径。您可以在 MacOS/Linux 上运行which uv或在 Windows 上运行where uv来获取此路径。
{
"mcpServers": {
"iotdb": {
"command": "uv",
"args": [
"--directory",
"YOUR_REPO_PATH/src/iotdb_mcp_server",
"run",
"server.py"
],
"env": {
"IOTDB_HOST": "127.0.0.1",
"IOTDB_PORT": "6667",
"IOTDB_USER": "root",
"IOTDB_PASSWORD": "root",
"IOTDB_DATABASE": "test",
"IOTDB_SQL_DIALECT": "table"
}
}
}
}Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/apache/iotdb-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
