Skip to main content
Glama

gograph_api

Read-onlyIdempotent

Compare exported Go symbols against a baseline Git ref or saved graph to detect public API drift, revealing added, removed, or renamed exports before release.

Instructions

Detect public API surface drift by comparing exported Go symbols between the current working tree and a baseline. A since value ending in .json loads a regular saved graph inside the project root with no linked path component and the exact current repository source-policy marker; its serialized root is ignored. Otherwise gograph validates the value as a Git ref and uses git archive to build a temporary baseline. The MCP server checks freshness before this call and refreshes in the current requested analysis mode; precise and precise_fallback graphs retry CHA/SSA after source changes. Read-only apart from reading the selected graph or extracting a temporary archive that is removed after the call. WHEN TO USE: Before releasing or merging a PR to catch breaking-change regressions — exported symbols added, removed, or renamed since the baseline. NOT TO USE: For listing current exports without a diff baseline (use gograph_public or gograph_skeleton instead). RETURNS: JSON with baseline and breaking flags; nested exported_symbols, interfaces, structs, and routes groups containing added/removed arrays plus changed detail objects; affected_tests, affected_mocks, and findings arrays. Empty groups indicate no drift.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sinceYesA baseline Git ref (for example 'main' or 'HEAD~1') or regular in-project saved graph path ending in .json, with no linked component and the exact current source-policy marker
Behavior5/5

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

Even with annotations declaring readOnly, idempotent, and non-destructive, the description adds critical behavioral details: it extracts a temporary archive removed after the call, checks freshness, refreshes in the current analysis mode, and retries CHA/SSA for precise graphs. These details go far beyond the annotations and clarify the tool's runtime behavior.

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 structured with clear sections (intro, parameter behavior, safety, WHEN/NOT TO USE, RETURNS). Every sentence carries specific information, and the most important facts are front-loaded. It's longer than most but each sentence earns its place, making it efficient and scannable.

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?

With one parameter, no output schema, but supported by rich annotations, the description covers all necessary aspects: input semantics, execution behavior (including failure modes and side effects), return structure, and intended use cases. It leaves no significant gaps for an agent to invoke the tool correctly.

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?

The schema covers 100% of the single parameter 'since', but the description enriches it with significant semantics: it explains the two accepted value types (Git ref vs .json saved graph), special handling for .json paths, and the meaning of 'regular saved graph' with source-policy marker. This adds value beyond the schema's basic description.

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 opens with a precise verb+resource statement: 'Detect public API surface drift by comparing exported Go symbols between the current working tree and a baseline.' It clearly distinguishes itself from sibling tools like gograph_public and gograph_skeleton by explicitly stating it's for diffing against a baseline, not listing current exports.

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?

WHEN TO USE and NOT TO USE sections are explicit and actionable. It says use before releasing or merging a PR to catch breaking changes, and directs users to gograph_public or gograph_skeleton for listing current exports without a baseline. This is the gold standard for usage 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/ozgurcd/gograph'

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