Getting started
Requirements
- Node.js 22+
- A Kibana-compatible read endpoint reachable with basic auth
- No index for bootstrap. Select the exact index or pattern later with
configure_index; hand-authored catalogs remain an advanced option.
Installation
Prompt-free connection bootstrap
- Provision the connection through a trusted environment, then run:
Never pass passwords as command-line arguments. Use KIBANA_PASSWORD, --password-env NAME, or --password-stdin.
export KIBANA_BASE_URL='https://kibana.example.com'
export KIBANA_USERNAME='elastic'
export KIBANA_PASSWORD='use-a-secret-provider'
npx -y @havesomecode/kibana-mcp-server bootstrap \
--client codexExpected: no prompts with these values supplied; a verified connection, secure credentials, an empty managed catalog on first install, and registration of the exact running package transport. No direct Codex config edits or index listing, scanning, inference, or configuration.
- Start the server without
KIBANA_BASE_URL,KIBANA_USERNAME, andKIBANA_PASSWORDto use the saved profile. Direct startup requires an explicitKIBANA_SOURCE_CATALOG_PATHor configuration-file store; no implicit checkout catalog. - Reconnect the client and call
discover. If empty, ask the user for the exact Kibana index or pattern and wait. Never guess, list, or scan indexes. Callconfigure_indexonly with their answer; it validates and saves only that index and accepts no credentials.
Reruns preserve explicitly configured sources. Bootstrap refuses to replace hand-authored or modified catalogs without --replace. Use that flag only with operator approval: it creates an empty managed catalog.
Install the agent skill
Run:
npx skills add Havesomecode/kibana-mcp-server \
--skill kibana-log-investigation \
--agent codex \
--global \
--yesExpected: the skill at skills/kibana-log-investigation/SKILL.md teaches bootstrap instead of manual MCP config edits.
Use in Codex
Use package bootstrap above for Codex. Use the repo plugin below only from a cloned checkout.
Quick path
- Clone the repository.
- Check Node.js 22+ (pinned in
.node-version). If missing, ask Codex to useensure-node-runtime. - From the repo root, run:
npm install
npm run buildInstall the built plugin
- Open the cloned repo in Codex.
- Install
Kibana Log Investigationfrom the repo marketplace in Codex's plugin directory. If the model cannot install it, click in the UI yourself, then let the agent continue. - Run
node dist/src/bin/kibana-mcp-server.js bootstrap --client none. This verifies the connection and creates an empty catalog on first install; the plugin already registers the server. - Reconnect the MCP process and check startup status. On failure, inspect sanitized stderr; rebuild and reinstall a missing runtime. After startup succeeds, restart once if tools need refreshing.
- In a fresh thread, call
discover. If empty, ask for the exact index or pattern and wait; only then callconfigure_index.
Repo-scoped plugin files:
.agents/plugins/marketplace.jsonplugins/kibana-log-investigation/.codex-plugin/plugin.jsonplugins/kibana-log-investigation/.mcp.jsonplugins/kibana-log-investigation/mcp-launcher.mjsplugins/kibana-log-investigation/dist/(generated self-contained runtime and notices)
Minimal handoff prompt
Send this prompt with the repo link:
Install the `kibana-log-investigation` skill from Havesomecode/kibana-mcp-server, then run its connection-only bootstrap with the provisioned KIBANA_BASE_URL, KIBANA_USERNAME, and KIBANA_PASSWORD values. Do not edit Codex config files, import the example catalog, or inspect indexes. After install, ask me which exact index or pattern to configure before calling configure_index.