Connect Elasticsearch to Your AI Agent

Identify an index and a question to analyze its documents, mappings, and operational state.

21 tools API key / Custom credential

Try a Elasticsearch Task

Copy a prompt into your agent with the oo Skill installed. Add your page links and source notes before running it.

oo Skill Elasticsearch

Inspect index fields and retrieve documents matching your question.

Investigate Cluster Health

Compare cluster health, node information, and shard placement.

/oo Elasticsearch: Read Elasticsearch cluster health, nodes, and shards for [index name]. Summarize unassigned shards and resource concerns shown by the data.

Start Working with Elasticsearch

  1. Install OOMOL

    Set up oo CLI and the oo Skill in your agent.

    Install OOMOL →
  2. Connect Elasticsearch

    Connect an encoded API key or a username and password, together with your Elasticsearch URL.

    Connect Elasticsearch →
  3. Give Your Agent a Task

    Use /oo with the pages to read, the changes to make, and where to save the result.

    Connection Guide →

Choose Your Agent

  • A publicly reachable deployment and credentials with permissions for the target indices.
  • Search counters accumulate since node startup. Compare them with node uptime when interpreting index usage.

Elasticsearch Tools

The connection supports index and document queries, cluster diagnostics, and selected index and document writes. Reindexing runs in the background and exposes a task for progress checks.

Query Indices and Documents

Read mappings, search and count documents, and retrieve individual documents.

Inspect Cluster and Index Operations

Read cluster diagnostics and index statistics, or check a background reindex task.

21 tools

Ping Cluster

Check whether the Elasticsearch cluster is reachable and return its health status.

elasticsearch.ping_cluster

List Indices

List Elasticsearch indices visible to the connected user.

elasticsearch.list_indices

Get Index Schema

Get mappings, settings, aliases, and field statistics for one Elasticsearch index.

elasticsearch.get_index_schema

Query Index

Search an Elasticsearch index with text queries, filters, pagination, sorting, and aggregations.

elasticsearch.query_index

Create Index

Create one Elasticsearch index with explicit mappings, settings, and aliases.

elasticsearch.create_index

Delete Index

Permanently delete one or more Elasticsearch indices by exact name. This destroys data and cannot be undone, so wildcards, comma-separated lists, and _all are rejected, and expectedCount must equal the number of names supplied.

elasticsearch.delete_index

Update Index Mappings

Add or update field mappings on an existing Elasticsearch index. Existing field types cannot be changed in place, so incompatible changes require a new index and a reindex.

elasticsearch.update_index_mappings

Get Index Stats

Get document, store, search, get, and indexing statistics for Elasticsearch indices. Counters such as searchQueryTotal are cumulative since each node started rather than a time window, so compare them against the node uptime in counterWindow before concluding that a zero means the index is never queried.

elasticsearch.get_index_stats

List Aliases

List Elasticsearch aliases and the indices behind them, optionally filtered by alias or index pattern.

elasticsearch.list_aliases

Update Aliases

Atomically add or remove Elasticsearch alias assignments in a single request, which is how an alias is switched between indices without downtime. This action cannot delete an index; use delete_index for that.

elasticsearch.update_aliases

Get Cluster Health

Get detailed Elasticsearch cluster health including shard counts and an optional per-index breakdown.

elasticsearch.get_cluster_health

Get Cluster Nodes

List Elasticsearch cluster nodes with uptime, heap, disk, and role information. Node uptime is what makes the cumulative counters from get_index_stats interpretable.

elasticsearch.get_cluster_nodes

List Shards

List Elasticsearch shard placement, state, and size, optionally limited to an index pattern or a shard state.

elasticsearch.list_shards

Get Document

Get one Elasticsearch document by id. A missing document returns found as false instead of raising an error.

elasticsearch.get_document

Index Document

Index or replace one document in an Elasticsearch index. Supplying documentId replaces that document, while omitting it lets Elasticsearch generate an id.

elasticsearch.index_document

Delete Document

Delete one Elasticsearch document by id. A missing document returns a not_found result instead of raising an error.

elasticsearch.delete_document

Bulk Index Documents

Apply many Elasticsearch document writes in one bulk request. Each operation names its own index, and per-operation failures are reported in the response instead of failing the whole request.

elasticsearch.bulk_index_documents

Count Documents

Count Elasticsearch documents matching a query without returning any hits, which is cheaper than a search when only the size of a result set matters.

elasticsearch.count_documents

Delete By Query

Delete Elasticsearch documents matching a query. This destroys data and cannot be undone, so a bounded maxDocs and at least one of query, termFilters, rangeFilters, or timeFilter are required, the index name must be exact, and _all is rejected. That makes it impossible to empty an entire index by accident. The action waits for the deletion to finish, and a large maxDocs can outlast that wait: a timeout does not cancel the deletion, which keeps running on the cluster with no task id to poll, so a retry after a timeout deletes a further batch.

elasticsearch.delete_by_query

Reindex

Start an Elasticsearch reindex from one index to another and return a task id to poll with get_task. The copy runs in the background, so this action returns before the data has moved.

elasticsearch.reindex

Get Task

Get the state and progress of one Elasticsearch task, such as a reindex started by the reindex action.

elasticsearch.get_task

Frequently Asked Questions

How can I ask for a focused search?

Provide the index name, search text, filters, and fields to summarize. Inspect mappings if you do not know the field names.

Does zero search activity mean an index is unused?

Counters reset when nodes restart. Check node uptime and the counter window before drawing conclusions.

How do I know a reindex has finished?

Reindex submission returns a task ID. Query that task until it completes and review its result or failures.

Connect Elasticsearch

About Elasticsearch ↗