Feedback

Octodet Elasticsearch Mcp

@octodet Claim

Basic information

Category
License
MIT
Transports
stdio
Author
octodet
Submitted by
Community
Quality
20

About Octodet Elasticsearch Mcp Server

A complete Elasticsearch mcp server with many tools

Octodet Elasticsearch Mcp is a MCP server in the Databases category listed in the AddMCP.net directory, published by Octodet. It exposes 16 tools, including list_indices, get_mappings, search, get_cluster_health and more. Supported transport: stdio. License: MIT. Source code is hosted on github.com. Related topics: elasticsearch.

Setup

{
    "mcpServers": {
        "elasticsearch": {
            "command": "npx",
            "args": [
                "-y",
                "@octodet/elasticsearch-mcp"
            ],
            "env": {
                "ES_URL": "http://localhost:9200",
                "ES_API_KEY": "your_api_key",
                "ES_VERSION": "8"
            }
        }
    }
}

Octodet Elasticsearch Mcp config

Add this server to your MCP-compatible client using the configuration below.

{
    "mcpServers": {
        "elasticsearch": {
            "command": "npx",
            "args": [
                "-y",
                "@octodet/elasticsearch-mcp"
            ],
            "env": {
                "ES_URL": "http://localhost:9200",
                "ES_API_KEY": "your_api_key",
                "ES_VERSION": "8"
            }
        }
    }
}

Octodet Elasticsearch Mcp tools

  • list_indices — List all available Elasticsearch indices with detailed information
    indexPattern:string*
  • get_mappings — Get field mappings for a specific Elasticsearch index
    index:string*
  • search — Perform an Elasticsearch search with the provided query DSL, highlighting, and script fields
    index:string*, queryBody:object*, scriptFields:object
  • get_cluster_health — Get health information about the Elasticsearch cluster
    (no parameters)
  • get_shards — Get shard information for all or specific indices
    index:string
  • add_document — Add a new document to a specific Elasticsearch index
    index:string*, id:string, document:object*
  • update_document — Update an existing document in a specific Elasticsearch index
    index:string*, id:string*, document:object*
  • delete_document — Delete a document from a specific Elasticsearch index
    index:string*, id:string*
  • update_by_query — Update documents in an Elasticsearch index based on a query
    index:string*, query:object*, script:object*, conflicts:string, maxDocs:integer, refresh:boolean
  • delete_by_query — Delete documents in an Elasticsearch index based on a query
    index:string*, query:object*, conflicts:string, maxDocs:integer, refresh:boolean
  • bulk — Perform multiple document operations (create, update, delete) in a single API call
    operations:array*, pipeline:string
  • create_index — Create a new Elasticsearch index with optional settings and mappings
    index:string*, settings:object, mappings:object
  • delete_index — Delete an Elasticsearch index
    index:string*
  • count_documents — Count documents in an index, optionally filtered by a query
    index:string*, query:object
  • get_templates — Get index templates from Elasticsearch
    name:string
  • get_aliases — Get index aliases from Elasticsearch
    name:string

Overview

What is Octodet Elasticsearch Mcp?

Octodet Elasticsearch Mcp is a Model Context Protocol (MCP) server that provides a comprehensive set of tools for interacting with Elasticsearch clusters. It enables LLM-powered applications to search, update, and manage Elasticsearch data through the standardized Model Context Protocol.

How to use Octodet Elasticsearch Mcp?

Install the package globally with npm install -g @octodet/elasticsearch-mcp or run it directly with npx @octodet/elasticsearch-mcp. Configure the connection using environment variables such as ES_URL, ES_API_KEY, ES_USERNAME, ES_PASSWORD, ES_CA_CERT, ES_VERSION, ES_SSL_SKIP_VERIFY, and ES_PATH_PREFIX. Integrate with MCP clients like VS Code or Claude Desktop by adding the server configuration to their settings, specifying the command, arguments, and environment variables.

Key features of Octodet Elasticsearch Mcp

  • Full CRUD operations for documents and indices
  • Bulk operations for multiple document actions in one API call
  • Query-based updates and deletions by matching documents
  • Cluster health and shard monitoring
  • Advanced search with full Elasticsearch DSL and highlighting
  • 16 MCP tools covering all major Elasticsearch operations

Use cases of Octodet Elasticsearch Mcp

  • Search and retrieve documents from Elasticsearch indices using complex DSL queries
  • Add, update, and delete documents programmatically through LLM interactions
  • Perform bulk indexing or maintenance operations efficiently
  • Monitor cluster health and manage index templates and aliases
  • Automate document lifecycle management with query-based updates and deletions

Frequently asked questions

1 What environment variables are required to connect to Elasticsearch?

The server requires ES_URL (default http://localhost:9200). Authentication can be set with ES_API_KEY or ES_USERNAME/ES_PASSWORD. Optional variables include ES_CA_CERT, ES_VERSION (8 or 9), ES_SSL_SKIP_VERIFY, and ES_PATH_PREFIX.

2 How do I integrate Octodet Elasticsearch Mcp with VS Code?

Add a configuration entry in your VS Code settings.json under mcp.servers with the command npx -y @octodet/elasticsearch-mcp and the required environment variables (e.g., ES_URL, ES_API_KEY).

3 Which Elasticsearch versions are supported?

The ES_VERSION environment variable accepts 8 or 9, with a default of 8.

4 What transport does the MCP server use?

The server implements the Model Context Protocol and can be used with any MCP-compatible client. It does not specify a custom transport in the README; examples show usage via command-line invocation and the MCP SDK’s default transport.

5 Can I use Octodet Elasticsearch Mcp programmatically in Node.js?

Yes, the package exports createOctodetElasticsearchMcpServer for programmatic integration. You can configure an Elasticsearch connection and use a custom transport via the MCP SDK.

Comments

No comments yet

Be the first to share feedback about this listing. Sign in to leave a comment.

Sign In

Feedback 💬