Skip to main content
Glama

Grade MCP tool definitions for agent-readiness

grade_tools
Read-onlyIdempotent

Grade MCP tool definitions (the tools array from a tools/list result) for how well AI agents can pick and call them. Returns a 0–100 score and A–F grade, per-tool scores, and findings with concrete fixes: missing or weak descriptions, untyped parameters, strings without maxLength, missing required or additionalProperties, missing annotations (readOnlyHint, destructiveHint …), invalid or duplicate names, outputSchema and enum problems, hidden characters and tool-poisoning patterns. Also returns an ESTIMATED token cost of the definitions (characters ÷ 4; real counts vary by model). Pure parsing: no network calls, and your tool definitions are never stored. Read-only. Same engine as the ToolGrade JSON API (POST /api/grade).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toolsNoThe tool definitions to grade, e.g. [{"name": "search_docs", "description": "...", "inputSchema": {...}}]: the "tools" array of a tools/list result. Up to 200 tools. Provide this or tools_json.
tools_jsonNoAlternative to tools: raw JSON text of a tools/list response, its result object ({"tools": [...]}) or a tool array, exactly as copied.
include_rawNoAlso return the full /api/grade report (all findings and every tool row) in structuredContent.raw. Larger output.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rawNoFull /api/grade response (only when include_raw is true)
infoNo
gradeYes
scoreYes
toolsYes
versionYes
warningNo
criticalNo
findingsYes
tokenNoteNo
toolCountYes
toolsOmittedNo
verdictMeaningNo
estimatedTokensYesESTIMATED total token cost of all definitions (compact JSON chars ÷ 4).
findingsOmittedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive/openWorld=false, and the description still adds real value beyond them: 'Pure parsing: no network calls, and your tool definitions are never stored' is a substantive privacy/execution guarantee, and it discloses that token cost is an estimate (characters ÷ 4) rather than a measured value. That is exactly the extra behavioral context annotations cannot carry.

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?

Front-loaded with the core action and result shape, then a long but purposeful enumeration of finding categories. The list of checks is dense and arguably padded, but each item is distinct and informative; the closing notes on estimation, pure parsing, and the API mapping all earn their place.

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?

An output schema exists, yet the description still summarizes the return payload (score, grade, per-tool rows, findings, token estimate) and the include_raw expansion path, so an agent can decide whether to set include_raw. Input sources, limits, and side effects are all covered; nothing needed to call it correctly is missing.

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 description coverage is 100%, so the schema already documents all three parameters, including the tools_json maxLength and the include_raw tradeoff. The description adds only the 'characters ÷ 4' estimate caveat, which is behavioral rather than parameter semantics. Baseline 3 applies when the schema does the heavy lifting.

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?

States a specific verb+resource ('Grade MCP tool definitions') and immediately scopes it ('the tools array from a tools/list result') with the evaluation criterion spelled out ('how well AI agents can pick and call them'). It also names the exact output artifacts (0–100 score, A–F grade, per-tool scores, findings), so an agent knows precisely what this does.

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?

Gives clear input-selection guidance via the mutually exclusive 'Provide this or tools_json' framing, and clarifies the relationship to the sibling-style API ('Same engine as the ToolGrade JSON API'). It does not state when NOT to use it, but with no sibling tools in scope the routing burden is low.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources