Centreon MCP Server测试版
通过您的 AI 助手监控 Centreon:MCP 服务器将实时监控以工具形式提供给任何 Model Context Protocol 客户端(Claude、IDE、智能体)。仅读取实时状态和确认告警,不会修改您的配置。
您的助手能做什么
实时状态
查询主机和服务的实时状态,并按状态统计。
告警确认
直接从助手确认主机或服务问题并附加备注。
强大的搜索过滤器
与 Centreon API 相同的逻辑过滤器($and、$or、正则),精确定位目标资源。
兼容主流 AI 平台
Claude (Desktop, Code)ChatGPT / OpenAIGoogle GeminiMicrosoft CopilotMistral Le ChatCursorVS Code
MCP 是开放标准:任何兼容 Model Context Protocol 的客户端都可以连接此服务器。
前提条件
- Python 3.13+ (or Docker)
- A Centreon instance reachable from the MCP server
- A personal API token (Configuration > Users > API tokens)
部署服务器
git clone https://github.com/CentreonLabs/centreon-mcp.git
cd centreon-mcp
# .env: CENTREON_BASE_URL, CENTREON_API_TOKEN, MCP_API_KEY, NGROK_AUTHTOKEN
docker compose up --build
# -> MCP server on :8000, ngrok tunnel, web UI on :4040git clone https://github.com/CentreonLabs/centreon-mcp.git
cd centreon-mcp
python -m venv .venv && source .venv/bin/activate
pip install -e .
# .env: CENTREON_BASE_URL, CENTREON_API_TOKEN, MCP_API_KEY
fastmcp run centreon_mcp/main.pygit clone https://github.com/CentreonLabs/centreon-mcp.git
cd centreon-mcp
uv sync --all-groups
# .env: CENTREON_BASE_URL, CENTREON_API_TOKEN, MCP_API_KEY
uv run fastmcp run centreon_mcp/main.py环境变量(.env)
| CENTREON_BASE_URL* | Centreon server URL (without /api/latest) |
| CENTREON_API_TOKEN* | Personal API token (Configuration > Users > API tokens) |
| MCP_API_KEY* | Bearer token clients must send to the MCP server |
| CENTREON_VERIFY_SSL | SSL certificate verification (default: true) |
| CENTREON_CA_BUNDLE | Path to a custom CA bundle (internal PKI) |
| NGROK_AUTHTOKEN | ngrok token (compose.yaml deployment only) |
* 必填变量
连接您的 MCP 客户端
将您的 MCP 客户端(Claude Desktop、IDE、智能体等)指向服务器 URL,并附带 Authorization 请求头:
{
"mcpServers": {
"centreon": {
"url": "https://your-mcp-host:8000/mcp",
"headers": { "Authorization": "Bearer your-mcp-api-key" }
}
}
}可用工具
- get_realtime_status (live status of a host or service)
- list_all_status (states overview with counters, regex filters)
- acknowledge_resource (acknowledge a problem with a comment)
测试版:工具和接口可能随时调整。欢迎在 GitHub 仓库提交反馈。