Back to Home
elastic icon

semantic-code-search-mcp-server

Verified Safe

by elastic

Overview

This MCP server exposes indexed code data to AI coding agents, enabling structured interaction for codebase understanding, code discovery, symbol analysis, and file content reconstruction.

Installation

Run Command
ELASTICSEARCH_ENDPOINT=http://localhost:9200 npx github:elastic/semantic-code-search-mcp-server

Environment Variables

  • ELASTICSEARCH_CLOUD_ID
  • ELASTICSEARCH_API_KEY
  • ELASTICSEARCH_USER
  • ELASTICSEARCH_PASSWORD
  • ELASTICSEARCH_ENDPOINT
  • ELASTICSEARCH_INDEX

Security Notes

The server uses `JSON.parse` but only on internally generated and stringified data, which is a safe pattern. Configuration, including Elasticsearch credentials, is loaded from environment variables, preventing hardcoded secrets. There is no usage of 'eval' or other dynamic code execution from arbitrary inputs. External network calls are limited to the configured Elasticsearch instance. Overall, the security posture appears robust for its intended use.

Similar Servers

Stats

Interest Score36
Security Score9
Cost ClassHigh
Avg Tokens10000
Stars7
Forks4
Last Update2026-01-13

Tags

Semantic SearchCode AnalysisAI Agent ToolsElasticsearchCodebase Exploration