mcp
Local MCP (Model Context Protocol) server for integrating LLMs with Mackerel.
claude mcp add --transport stdio mackerelio-labs-mcp-server npx -y @mackerel/mcp-server \
--env MACKEREL_APIKEY="${MACKEREL_APIKEY}"How to use
This MCP server provides a Model Context Protocol interface to interact with Mackerel. It exposes a range of read and write operations for Mackerel data, including fetching alerts, dashboards, hosts, services, monitors, and traces, as well as retrieving metrics for hosts and services. The server can be run either via Docker or via npx, giving flexibility in deployment. To start using it, configure the MACKEREL_APIKEY environment variable with a valid API key and run the server through your preferred option. Once running, you can invoke the available tools through the MCP protocol to query and manipulate Mackerel data. The server acts as an adapter between generic MCP clients and the Mackerel API, translating MCP operations into Mackerel API calls.
How to install
Prerequisites:
- Node.js installed if you plan to use npx (node and npm are handled automatically by npx).
- Docker installed if you plan to run via Docker.
- A valid Mackerel API key.
Option 1: Run via Docker
- Ensure your MACKEREL_APIKEY is available in your environment.
- Start the container using the provided command:
docker run --rm -i -e MACKEREL_APIKEY -e MACKEREL_APIKEY ghcr.io/mackerelio-labs/mcp-server:latest
- The MCP server will start and listen for MCP requests.
Option 2: Run via npx
- Ensure your MACKEREL_APIKEY is available in your environment.
- Run the MCP server with npx:
npx -y @mackerel/mcp-server
- The MCP server will start and listen for MCP requests.
Environment variable notes:
- MACKEREL_APIKEY: Your Mackerel API key. This is required for both Docker and npx execution.
Additional notes
Tips and common issues:
- Always provide MACKEREL_APIKEY when starting the server; without it, API calls to Mackerel will fail.
- When running in Docker, ensure the host can reach the Mackerel API endpoint (network access and any required proxies).
- If you rotate your API key, restart the MCP server to pick up the new key.
- The available MCP operations cover alerts, dashboards, hosts, services, monitors, traces, and server stats for HTTP/database queries; use the tools list to determine the exact operations you can perform.
- If you encounter authentication errors, verify that the API key has the necessary permissions for the requested operations in Mackerel.
- The npm package name for the Node.js option is @mackerel/mcp-server.
Related MCP Servers
context7
Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
obsidian -tools
Add Obsidian integrations like semantic search and custom Templater prompts to Claude or any MCP client.
MiniMax -JS
Official MiniMax Model Context Protocol (MCP) JavaScript implementation that provides seamless integration with MiniMax's powerful AI capabilities including image generation, video generation, text-to-speech, and voice cloning APIs.
mcp-bundler
Is the MCP configuration too complicated? You can easily share your own simplified setup!
akyn-sdk
Turn any data source into an MCP server in 5 minutes. Build AI-agents-ready knowledge bases.
promptboard
The Shared Whiteboard for Your AI Agents via MCP. Paste screenshots, mark them up, and share with AI.