list_repos
Lists the repos this MCP server can reach, and their aliases. On by default in both single-repo and workspace mode; one of the tools that takes no parameters.
Discovery, not analysis. list_repos tells the agent what repo
values are valid on every other tool. In single-repo mode there's one
alias ("default"); in workspace mode it's every configured repo in
the workspace, plus which one is the default.
When to call
- In workspace mode, before passing a
repoalias to another tool, if the agent doesn't already know the workspace's repo names. - Rarely needed in single-repo mode: there's only one repo, and every other tool defaults to it.
Parameters
None. list_repos() takes no arguments.
Returns
Single-repo mode:
| Field | Meaning |
|---|---|
workspace | false |
workspace_root | null |
default_repo | "default" |
repos | One entry: {alias: "default", path, absolute_path, is_default: true} |
hint | One-line reminder that repo is unnecessary in single-repo mode |
Workspace mode:
| Field | Meaning |
|---|---|
workspace | true |
workspace_root | Absolute path to the workspace root |
default_repo | The default repo's alias |
repos | Every configured repo: alias, path, absolute_path, is_default, indexed_at, last_commit_at_index |
hint | One-line reminder to pass repo='<alias>' on tools that accept it |
Example
list_repos()Things worth knowing
- No freshness envelope. Unlike most tools,
list_reposdoesn't carry_meta.index_behind/stale_warningfields, since it serves configuration, not indexed content. - Live-reloaded in workspace mode. The
indexed_atandlast_commit_at_indexfields are re-read from the workspace config on each call, so they track arepowise updatethat ran after this MCP server started, without a restart.
Pair with any tool that accepts a repo parameter: call list_repos()
once at the start of a workspace session, then pass the alias you need
on get_context, get_risk, search_codebase, and the rest.
get_health
Code-health scores and marker findings per file across three signals (defect risk, maintainability, performance), exposed to your agent so it can self-check a change before opening a PR.
generate_refactoring_code
Turns one structured refactoring plan from get_health(include=["refactoring"]) into generated code and a unified diff, grounded on the plan plus the real source it references.