PulseAugur
EN
LIVE 05:31:49

Developer finds GitHub API sort order mismatch in tool documentation

A developer discovered a subtle bug in their tool's documentation where the promised GitHub API sorting options did not align with the actual API's capabilities. The tool's docstring claimed support for sorting by 'stars' and 'forks', but the GitHub REST API endpoint used only accepted 'created', 'updated', 'pushed', and 'full_name' for user repositories. This discrepancy led to the API silently ignoring the invalid sort parameters and defaulting to its own order, creating a misleading success state for the tool. The developer fixed this by implementing client-side sorting for 'stars' and 'forks' after fetching the data, ensuring the tool's behavior now matches its documentation. AI

IMPACT Highlights the importance of accurate documentation and API contract adherence for AI agent tools.

RANK_REASON Article details a bug fix in a specific developer tool related to API interaction and documentation.

Read on dev.to — MCP tag →

AI-generated summary · Google Gemini · from 1 sources. How we write summaries →

Developer finds GitHub API sort order mismatch in tool documentation

COVERAGE [1]

  1. dev.to — MCP tag TIER_1 English(EN) · Enjoy Kumawat ·

    My MCP Tool's Docstring Promised sort="stars". GitHub's API Was Never Going to Honor That Value.

    <p>Every tool in my <code>developer-presence</code> MCP server has a one-line docstring, because that's the only documentation an agent calling the tool ever sees — no README, no OpenAPI spec, just whatever string sits under the <code>@mcp.tool()</code> decorator. I've already fo…