Skip to main content
Glama

gograph_callees

Read-onlyIdempotent

Find functions and methods called by a specified Go function. Reveal downstream dependencies up to 10 hops with callee symbols, file locations, and call-site line numbers.

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

TableJSON Schema
NameRequiredDescriptionDefault
depthNoTraversal depth from 1 to 10 (default 1)
limitNoMaximum rows per page; the byte budget may return fewer.
cursorNoOpaque next_cursor for the same graph snapshot and result selection.
mermaidNoReturn Mermaid flowchart text instead of the normal response
functionYesThe name of the calling function to inspect callees for (supports short name 'Serve', dot-notation 'graph.Graph.Build', or fully-qualified ID)
no_testsNoExclude call edges originating in *_test.go files

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.7.5
    • addedInput schema / properties / cursor
      Added value: +{
      +  "description": "Opaque next_cursor for the same graph snapshot and result selection.",
      +  "maxLength": 128,
      +  "type": "string"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "default": 100,
      +  "description": "Maximum rows per page; the byte budget may return fewer.",
      +  "maximum": 200,
      +  "minimum": 1,
      +  "type": "integer"
      +}
  2. Changed2 schema fields changedv1.5.6
    • changedInput schema / properties / depth / type
      Previous value: -"number"New value: +"integer"
    • addedInput schema / properties / mermaid
      Added value: +{
      +  "description": "Return Mermaid flowchart text instead of the normal response",
      +  "type": "boolean"
      +}
  3. Addedv1.5.4
  4. Removedv1.5.3
  5. Changed2 schema fields changed
    • addedInput schema / properties / depth
      Added value: +{
      +  "description": "Traversal depth from 1 to 10 (default 1)",
      +  "type": "number"
      +}
    • addedInput schema / properties / no_tests
      Added value: +{
      +  "description": "Exclude call edges originating in *_test.go files",
      +  "type": "boolean"
      +}
  6. Changed1 schema field changed
    • changedInput schema / properties / function / description
      Previous value: -"The name of the calling function to inspect callees for (e.g., 'Serve', 'runMCP')"New value: +"The name of the calling function to inspect callees for (supports short name 'Serve', dot-notation 'graph.Graph.Build', or fully-qualified ID)"
  7. Changed1 schema field changedv1.4.70
    • changedInput schema / properties / function / description
      Previous value: -"The name of the calling function (e.g., 'InitServer')"New value: +"The name of the calling function to inspect callees for (e.g., 'Serve', 'runMCP')"
  8. First observedv1.0.0

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint/idempotentHint/destructiveHint, so safety is covered; the description nonetheless adds genuinely new behavioral context, namely that the MCP server refreshes source analysis before the call and that depth 2-10 expands the traversal. It stops short of latency/cost implications of that refresh, so not quite a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose and defaults, then cleanly sectioned into WHEN/NOT TO USE and RETURNS. Dense but every sentence carries distinct information; no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the RETURNS section correctly carries the return-shape burden (callee symbols, package paths, file locations, call-site line numbers, Mermaid text) and the refresh behavior is disclosed. An agent has everything needed to invoke and interpret results.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3; the description goes further by explaining the default fan-out and the depth 2-10 expansion semantics, and by naming the mermaid=true alternate response mode. It adds meaning beyond the schema rather than restating it.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Find functions and methods called by the specified function') and immediately scopes it against sibling tools by name ('use gograph_callers', 'use gograph_deps'). An agent can select it correctly without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit WHEN TO USE and NOT TO USE sections that name the two most confusable alternatives and the exact condition that routes to each (upstream callers vs. package dependency trees). This is the strongest possible guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.