MCP.so
登录

Prometheus MCP Server

@pab1it0

基本信息

分类

开发工具

许可证

MIT

传输方式

stdio

作者

pab1it0

关于 Prometheus MCP Server

A Model Context Protocol (MCP) server that enables AI agents and LLMs to query and analyze Prometheus metrics through standardized interfaces.

Prometheus MCP Server 配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "prometheus-mcp-server": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "\\"
      ]
    }
  }
}

Prometheus MCP Server 工具

6

System

Query

Query

Discovery

Discovery

Discovery

概览

What is Prometheus MCP Server?

Prometheus MCP Server is a Model Context Protocol server that gives AI assistants the power to query your Prometheus metrics and execute PromQL queries through standardized MCP interfaces. It is intended for users of MCP-compatible clients such as Claude Desktop, VS Code, Cursor, or Windsurf who need to analyze metrics data from a Prometheus server.

How to use Prometheus MCP Server?

Install and run the server via Docker, or deploy to Kubernetes using the provided Helm chart. Configure it by setting the PROMETHEUS_URL environment variable to point to your Prometheus server, plus optional authentication and transport variables. Add the server to your MCP client’s configuration (for example, Claude Desktop or VS Code) using the Docker command shown in the README.

Key features of Prometheus MCP Server

  • Execute instant and range PromQL queries against Prometheus
  • Discover and explore metrics with pagination and filtering
  • Get metadata for metrics and search by name or description
  • View scrape target information
  • Support for basic auth, bearer token, and mutual TLS authentication
  • Configurable transport modes (stdio, HTTP, SSE)

Use cases of Prometheus MCP Server

  • AI-assisted monitoring and alert troubleshooting using PromQL
  • Automated metric exploration and analysis in development workflows
  • Querying historical metrics for root cause analysis
  • Integrating Prometheus data with AI-powered dashboards and assistants

常见问题

1

What do I need to run Prometheus MCP Server?

You need a Prometheus server accessible from your environment and an MCP-compatible client such as Claude Desktop, VS Code, Cursor, or Windsurf.

2

How do I connect the server to my Prometheus instance?

Set the `PROMETHEUS_URL` environment variable to the URL of your Prometheus server. Optional authentication can be configured via `PROMETHEUS_USERNAME` and `PROMETHEUS_PASSWORD`, `PROMETHEUS_TOKEN`, or client certificate variables.

3

What transport protocols does Prometheus MCP Server support?

The server supports stdio (default), HTTP, and SSE transport modes, controlled by the `PROMETHEUS_MCP_SERVER_TRANSPORT` environment variable.

4

Can I customize which tools are available?

Yes, the list of tools is configurable so you can choose which tools to expose to the MCP client, helping to save context window space.

5

Is authentication supported?

Yes, the server supports basic authentication, bearer token authentication, and mutual TLS authentication, all configured via environment variables.

评论

开发工具 分类下的更多 MCP 服务器