gograph_callees
Find functions and methods called by a specified Go function to map downstream dependencies. Returns callee symbols with package paths, file locations, and call-site line numbers, with optional depth expansion.
Instructions
Find functions and methods called by the specified function. Defaults to one-hop fan-out; depth 2-10 expands the downstream call graph. The MCP server refreshes source analysis before the call. Read-only; no persistent side effects. WHEN TO USE: To understand a function's downstream dependencies. NOT TO USE: For upstream callers (use gograph_callers); for package dependency trees (use gograph_deps). RETURNS: Callee symbols with package paths, file locations, and call-site line numbers; with mermaid=true, Mermaid flowchart text.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| root | No | Absolute path of the checkout you are working in (your cwd or git worktree). Must be this server's repository or one of its git worktrees; the answer then comes from that checkout's own graph. A path elsewhere is refused. Alias: cwd. Omit only when the configured checkout is the one you mean. | |
| depth | No | Traversal depth from 1 to 10 (default 1) | |
| limit | No | Maximum rows per page; the byte budget may return fewer. | |
| cursor | No | Opaque next_cursor for the same graph snapshot and result selection. | |
| mermaid | No | Return Mermaid flowchart text instead of the normal response | |
| function | Yes | The name of the calling function to inspect callees for (supports short name 'Serve', dot-notation 'graph.Graph.Build', or fully-qualified ID) | |
| no_tests | No | Exclude call edges originating in *_test.go files | |
| intention | No | Technical rationale, required for analytical calls selecting an active session. | |
| session_id | No | Caller selector returned by session_create. Omission means an independent caller; never inherits server environment or another caller's session. |