Skip to main content
Glama
reflex-search

Reflex

Official

get_dependencies

Retrieve all static imports of a file, showing dependency path, line number, type (internal/external/stdlib), and imported symbols.

Instructions

Get all dependencies (imports) of a specific file.

Purpose: Analyze what modules/files a given file imports.

Returns: Array of dependency objects with import path, line number, type (internal/external/stdlib), and optional symbols.

Use this when:

  • Understanding file dependencies

  • Analyzing import structure

  • Finding what a file depends on

IMPORTANT: Only extracts static imports (string literals). Dynamic imports (variables, template literals, expressions) are automatically filtered by tree-sitter query design. See CLAUDE.md section "Dependency/Import Extraction" for details.

Note: Path matching is fuzzy - supports exact paths, fragments, or just filenames.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesFile path (supports fuzzy matching: 'Controllers/FooController.php' or just 'FooController.php')
Behavior4/5

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

Without annotations, the description carries the full behavioral transparency burden. It discloses that only static imports (string literals) are extracted and that dynamic imports are automatically filtered, and notes fuzzy path matching. It also references CLAUDE.md for further details. This provides important context beyond the tool's basic function.

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?

The description is well-structured with sections for purpose, returns, usage, important notes, and a note. It is concise at around 100 words and front-loaded with the main action. Slightly more streamlining could achieve a perfect score.

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

Completeness4/5

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

Given the single parameter and no output schema, the description provides a good overview including return type (array of dependency objects with fields) and limitations (static only). It lacks error handling or edge case details but is otherwise complete for its complexity.

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?

The schema provides 100% coverage with a clear description of the 'path' parameter, including fuzzy matching examples. The description adds a note about path matching being fuzzy, but the schema already covers this well. Baseline 3 is appropriate as the description does not significantly add new meaning.

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?

The description clearly states the tool's purpose: 'Get all dependencies (imports) of a specific file.' It uses a specific verb 'Get' and resource 'dependencies (imports)' and distinguishes from siblings like 'get_dependents' and 'get_transitive_deps' by focusing on imports of a specific file.

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

Usage Guidelines4/5

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

The description includes a 'Use this when' section with clear scenarios: understanding file dependencies, analyzing import structure, and finding what a file depends on. However, it does not explicitly mention when not to use it or compare with sibling tools, which could improve guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/reflex-search/reflex'

If you have feedback or need assistance with the MCP directory API, please join our Discord server