trace_path
Trace callers, callees, data flow, or cross-service paths through a code graph to analyze dependencies and impact.
Instructions
Trace paths through the code graph. Modes: calls (callers/callees), data_flow (value propagation with args at each hop), cross_service (through HTTP/async Route nodes). Use INSTEAD OF grep for callers, dependencies, impact analysis, or data flow tracing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| function_name | Yes | ||
| project | Yes | ||
| direction | No | both | |
| depth | No | ||
| mode | No | calls: follow CALLS edges. data_flow: follow CALLS+DATA_FLOWS with arg expressions. cross_service: follow HTTP_CALLS+ASYNC_CALLS+DATA_FLOWS through Routes. | calls |
| parameter_name | No | For data_flow mode: scope trace to a specific parameter name | |
| edge_types | No | ||
| risk_labels | No | Add risk classification (CRITICAL/HIGH/MEDIUM/LOW) based on hop distance | |
| include_tests | No | Include test files in results. When false (default), test files are filtered out. When true, test nodes are included with is_test=true marker. |