search_indexLABSCO SUMMARY
Three read tools that answer what is in this cluster without opening Kibana.
Listing the indices and then reading one mapping gives an agent the shape of the data before it searches, which is the step that otherwise costs several failed queries. Everything in the set reads: there is no indexing, update or delete call here.
What it is
A Python server, built on FastMCP, that connects to an Elasticsearch cluster and exposes search, index listing and mapping inspection.
What you get
- Every index on the cluster, with the system indices left out (list_indices)
- The mapping for a named index, so you know which fields exist before you query them (get_index_mappings)
- A query-string search against an index (search_index)
Requirements
Python 3.8 or newer, uv or pip, and a reachable Elasticsearch cluster. Its address, plus a username and password, go in the environment.
Setup effort
Build from source — git clone https://github.com/Akhilvis/elastic-mcp
USE CASES
Finding out which indices a cluster actually holds
List them with the system indices filtered out, so what comes back is your data.
Learning a field layout before writing a query
Read the mapping for the index and see the field names and types you can search on.
Answering a question from log or document data
Find the right index, read its mapping, then run the query string against it.
Checking a cluster is reachable and the credentials work
One index listing either returns the cluster contents or fails at the connection, before anything depends on it.
3 tools
Listed in project docs. Your client may show a different list.
list_indicesget_index_mappingsBEFORE YOU INSTALL
What to know first
Tools you get
3 tools named in the project's documentation.
Requires
- Python 3.8+
- ELASTIC_PASSWORD in your environment
- ELASTIC_USERNAME in your environment
Where it runs
The documented client runs the server on your machine.
INSTALLATION
Connect your client
You clone this one yourself.
Server setup
git clone https://github.com/Akhilvis/elastic-mcp
cd elastic-mcp
uv pip install -r requirements.txtMCP Clients
Claude Desktop
{
"mcpServers": {
"Elastic MCP Server": {
"command": "uv",
"args": [
"run",
"--with-requirements",
"<YOUR_ABSOLUTE_PATH_TO_REQUIREMENTS_TXT>",
"fastmcp",
"run",
"<YOUR_ABSOLUTE_PATH_TO_ELASTIC_TOOL>"
],
"env": {
"ELASTIC_URL": "http://localhost:9200",
"ELASTIC_USERNAME": "<YOUR_ELASTIC_USERNAME>",
"ELASTIC_PASSWORD": "<YOUR_ELASTIC_PASSWORD>"
}
}
}
}