API reference
MCP tools
The six tools the Prometheus MCP server exposes over stdio. Includes input schemas and example responses.
The MCP server registers six tools. Each one is callable by any MCP-aware agent host (Claude Desktop, Cursor, Augment, your own runtime) once the server is wired up — see Claude Desktop for the canonical setup.
search_code
Hybrid retrieval over the indexed workspace. Combines BM25
(pg_trgm / tsvector) with vector cosine over Voyage embeddings,
then expands one hop in the symbol graph.
{
"name": "search_code",
"arguments": {
"query": "validate incoming webhook signature",
"limit": 8,
"filter": { "language": "ts", "pathPrefix": "src/api/" }
}
}
Returns an array of { file, range, symbol, snippet, score } entries.
get_symbol
Fetches a fully-qualified symbol by name, returning its definition text, file location, and visibility.
{
"name": "get_symbol",
"arguments": { "fqn": "src/queue.ts:RetryQueue.enqueue" }
}
find_references
Lists all call sites and re-exports of a symbol. Resolves through
re-exports and barrel files so an agent does not have to chase
export { X } from "./y" chains.
{
"name": "find_references",
"arguments": { "fqn": "src/billing.ts:chargeCustomer" }
}
expand_context
Given a list of symbols or file paths, returns the minimum surrounding context an agent needs to reason about them — imports, type declarations, immediate callers. Used to grow a tight retrieval into something a model can actually edit against.
{
"name": "expand_context",
"arguments": {
"seeds": ["src/queue.ts:RetryQueue"],
"tokenBudget": 4000
}
}
get_file
Verbatim file contents, optionally sliced to a line range. Use this instead of synthesising file content from search snippets.
{
"name": "get_file",
"arguments": { "path": "src/queue.ts", "range": [12, 84] }
}
list_changed_since
Returns files modified since a given commit or timestamp. Useful for incremental review flows ("what changed in this PR?") without re-running the indexer.
{
"name": "list_changed_since",
"arguments": { "since": "8f3a1c2" }
}