Skip to content

Commit dc9205e

Browse files
committed
Docs: Clarify ES_API_KEY usage and version compatibility
This commit enhances the documentation to provide clearer guidance on Elasticsearch API key (ES_API_KEY) usage: - **config-elasticsearch-example.json:** Added a note under the HTTP configuration to clarify that the is set on the standalone Elasticsearch MCP server (e.g., via a command), not within this file when using HTTP mode. - **IMPLEMENTATION_PLAN.md:** Updated Phase 2.1 to explicitly state that is supported on Elasticsearch 8.x+ (and 7.x+) and to differentiate where it should be configured for stdio mode (in 's env block) versus HTTP mode (on the external MCP server's startup command). These changes aim to prevent confusion regarding API key compatibility with Elasticsearch versions and its configuration location based on the connection mode. AI-assisted-by: Gemini
1 parent 83b406f commit dc9205e

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

IMPLEMENTATION_PLAN.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,9 @@ Before starting Phase 1, ensure you have:
184184
- `api_key` (Horreum only): The API key for authentication.
185185
- `stdio_args` (Elasticsearch only): A list of arguments for the Source MCP command.
186186
- `timeout_seconds`: Optional timeout for connection (defaults to 30).
187+
* **🔑 Auth Note:** `ES_API_KEY` is supported on Elasticsearch 8.x+ (and 7.x+). It is the preferred authentication method over username/password.
188+
- **Stdio Mode:** Set `ES_API_KEY` in `config.json` (env block).
189+
- **HTTP Mode:** Set `ES_API_KEY` when starting the *external* MCP server (e.g., in your `docker run` command). Do NOT put it in this `config.json`.
187190
* **💡 Tip for Podman Users:** If using Podman, set the `endpoint` to your podman run command.
188191
- Example: `"endpoint": "podman run -i --rm -e ELASTICSEARCH_URL=... mcp-server-elasticsearch"`
189192
- Ensure `-i` (interactive) is used so stdin/stdout are connected.

config-elasticsearch-example.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
"_url_note_3": "If remote doesn't work: Switch to HTTP mode (see alternative config below)",
4848

4949
"ES_API_KEY": "your-elasticsearch-api-key-here",
50-
"_api_key_note": "Get API key from ES: POST /_security/api_key (requires manage_api_key privilege)",
50+
"_api_key_note": "Supported on ES 8.x+ (and 7.x+). Get API key: POST /_security/api_key",
5151
"_alternative_auth": "Or use ES_USERNAME and ES_PASSWORD instead (check ES MCP docs)"
5252
},
5353
"timeout_seconds": 30
@@ -58,6 +58,7 @@
5858
"_comment": "USE THIS CONFIG if stdio mode has networking issues (recommended for production)",
5959
"_step_1": "Start Elasticsearch MCP as separate HTTP server:",
6060
"_start_command": "docker run -d --name es-mcp -e ES_URL='http://your-es:9200' -e ES_API_KEY='your-key' -p 8080:8080 docker.elastic.co/mcp/elasticsearch http",
61+
"_auth_clarification": "NOTE: The ES_API_KEY is passed to the docker command above, NOT in this config file (when using HTTP mode).",
6162
"_step_2": "Copy the config below to replace the 'sources' section above",
6263
"_step_3": "Restart your Domain MCP server",
6364

0 commit comments

Comments
 (0)