repolens_list_repositoriesLABSCO SUMMARY
Structural search, deliberately not a file toolkit.
It does one thing your assistant's built-in tools cannot: reach outside the current repository and find a definition by shape rather than by string. The AST pass is what makes the answers usable — you get the signature and whether it is exported, not a grep hit you have to open. Text search and file reads inside the repo you are already in are left to the tools that are better at them.
What it is
A search server for the case your editor cannot cover: you are in the frontend repo and the answer is in the backend one. It parses code with ast-grep rather than matching text, so it can tell class User from const User and return a full signature instead of a line. JavaScript, TypeScript and PHP are supported, across repositories you register once or directories you pass ad hoc.
What you get
repolens_find_functionsfinds function and method definitions, wildcards included, in JS/TS and PHPrepolens_find_classesfinds class definitions, and PHP traitsrepolens_find_typesfinds interfaces and type aliasesrepolens_find_api_routesmaps API endpoints across Express, NestJS, Fastify and Laravelrepolens_list_repositorieslists what is registered- Every search tool takes
pathsfor ad-hoc directories andrepoFilterto narrow to registered repos by alias
Requirements
Run it with npx -y repo-lens-mcp (package repo-lens-mcp, version 0.3.0) over stdio. No account, no key, nothing leaves the machine. A repolens.yaml listing repository paths and aliases is optional — pass --config to point at one, or drop it at ~/.config/repo-lens-mcp/repolens.yaml; without it the ad-hoc paths parameter still works. MCP_LOG_LEVEL controls logging.
Setup effort
One command — npx repo-lens-mcp
USE CASES
Finding the backend endpoint you are calling from the frontend
Map routes across Express, NestJS, Fastify or Laravel and filter to one repo by alias.
Locating a definition in a service you don't have open
Search for the class or function by name across every registered repository at once.
Checking whether a shared type already exists
Look for the interface or type alias before you write a second copy of it.
Searching a directory you never registered
Pass the path straight to the search tool — no config file needed.
5 tools
Listed in project docs. Your client may show a different list.
repolens_find_functionsrepolens_find_classesrepolens_find_typesrepolens_find_api_routesBEFORE YOU INSTALL
What to know first
Tools you get
5 tools named in the project's documentation.
Requires
npx on PATH
Where it runs
Both documented clients run the server on your machine.
INSTALLATION
Connect your client
Server setup
npx repo-lens-mcpMCP Clients
Claude Desktop
{
"mcpServers": {
"repo-lens": {
"command": "npx",
"args": [
"-y",
"repo-lens-mcp",
"--config",
"/home/<YOUR_USERNAME>/repolens.yaml"
]
}
}
}VS Code
{
"servers": {
"repo-lens": {
"command": "npx",
"args": [
"-y",
"repo-lens-mcp",
"--config",
"/home/<YOUR_USERNAME>/repolens.yaml"
]
}
}
}