Skip to main content
Glama

get_call_chain

Trace the sequential call graph between two functions to see how one reaches the other, with configurable maximum depth for focused results.

Instructions

Trace sequential call graph between start and end functions.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "startFunction": "<startFunction>",
      "endFunction": "<endFunction>"
    },
    "name": "get_call_chain"
  }
}

Input Schema

NameRequiredDescriptionDefault
maxDepthNoMax depth (1-10, default: 5).
endFunctionYesDestination function name.
startFunctionYesOriginating function name.
workspacePathNoOptional workspace root path.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.80.5

TDQS

C2.8/5.0
Behavior2/5

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

No annotations exist, so the description carries the full behavioral burden and leaves most of it unaddressed. It does not say whether a single path or all paths are returned, what happens when no path exists, whether the result is read-only/non-mutating, or what maxDepth truncation means for the answer. The word "trace" hints at a read operation but nothing is stated explicitly.

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

Conciseness4/5

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

A single front-loaded sentence with no filler or redundancy. It is efficient but borders on under-specification, since nothing follows the core statement to expand on behavior or results.

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

Completeness1/5

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

Placeholder for a 1 score per instructions: with no annotations, no output schema, and four parameters, the description is far too thin to tell an agent what a successful trace yields or how it fails. Knowing the return shape matters here because there is no output schema to fall back on.

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

Parameters3/5

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

Schema description coverage is 100%, so startFunction, endFunction, maxDepth, and workspacePath are already documented in the schema; a baseline of 3 applies. The description's "between start and end functions" reinforces the direction of the required pair but adds no format, resolution, or workspace-scoping detail beyond the schema.

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

Purpose4/5

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

"Trace sequential call graph between start and end functions" gives a specific verb (trace), resource (call graph), and scope (a path bounded by two named functions). It is clear on its own, but it never contrasts itself with near-neighbors such as get_callers or trace_cross_service_flow, so differentiation relies on the reader inferring from the names.

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

Usage Guidelines2/5

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

There is no guidance on when to reach for this tool versus get_callers, resolve_call_target, or trace_cross_service_flow, and no stated preconditions (indexed workspace, resolvable symbols). The agent must guess the selection rule from the tool name alone.

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