OpenSearch Dashboards logs

v0.2.0
io.github.mbaracz/mcp-opensearch-dashboards Checked 17 hours ago Published 15 hours ago

Search logs in OpenSearch Dashboards and follow one trace across Kubernetes namespaces and apps.

Values you need

VariableWhat it is
OSD_MCP_SOURCESrequired OpenSearch Dashboards URL, or name=url pairs separated by commas
OSD_MCP_USERrequired Dashboards user name, best an account that can only read the log indices
OSD_MCP_PASSWORDrequired secret Dashboards password
OSD_MCP_TENANToptional Dashboards tenant Default: global

npm (npx) discovery passed

Requires Node.js 18+

Run in a terminal
claude mcp add mcp-opensearch-dashboards -e 'OSD_MCP_PASSWORD=<OSD_MCP_PASSWORD>' -e 'OSD_MCP_SOURCES=<OSD_MCP_SOURCES>' -e 'OSD_MCP_USER=<OSD_MCP_USER>' -- npx -y mcp-opensearch-dashboards@0.1.1
Add to claude_desktop_config.json
{
  "mcpServers": {
    "mcp-opensearch-dashboards": {
      "args": [
        "-y",
        "mcp-opensearch-dashboards@0.1.1"
      ],
      "command": "npx",
      "env": {
        "OSD_MCP_PASSWORD": "<OSD_MCP_PASSWORD>",
        "OSD_MCP_SOURCES": "<OSD_MCP_SOURCES>",
        "OSD_MCP_USER": "<OSD_MCP_USER>"
      }
    }
  }
}
Add to ~/.cursor/mcp.json
{
  "mcpServers": {
    "mcp-opensearch-dashboards": {
      "args": [
        "-y",
        "mcp-opensearch-dashboards@0.1.1"
      ],
      "command": "npx",
      "env": {
        "OSD_MCP_PASSWORD": "<OSD_MCP_PASSWORD>",
        "OSD_MCP_SOURCES": "<OSD_MCP_SOURCES>",
        "OSD_MCP_USER": "<OSD_MCP_USER>"
      }
    }
  }
}
Add to .vscode/mcp.json
{
  "inputs": [
    {
      "description": "OSD_MCP_PASSWORD",
      "id": "osd-mcp-password",
      "password": true,
      "type": "promptString"
    },
    {
      "description": "OSD_MCP_SOURCES",
      "id": "osd-mcp-sources",
      "password": true,
      "type": "promptString"
    },
    {
      "description": "OSD_MCP_USER",
      "id": "osd-mcp-user",
      "password": true,
      "type": "promptString"
    }
  ],
  "servers": {
    "mcp-opensearch-dashboards": {
      "args": [
        "-y",
        "mcp-opensearch-dashboards@0.1.1"
      ],
      "command": "npx",
      "env": {
        "OSD_MCP_PASSWORD": "${input:osd-mcp-password}",
        "OSD_MCP_SOURCES": "${input:osd-mcp-sources}",
        "OSD_MCP_USER": "${input:osd-mcp-user}"
      },
      "type": "stdio"
    }
  }
}
Add to ~/.codex/config.toml
[mcp_servers.mcp-opensearch-dashboards]
command = "npx"
args = ["-y", "mcp-opensearch-dashboards@0.1.1"]
env = { "OSD_MCP_PASSWORD" = "<OSD_MCP_PASSWORD>", "OSD_MCP_SOURCES" = "<OSD_MCP_SOURCES>", "OSD_MCP_USER" = "<OSD_MCP_USER>" }

For AI agents

  1. Ask the user for: OSD_MCP_SOURCES, OSD_MCP_USER, OSD_MCP_PASSWORD. Never invent or guess these values; secrets go into the client config, not into chat logs.
  2. Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
  3. Restart or reload the client so it starts the server.
  4. Verify: the server should expose these tools: list_sources, list_index_patterns, list_fields, search_logs, get_trace.
  5. If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.

Machine-readable: install.md · manifest.json