Elasticsearch MCP by usefulapi
Check cluster health, read indices and mappings, and search or count documents in Elasticsearch.
¿Debería usar esto?
Calidad y seguridad
Hallazgos (1)
- LOWen elasticsearch_list_data_streams
Basado en el análisis automatizado de las definiciones de herramientas y el cumplimiento del protocolo.
Costo de contexto
Este es el número aproximado de tokens que se consumen cada vez que las herramientas del servidor se cargan en el contexto de un modelo. Los recuentos más altos reducen la atención disponible para otras tareas.
Instalar
Instalación con un clic
Agrega esto a tu archivo `claude_desktop_config.json`:
{
"mcpServers": {
"elasticsearch": {
"url": "https://elasticsearch.usefulapi.io/mcp"
}
}
}Puntos de conexión remotos
https://elasticsearch.usefulapi.io/mcpstreamable-httpQué puede hacer
Inventario de herramientas
Herramientas (13)
🟢elasticsearch_cluster_info
Get the cluster name, node name, and Elasticsearch version of this cluster. Good first call to confirm the connection. API: GET /.
Esquema de entrada
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_cluster_health(level)
Get cluster health status (green, yellow, red), node and shard counts, and unassigned shards. API: GET /_cluster/health.
Esquema de entrada
{
"type": "object",
"properties": {
"level": {
"description": "Detail level (default cluster).",
"type": "string",
"enum": [
"cluster",
"indices",
"shards"
]
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_cluster_stats
Get cluster-wide statistics: document and store totals, node count, JVM memory, and versions. API: GET /_cluster/stats.
Esquema de entrada
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_list_nodes
List cluster nodes with roles, heap and disk usage, CPU, and load. API: GET /_cat/nodes (format=json).
Esquema de entrada
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_list_indices(index, health)
List indices with health, status, document count, store size, and shard counts. Optional name pattern. API: GET /_cat/indices (format=json).
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"description": "Index name or wildcard pattern, e.g. logs-*. Omit to list all.",
"type": "string",
"minLength": 1
},
"health": {
"description": "Only indices with this health.",
"type": "string",
"enum": [
"green",
"yellow",
"red"
]
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_get_index(index)
Get an index's settings, mappings, and aliases in one call. API: GET /{index}.
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"type": "string",
"minLength": 1,
"description": "Index, alias or data stream name. Comma lists and wildcards work, e.g. logs-*."
}
},
"required": [
"index"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_get_mapping(index)
Get the field mappings (field names and types) of an index, alias or data stream. Read this before writing a search query. API: GET /{index}/_mapping.
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"type": "string",
"minLength": 1,
"description": "Index, alias or data stream name. Comma lists and wildcards work, e.g. logs-*."
}
},
"required": [
"index"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_list_aliases(name)
List index aliases and the indices they point to. API: GET /_alias or GET /_alias/{name}.
Esquema de entrada
{
"type": "object",
"properties": {
"name": {
"description": "Name or wildcard pattern. Omit to list all.",
"type": "string",
"minLength": 1
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_list_data_streams(name)
List data streams with their backing indices, generation, and status. API: GET /_data_stream or GET /_data_stream/{name}.
Esquema de entrada
{
"type": "object",
"properties": {
"name": {
"description": "Name or wildcard pattern. Omit to list all.",
"type": "string",
"minLength": 1
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_search(index, query, size, from, sort, ...)
Search documents in one or more indices with a Query DSL object. Returns hits, total count, and optional aggregations. Use elasticsearch_get_mapping first to learn the field names. API: POST /{index}/_search.
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"type": "string",
"minLength": 1,
"description": "Index, alias or data stream name. Comma lists and wildcards work, e.g. logs-*."
},
"query": {
"description": "Elasticsearch Query DSL object, e.g. {\"match\": {\"title\": \"invoice\"}}. Omit to match all documents.",
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
},
"size": {
"description": "Number of hits to return (0-100, default 10).",
"type": "integer",
"minimum": 0,
"maximum": 100
},
"from": {
"description": "Offset of the first hit (0-10000).",
"type": "integer",
"minimum": 0,
"maximum": 10000
},
"sort": {
"description": "Sort clauses, e.g. [{\"created_at\": \"desc\"}].",
"type": "array",
"items": {}
},
"source_fields": {
"description": "Only return these fields of each document (_source filter).",
"type": "array",
"items": {
"type": "string"
}
},
"aggs": {
"description": "Aggregations object, e.g. {\"by_status\": {\"terms\": {\"field\": \"status\"}}}.",
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
}
},
"required": [
"index"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_count(index, query)
Count the documents that match a Query DSL object in one or more indices. API: POST /{index}/_count.
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"type": "string",
"minLength": 1,
"description": "Index, alias or data stream name. Comma lists and wildcards work, e.g. logs-*."
},
"query": {
"description": "Elasticsearch Query DSL object, e.g. {\"match\": {\"title\": \"invoice\"}}. Omit to match all documents.",
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
}
},
"required": [
"index"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_get_document(index, id, source_fields, routing)
Get one document by index and id. Optional source_fields limits the returned fields. API: GET /{index}/_doc/{id}.
Esquema de entrada
{
"type": "object",
"properties": {
"index": {
"type": "string",
"minLength": 1,
"description": "Index or alias that holds the document."
},
"id": {
"type": "string",
"minLength": 1,
"description": "Document id."
},
"source_fields": {
"description": "Only return these fields.",
"type": "array",
"items": {
"type": "string"
}
},
"routing": {
"description": "Routing value, if the document was indexed with one.",
"type": "string"
}
},
"required": [
"index",
"id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢elasticsearch_esql_query(query)
Run a read-only ES|QL query, e.g. 'FROM logs-* | WHERE status >= 500 | STATS count = COUNT(*) BY service | LIMIT 20'. Returns columns and rows. API: POST /_query.
Esquema de entrada
{
"type": "object",
"properties": {
"query": {
"type": "string",
"minLength": 1,
"maxLength": 10000,
"description": "The ES|QL query text."
}
},
"required": [
"query"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}Comunidad
Evidencia