A VS Code extension that provides a Claude Code style chat sidebar backed by Elastic Agent Builder Kibana APIs.

- Dedicated chat sidebar view with:
- Top bar with
Past Conversationsdropdown menu - Click-to-load previous conversations from the popout menu
- Agent selector
- Connector selector
- New chat action (
+in top bar) - Open-in-new-tab command
- Top bar with
- Start and continue conversations with Agent Builder:
POST /api/agent_builder/conversePOST /api/agent_builder/converse/async(SSE streaming)
- List agents and connectors:
GET /api/agent_builder/agentsGET /api/actions/connectors
- Local file attachment from active editor file (text only for MVP)
Attach Selectionfrom active editor with file + line range labelingMention File in Chatconvenience command- Streaming output with incremental assistant updates and Stop support
- Completed reasoning rendering when
stepsare returned - Optional assistant-proposed workspace file edits with explicit Apply confirmation
- Host-injected prompt instructions so the assistant emits
eac-file/eac-deleteblocks for file-change requests - API key configuration via extension setting
elasticAgentChat.apiKey - Redacted output logging in output channel
Elastic Agent Chat
- VS Code
1.90+ - Kibana / Elastic Agent Builder
9.2+ - Kibana API key with sufficient privileges (
read_agent_builderand connector access) - Attachment support on
converseendpoints requires Kibana9.3+(API-level attachment fields were added in 9.3).
Workspace settings under elasticAgentChat:
kibanaUrl(required)apiKey(required)spaceId(optional)streamingEnabled(default:true)visualizationsEnabled(default:true)workspaceWriteEnabled(default:false)maxAttachmentBytes(default:204800)maxTotalAttachmentBytes(default:1048576)binaryAttachmentPolicy(default:reject)redactionRules(default:["**/.env", "**/*key*"])connectorFilterMode(alldefault, optionalllm_only)panelTitle(default:Elastic Agent Chat)
Example .vscode/settings.json:
{
"elasticAgentChat.kibanaUrl": "https://my-kibana.example.com",
"elasticAgentChat.spaceId": "default",
"elasticAgentChat.streamingEnabled": true,
"elasticAgentChat.workspaceWriteEnabled": true
}Elastic Agent Chat: Open PanelElastic Agent Chat: Open In New TabElastic Agent Chat: Open SettingsElastic Agent Chat: Set Kibana API KeyElastic Agent Chat: New ChatElastic Agent Chat: Attach SelectionElastic Agent Chat: Mention File in Chat
Open Panel focuses the extension's sidebar view container (Elastic Agent Chat) in the Activity Bar.
Use the + action in the chat header (or Open In New Tab) to open an editor-tab instance of Elastic Agent Chat.
To place it on the right side like Claude Code, right-click the view title and choose Move View -> Secondary Side Bar.
Minimum required settings:
elasticAgentChat.kibanaUrlelasticAgentChat.apiKey
- API key is read from extension settings (
elasticAgentChat.apiKey) and is never sent to webview state. - API key is redacted in logs.
- Attachments are disabled in untrusted workspaces.
- Assistant workspace edits are disabled by default and require
elasticAgentChat.workspaceWriteEnabled=true. - Assistant workspace edits always require explicit user confirmation in a modal prompt before apply.
- Attachment redaction warnings are shown before upload when path matches configured patterns.
When elasticAgentChat.workspaceWriteEnabled is enabled, assistant messages can include one or more edit blocks.
Each assistant message that includes valid blocks shows an Apply edits button.
Supported formats:
```eac-file path=src/example.ts
export const example = true;
```
```eac-delete path=src/old.ts
```Or JSON:
```eac-workspace-edits
{
"edits": [
{ "action": "write", "path": "src/new.ts", "content": "export const x = 1;\n" },
{ "action": "delete", "path": "src/unused.ts" }
]
}
```Inline visualization block (for chat preview rendering):
```eac-viz title="Example chart" type=bar
{
"rows": [
{ "label": "A", "value": 10 },
{ "label": "B", "value": 7 }
]
}
```Install dependencies:
npm installBuild extension + webview:
npm run buildWatch mode:
npm run watchTypecheck:
npm run typecheckRun tests:
npm run test- Every push and pull request runs CI for
typecheck,test, andbuild. - Every pushed commit also generates a VSIX artifact (
dist/elastic-agent-chat.vsix) in the workflow run artifacts. - Pushing a tag like
v0.1.0triggers a release workflow that:- verifies the tag matches
package.jsonversion - reruns CI checks
- packages
dist/elastic-agent-chat.vsix - creates a GitHub Release with the VSIX attached for download/install in VS Code
- verifies the tag matches
Release flow:
npm version patch
git push --follow-tags401 Unauthorized- Re-run
Elastic Agent Chat: Set Kibana API Key.
- Re-run
403 Forbidden- Check Kibana privileges (
read_agent_builder) and connector permissions.
- Check Kibana privileges (
404 Not Found- Verify
kibanaUrlandspaceIdvalues.
- Verify
413 Payload Too Large- Reduce attachment size or count.
400 Bad Requestwhile using attachments- Verify Kibana is
9.3+and that Agent Builder converse attachments are supported in your deployment.
- Verify Kibana is
- No agents/connectors listed
- Validate Kibana URL, API key, and space prefix.
GET /api/agent_builder/agentsGET /api/actions/connectorsPOST /api/agent_builder/conversePOST /api/agent_builder/converse/async- Endpoint reference: Kibana Agent Builder API docs
- MVP stores only current conversation in workspace state.
- Local conversation history is stored in workspace state and selectable from the
Past Conversationslist. - Server-side persistent conversation attachments and diff approval workflow are intentionally deferred.