llms.txt Content
# searchcode MCP Server
- Server URL: https://api.searchcode.com/v1/mcp
- Well-known: https://api.searchcode.com/.well-known/mcp.json
- REST API: https://api.searchcode.com/api/v1/{tool_name}?client=your-app
- OpenAPI Spec: https://searchcode.com/openapi.json
- Transport: Streamable HTTP
> Code intelligence for LLMs. Analyze, search, and retrieve code from any public git repository.
searchcode.com provides an MCP server that gives LLMs structured access to code intelligence
tools for any public git repository — no pre-built index required. Point it at a repo URL and
get language breakdowns, complexity metrics, tech stack detection, static analysis, security
scanning, full-text code search, and file retrieval.
A plain JSON REST API is also available at `POST /api/v1/{tool_name}?client=your-app` for
non-MCP clients. All 6 tools are mirrored with the same parameters and response shapes.
See the [OpenAPI spec](https://searchcode.com/openapi.json) for full documentation.
## Installation
No install or API key required. Add the server URL to your MCP client config:
- **Claude Code** (current project): `claude mcp add searchcode --transport http https://api.searchcode.com/v1/mcp`
- **Claude Code** (global, all projects): `claude mcp add searchcode --scope user --transport http https://api.searchcode.com/v1/mcp`
- **Claude Desktop** (claude_desktop_config.json): `{"mcpServers": {"searchcode": {"command": "npx", "args": ["-y", "mcp-remote", "https://api.searchcode.com/v1/mcp"]}}}`
- **Cursor** (.cursor/mcp.json): `{"mcpServers": {"searchcode": {"url": "https://api.searchcode.com/v1/mcp"}}}`
- **VS Code / Copilot** (.vscode/settings.json): `{"mcp": {"servers": {"searchcode": {"url": "https://api.searchcode.com/v1/mcp"}}}}`
- **Gemini CLI** (~/.gemini/settings.json): `{"mcpServers": {"searchcode": {"httpUrl": "https://api.searchcode.com/v1/mcp"}}}`
- **Amp** (~/.config/amp/settings.json or .amp/settings.json): `{"amp.mcpServers": {"searchcode": {"url": "https://api.sea
OpenAPI Spec (preview)
{
"components": {
"parameters": {
"client": {
"description": "Client identifier for your application (e.g. 'my-app-v1'). Required for all REST API requests.",
"in": "query",
"name": "client",
"required": true,
"schema": {
"type": "string"
}
}
},
"schemas": {
"APIError": {
"properties": {
"error": {
"properties": {
"code": {
"description": "Machine-