Skip to main content
Glama

gograph_imports

Read-onlyIdempotent

Find all files and packages that import a given internal or third-party package. Trace package dependency relationships across a Go codebase.

Instructions

Find all files and packages that import a specific internal or third-party package. BEHAVIOR & SAFETY: This is a 100% local, read-only static analysis tool. It has no side effects, requires no authorization or credentials, has no rate limits, and performs zero destructive modifications. USAGE GUIDELINES: Call this tool when mapping package dependency relationships, isolating features, or tracing where third-party libraries are used. Do NOT use if you need a package's own imports (use gograph_deps instead). COMPLETENESS: Requires 'package' parameter. Returns a complete array of file paths and importing packages referencing the target import path. Example package: 'golang.org/x/tools'.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
packageYesThe exact import path of the target package to trace imports for (e.g., 'github.com/redis/go-redis')
Behavior5/5

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

Annotations already declare readOnly, idempotent, not destructive. Description adds context: '100% local, read-only static analysis tool, no side effects, no auth, no rate limits, zero destructive modifications' – no contradiction and provides extra reassurance.

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?

Approximately 5 sentences with clear section headings. No filler. Front-loaded with purpose.

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?

Simple tool with 1 param, rich annotations, and description covers behavior, usage, return type ('complete array of file paths and importing packages'). No missing critical information.

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?

Single parameter 'package' has schema description and tool description repeats it's required and gives example. Schema coverage 100%, so baseline 3. Description adds extra example ('golang.org/x/tools') and states requirement, adding marginal value.

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?

Description states clear action 'Find all files and packages that import a specific package' with specific scope. It distinguishes from sibling gograph_deps which returns a package's own imports.

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?

Explicitly states when to call (mapping dependencies, tracing libraries) and when not to ('Do NOT use if you need a package's own imports'), providing alternative tool name.

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/ozgurcd/gograph'

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