sonar-review

sonar-review is a skill for Claude Code from sananthanarayan/skilldrop. It costs 217 tokens per session (4,034 once invoked), scanned A, original, MIT.

A code-review skill that scans recently changed files with Sonar, a code-quality analysis tool, and produces a structured report with a quality-gate result and severity levels.

In plain words
What is it for?
Use it before merging changes to check changed files for Sonar findings, including bugs, security concerns, and maintainability problems.
Why use it?
It turns scanner output into an actionable pre-merge review, showing which changed lines have reported issues and which Sonar rules apply.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the skilldrop plugin — 51 skills, 4 agents shipped together

Good fit Use it before merging changes to check changed files for Sonar findings, including bugs, security concerns, and maintainability problems.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sananthanarayan/skilldrop/sonar-review
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add sananthanarayan/skilldrop --skill sonar-review
Clone the repo
git clone --depth 1 https://github.com/sananthanarayan/skilldrop

Made for: Claude Code.

Or install skilldrop, the plugin that ships this one along with the rest of its 51 skills, 4 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for sonar-review

README.md
[![agentmods](https://agentmods.dev/badge/skills/sananthanarayan/skilldrop/sonar-review.svg)](https://agentmods.dev/skills/sananthanarayan/skilldrop/sonar-review)
Your own site
<a href="https://agentmods.dev/skills/sananthanarayan/skilldrop/sonar-review"><img src="https://agentmods.dev/badge/skills/sananthanarayan/skilldrop/sonar-review.svg" alt="Measured on agentmods" height="20"></a>
Per session 217 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,034 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00217 $0.04034
Opus 5 $0.00109 $0.02017
Sonnet 5 $0.00043 $0.00807
Haiku 4.5 $0.00022 $0.00403

Measured 8d ago against content hash d67d0cbca6a3, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

sonar-review scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s -u "$SONAR_TOKEN:" \
skills/sonar-review/SKILL.md · 221 lines

How it starts

The opening of the file, as written. The whole thing — 221 lines — stays where its author put it; the contents beside it link to each section on GitHub.

sonar-review

You run a Sonar scan against the user's just-changed code and produce a structured pre-merge compliance report. The artifact is a markdown review the user acts on — not raw scanner output, not a quiet "scan complete".

This skill is the Sonar-flavored counterpart to devils-advocate: same shape (severity-tagged findings, file:line evidence, concrete fixes, verdict on top), but the rules come from Sonar's catalog and the verdict comes from the project's quality gate, not your judgment.

Works against both deployment modes — the mode is detected from sonar-project.properties, not asked:

Mode Detection Host Token env
SonarQube server No sonar.organization line $SONAR_HOST_URL (set by user) $SONAR_TOKEN
SonarCloud sonar.organization=<key> present https://sonarcloud.io (fixed) $SONAR_TOKEN

The API endpoints are identical between the two — only the host differs. If the user is jumping in cold and the repo isn't wired up, run sonar-onboard first.

How to respond

  1. Detect the mode. First thing — read sonar-project.properties and check for a sonar.organization= line:

    • Present ⇒ SonarCloud. Host is https://sonarcloud.io (don't read $SONAR_HOST_URL).
    • Absent ⇒ SonarQube server. Host comes from $SONAR_HOST_URL.

    Use the detected mode for every subsequent step. Don't ask the user — the properties file is the source of truth.

  2. Verify the environment before scanning. Checks differ by mode:

    Check Applies to If missing
    sonar-project.properties at repo root both Stop. Tell the user to run sonar-onboard first — there's no project config to scan against.
    sonar-scanner on PATH both Stop. Print the install hint (see step 3). Do not attempt to install it.
    SONAR_TOKEN env var set both Stop. Tell the user to export it from their Sonar account → Security → Tokens.
    SONAR_HOST_URL env var set server only Stop. Tell the user to export it (e.g. export SONAR_HOST_URL=https://sonar.company.com).

Read the full file on GitHub · 221 lines

Files

What ships with it

10 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 221 lines · 217 tokens per session scan A d67d0cbca6a3

Subscribe to this mod's changes

sonar-review is a skill published in the GitHub repository sananthanarayan/skilldrop (2 stars, last pushed 24d ago), licensed MIT. It adds 217 tokens to every session and 4,034 once invoked, about $0.0011 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

continual-learning

Nightly refinement of an existing per-repo review-style prompt using this reviewer's own finding outcomes. Read confirmed (resolved-by-commit / thumbs-up) and dismissed (thumbs-down) findings, promote the bug patterns the team actually fixes, demote the false-positive patterns, reconcile against the current prompt…

langchain-ai/open-swe · 89 tokens

security-review

Perform a focused security review of pending git changes to identify high-confidence security vulnerabilities with real exploitation potential. Use this skill when the user asks for a security review, security audit, vulnerability scan, or wants to check pending changes on a branch for security issues before merging.…

waybarrios/opencode-power-pack · 64 tokens

review-work

Post-implementation gate review: run manual QA on the real surface yourself, then launch ONE gate reviewer (never a panel) to audit goal, constraints, code quality, security, missed context, and QA evidence. Use before a PR handoff or when the user explicitly asks to review completed work.

code-yeongyu/oh-my-openagent · 63 tokens

huggingface-llm-trainer

Train or fine-tune language models with TRL or Unsloth on Hugging Face Jobs, including SFT, DPO, GRPO, reward models, and GGUF conversion. Use for cloud LLM training; use huggingface-vision-trainer for vision tasks.

waybarrios/opencode-power-pack · 65 tokens

feature-dev

Guide a feature implementation through a structured seven-phase workflow with deep codebase understanding, clarifying questions, parallel architecture design, and quality review. Use this skill when the user asks to build a new feature, add functionality, or wants a methodical approach to implementation rather than…

waybarrios/opencode-power-pack · 62 tokens

review

Review local code changes for bugs, regressions, missing tests, and pragmatic improvements. Use when the user asks to review the current changes from git status, or to review a specific backlog task by id such as task-65 or TASK-65. Also trigger when the user says things like "review", "review current changes", "check…

devoxx/DevoxxGenieIDEAPlugin · 90 tokens