• Applicable Software: MokoGIT
  • Min Version Number: 02.09.00
  • Max Version Number: Not Applicable

MokoMonitor is a Model Context Protocol (MCP) server that gives an AI assistant like Claude Code a live, read-only window into your server infrastructure. From one connection it can check server health, disk, memory, and running services over SSH; query Grafana dashboards, datasources, and active alerts; and verify site uptime across your monitored fleet. It turns "is everything healthy?" into a question you can simply ask in plain language.

What it is

MokoMonitor (@mokoconsulting/mcp-mokomonitor) is an MCP server for infrastructure monitoring. It exposes a focused set of tools that let an MCP-aware client — such as Claude Code — inspect server health, tail logs, review Grafana dashboards and alerts, and track the status of the sites you monitor.

Under the hood it connects to your servers over SSH (using standard key-based authentication) and talks to Grafana through its HTTP API. Health and diagnostic commands are read-only and run as fixed, non-interpolated commands, so the assistant can look but not tamper. The server communicates with the client over stdio, making it easy to register with any MCP client.

  • Package: @mokoconsulting/mcp-mokomonitor
  • Current version: 1.3.0
  • Runtime: Node.js 20 or later
  • License: GPL-3.0-or-later

Install (npm)

MokoMonitor is published to public npm under the @mokoconsulting scope. Install it globally:

npm install -g @mokoconsulting/mcp-mokomonitor

Prefer not to install anything? Run it on demand with npx:

npx -y @mokoconsulting/mcp-mokomonitor

MokoMonitor requires Node.js 20 or later. Once installed globally, the server is available as the monitor-mcp command. Optionally, you can pull the package from the MokoGIT registry mirror by adding this scope-to-registry mapping to your .npmrc:

@mokoconsulting:registry=https://git.mokoconsulting.tech/api/packages/MokoConsulting/npm/

Configure

MokoMonitor reads its configuration from ~/.mcp_mokomonitor.json (you can point it elsewhere with the MONITOR_MCP_CONFIG environment variable). This file defines your server connections and, optionally, your Grafana endpoint and a path to a sites.json monitoring definition.

Example configuration file (~/.mcp_mokomonitor.json):

{
  "defaultConnection": "prod",
  "connections": {
    "prod": {
      "host": "your-server.example.com",
      "port": 22,
      "username": "youruser",
      "keyPath": "~/.ssh/id_ed25519"
    }
  },
  "grafana": {
    "baseUrl": "https://grafana.example.com",
    "apiKey": "YOUR_GRAFANA_API_KEY"
  },
  "sitesJsonPath": "~/sites.json"
}

The grafana and sitesJsonPath blocks are optional — the Grafana tools activate only when baseUrl and apiKey are present.

Then register the server with your MCP client (for example, Claude Code) in its .mcp.json:

{
  "mcpServers": {
    "monitor": {
      "command": "npx",
      "args": ["@mokoconsulting/mcp-mokomonitor"]
    }
  }
}

Tooling

MokoMonitor exposes roughly 30 tools, grouped into four areas:

  • Server health (SSH)monitor_health (uptime, disk, memory, CPU, load in one shot), monitor_disk, monitor_memory, monitor_uptime, monitor_processes (top processes by CPU or memory), monitor_service (systemd service status), monitor_logs (tail any log file), and monitor_list_servers to see configured connections.
  • Extended host diagnostics (SSH)monitor_docker, monitor_docker_stats, and monitor_docker_containers for container status and resource usage; monitor_network (listening ports and connections); monitor_journal (systemd journal by service and priority); monitor_cron (active cron jobs); monitor_failed_logins (recent failed SSH attempts); monitor_reboot_required; and monitor_updates (available system updates).
  • Grafanagrafana_health, grafana_dashboards and grafana_dashboard_get, grafana_datasources, grafana_alerts and grafana_alert_rules, grafana_annotations, and grafana_query for running SQL or PromQL against a datasource over a time range.
  • Sites and monitoring infrastructuremonitor_sites, monitor_site_add, and monitor_site_remove manage the sites.json definition (site URL, type, client, optional API tokens); monitor_prometheus_targets, monitor_waas_heartbeats, monitor_nginx_status, and monitor_ntfy_status check the supporting monitoring stack.

Get help

Need a hand getting MokoMonitor connected, or want it configured for your environment? Open a support ticket with the MokoConsulting team, or call us at (931) 279-6313.