Skip to main content
Glama

review_sonar

Read-onlyIdempotent

Inspect PRs/MRs with Sonar quality gates, coverage, duplication, issues, and hotspots, then explain failures and guide code fixes using local editing and testing tools.

Instructions

Inspect a PR/MR and its Sonar quality gate, coverage, duplication, issues and hotspots together. The assistant explains failures and, when asked, fixes code using its local editing/testing tools. Supply ruleKey for remediation details or filePath for source context. This tool reads evidence; a new Sonar analysis is needed to confirm a fix.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageNo
targetYes
projectNoSonar project key; defaults to configuration
ruleKeyNo
filePathNoOptional repository-relative file to inspect at the PR head

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

B3.4/5.0
Behavior4/5

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

Annotations already signal read-only, non-destructive, idempotent behavior, so the bar is lower. The description adds useful context beyond annotations—namely that fix suggestions use local editing/testing tools and that confirming fixes requires a fresh analysis—clarifying the write-via-tool chain despite readOnlyHint on this tool itself.

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?

Three compact sentences front-load the core purpose, then layer in the fix behavior and parameter hints. Every sentence carries information, though the parameter sentence is somewhat telegraphic.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a five-parameter, nested-target, no-output-schema tool, the description is decent on purpose and behavior but thin on parameter semantics—especially target and project defaults. An agent can call it, but may need to inspect the schema for target structure and pagination.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 40%, so the description must compensate but barely does. It explains ruleKey (remediation details) and filePath (source context), yet ignores target, project, and page entirely, leaving three of five parameters without descriptive support in either field.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description uses a clear verb ('Inspect') plus specific resources (PR/MR, Sonar quality gate, coverage, duplication, issues, hotspots) that pinpoint the tool's scope. It distinguishes from generic review tools by naming the exact artifacts it aggregates, though it doesn't explicitly differentiate from sibling review_work.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description says 'when asked, fixes code' and explains that 'a new Sonar analysis is needed to confirm a fix,' which implies post-fix behavior. But it never states when to choose review_sonar over review_work or plan_ticket_tasks, leaving the agent to guess based on resource type.

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

Deploy Server

Other Tools