Skip to main content
Glama
dorkian

code-graph-mcp

by dorkian

Find component relations

find_component_relations

Retrieve all child/parent components, hooks, stores, endpoints, and file imports for a given component or route name to avoid manual grepping.

Instructions

Given a component or route name, return everything related: child components it renders, parents that render it, hooks/stores used, endpoints it calls, and file import relationships. Use instead of grepping for usages.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYescomponent or route name, e.g. LoginPage or /login
detailNocompact (default) = terse line output; full = expanded lists
max_tokensNoresponse token budget (default 2000)
Behavior3/5

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

No annotations are provided, so the description carries full responsibility for behavioral disclosure. It lists what the tool returns but does not mention non-destructive behavior, error handling, or any side effects. The description implies a read-only operation but does not confirm auth needs or rate limits.

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?

The description is two sentences with no fluff. The first sentence front-loads the purpose and expected output. The second sentence provides a usage guideline. Every sentence earns its place.

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 complexity (3 params, no output schema), the description provides a comprehensive list of relationship types. However, it does not describe the return format (e.g., JSON structure) or how results are structured. With no output schema, a more detailed explanation of the output would improve completeness.

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 coverage is 100%, so baseline is 3. The description adds value for the 'name' parameter by explaining it includes component or route names with examples. For 'detail' and 'max_tokens', it adds little beyond the schema; 'max_tokens' simply says 'response token budget' which is already in the schema.

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: given a component or route name, return related elements. It uses specific verbs like 'return' and lists concrete outputs (children, parents, hooks/stores, endpoints, imports). It also distinguishes itself from the common alternative 'grepping for usages'.

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 gives clear guidance on when to use: when you need to find relations of a component or route. It also explicitly suggests using this tool instead of grepping. However, it does not compare to sibling tools like 'search_symbols' or 'impact_of_change', nor does it state when not to use it.

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/dorkian/code-graph-mcp'

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