
Kibana Mcp
io.github.mshegolev由 GitHub 帳號 mshegolev 發布v0.1.1更新於 Oct 25, 2026
Kibana/Elasticsearch MCP — log search, aggregations, index discovery, dashboards.
概覽
針對 Kibana 與 Elasticsearch 的唯讀 MCP 伺服器,讓助理搜尋日誌、執行聚合、列出索引並瀏覽儀表板。
- 可以做什麼
- 列出索引及其健康狀態、文件數與大小,可依模式篩選。在指定索引中依全文查詢、時間範圍、排序與結果數量搜尋日誌。依欄位對日誌聚合,支援計數、平均值、加總、最小值與最大值指標。列出已儲存的儀表板,支援搜尋與分頁,並取得單一儀表板及其面板明細。結果同時以結構化 JSON 與 markdown 文字回傳。
- 適用情境
- 適合助理在排查問題或回顧事故時檢索日誌、依等級或服務統計錯誤、確認有哪些索引,或查找 Kibana 儀表板,不必開啟 Kibana 介面。
- 執行需求
- 以本機 Python 套件執行(pip install kibana-mcp 或 uvx kibana-mcp),也可使用 Docker 映像。必須設定 KIBANA_URL;可選 ELASTICSEARCH_URL 直連 Elasticsearch,否則請求會經 Kibana Console 代理轉送。驗證使用 KIBANA_API_KEY,或 KIBANA_USERNAME 搭配 KIBANA_PASSWORD,也可匿名存取。自簽憑證可將 KIBANA_SSL_VERIFY 設為 false。需要能連線至 Kibana 或 Elasticsearch 主機的網路。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Kibana Mcp,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
kibana-mcp
[PyPI version] [Python 3.10+] [License: MIT] [Tests]
MCP server for Kibana / Elasticsearch — log search, aggregations, index discovery, and dashboard browsing via Claude and any MCP-compatible agent.
Why another Kibana MCP?
Existing integrations require a running Kibana instance with browser-level credentials and often wrap the Kibana UI rather than the stable REST APIs. This server:
- Hits Elasticsearch REST API directly for log queries (faster, stable across Kibana UI changes)
- Falls back to the Kibana Console proxy when no direct ES URL is configured (zero extra firewall rules)
- Supports ApiKey auth (best for agents) as well as Basic auth and anonymous access
- Returns both structured JSON (
outputSchema) and markdown text so it works with any MCP client - Is read-only — all tools carry
readOnlyHint: true, no data is modified
Tools
Installation
Or run directly with uvx:
Configuration
Environment Variables
Auth priority: ApiKey > Basic > anonymous.
Copy .env.example to .env and fill in your values.
MCP Client Configuration (Claude Desktop / claude.app)
Or with direct ES access for better performance:
Docker
Usage Examples
Log Search
→ kibana_search_logs(index="logs-*", query="level:ERROR AND service:api", size=50, time_from="2026-04-18T09:00:00Z")
→ kibana_search_logs(index="nginx-*", query="status:500", sort_order="asc", size=100)
Aggregations
→ kibana_aggregate_logs(index="logs-*", group_by="level", time_from="2026-04-18T09:00:00Z")
→ kibana_aggregate_logs(index="logs-*", group_by="service.keyword", metric="avg", metric_field="response_time_ms")
Index Discovery
→ kibana_list_indices()
→ kibana_list_indices(pattern="filebeat-*")
Dashboards
→ kibana_list_dashboards(search="infrastructure")
→ kibana_get_dashboard(dashboard_id="<id from list_dashboards>")
Performance Characteristics
- Log search (
kibana_search_logs): typically 50-500ms with direct ES URL; add 100-200ms when routing through Kibana Console proxy - Aggregations (
kibana_aggregate_logs):size:0queries — no hits transferred, usually 10-100ms - Index listing: single
_cat/indicescall, O(index_count) response, typically <100ms - Dashboard APIs: Kibana Saved Objects API, typically 50-200ms; latency is Kibana-side, not network
- Set
ELASTICSEARCH_URLdirectly if your agent does frequent log searches — eliminates the proxy overhead
Development
License
MIT — see LICENSE.
來源:README.md,提交 b1c596c
工具
0版本歷史
1- v0.1.1最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分