home / mcp / alertmanager mcp server
A Model Context Protocol MCP server that integrates Prometheus Alertmanager with MCP clients and supports Kubernetes connectivity.
Configuration
View docs{
"mcpServers": {
"jeanlopezxyz-mcp-alertmanager": {
"url": "https://mcp.alertmanager.local/mcp",
"headers": {
"ALERTMANAGER_URL": "http://localhost:9093"
}
}
}
}You set up an MCP server that enables Prometheus Alertmanager to integrate with MCP clients and Kubernetes clusters. It runs as a native Go binary and can be easily invoked via npx, with built-in options to connect directly to Alertmanager or auto-connect inside a Kubernetes/OpenShift environment.
You can connect to the Alertmanager MCP server in two primary ways: direct URL access or automatic Kubernetes integration. When you run the server via npx, it behaves as an MCP endpoint that your MCP client can reach. You can configure your client to either point to a direct URL or to let the server discover Alertmanager through the Kubernetes API proxy.
Prerequisites: you need Node.js installed if you plan to use npx. You do not need to install anything for the npx-based run beyond having npm available on your system.
# Quick start using npx to run the MCP server
npx -y mcp-alertmanager@latest
# Build from source and run the binary
make build
./mcp-alertmanagerYou can configure the MCP client to communicate with the Alertmanager MCP server in two main ways: direct URL configuration or automatic Kubernetes connectivity. The direct approach uses an explicit Alertmanager API URL, while the Kubernetes approach discovers Alertmanager through the Kubernetes API service proxy.
{
"mcpServers": {
"alertmanager": {
"command": "npx",
"args": ["-y", "mcp-alertmanager@latest"],
"env": {
"ALERTMANAGER_URL": "http://localhost:9093"
}
}
}
}Direct URL usage overrides automatic discovery. If you set a direct URL via ALERTMANAGER_URL or the --url flag, your MCP client will connect straight to that address. If you do not specify a direct URL, the server will attempt Kubernetes API proxy-based auto-connect using the cluster context and kubeconfig.
{
"mcpServers": {
"alertmanager": {
"command": "npx",
"args": ["-y", "mcp-alertmanager@latest"]
}
}
}Fetch current alerts with optional filters, group alerts by routing labels, and summarize alert states across namespaces.
List, create, and delete silences to mute alerts for a period of time.
Check the Alertmanager status, version, cluster info, and list configured receivers.
Investigate specific alerts, review history, and find correlated alerts.