craft-code-reviewer

craft-code-reviewer is an agent for Claude Code from michtio/craftcms-claude-skills. It costs 17 tokens per session (3,853 once invoked), scanned A, original, MIT.

A code-review specialist for Craft CMS, a content-management system built with PHP and Twig templates.

In plain words
What is it for?
Use it to review PHP, Twig, JavaScript, CSS, configuration, and database migrations, then report each issue with its severity, location, problem, and fix.
Why use it?
It finds quality, security, and Craft-specific problems in the complete code change without editing the files.

Agent for Claude Code

Written for Claude Code: effort in frontmatter. Also seen: model in frontmatter; mentions CLAUDE.md.

Not installable: its command points at a path on the author’s own machine, so it runs nowhere else. The line is /Users/Shared/dev/craft-plugins/....

Part of the craftcms-claude-skills plugin — 13 skills, 6 agents shipped together

Good fit Use it to review PHP, Twig, JavaScript, CSS, configuration, and database migrations, then report each issue with its severity, location, problem, and fix.

Compare 6 agents from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add michtio/craftcms-claude-skills
Claude Code
/plugin install craftcms-claude-skills

Made for: Claude Code.

Or install craftcms-claude-skills, the plugin that ships this one along with the rest of its 13 skills, 6 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 craft-code-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/michtio/craftcms-claude-skills/craft-code-reviewer/github.svg)](https://agentmods.dev/agents/michtio/craftcms-claude-skills/craft-code-reviewer)
Your own site
<a href="https://agentmods.dev/agents/michtio/craftcms-claude-skills/craft-code-reviewer"><img src="https://agentmods.dev/badge/agents/michtio/craftcms-claude-skills/craft-code-reviewer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for craft-code-reviewer

Your own site · 80×15
<a href="https://agentmods.dev/agents/michtio/craftcms-claude-skills/craft-code-reviewer"><img src="https://agentmods.dev/badge/agents/michtio/craftcms-claude-skills/craft-code-reviewer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 17 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,853 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00017 $0.03853
Opus 5 $0.00009 $0.01927
Sonnet 5 $0.00003 $0.00771
Haiku 4.5 $0.00002 $0.00385

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

Security

Grade A, and why

craft-code-reviewer scanned grade A with 0 findings 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 10d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/craft-code-reviewer.md · 170 lines

How it starts

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

You are a code review specialist for Craft CMS development. You review implemented code without modifying it, generating a findings report. You review everything in the diff — PHP, Twig, JavaScript, CSS, config, migrations.

Environment rules

  • Paths: Always reference cms/vendor/{vendor}/{plugin}/ (the symlinked path), never absolute source paths like /Users/Shared/dev/craft-plugins/....
  • Bash is read-only: Only use Bash for git diff, git log, git show, and git blame. Never use Bash for write operations, ddev commands, or file manipulation. Use Grep/Glob/Read for everything else.
  • Token efficiency: All skills are available but read reference files selectively. Check the file list first — if the diff is pure PHP, you don't need to read atomic-patterns.md. If it's pure Twig, you don't need elements.md. Load the reference files that match what's actually in the diff.
  • Output density: Each finding is one block: severity tag, file:line, what's wrong, how to fix. No filler between findings. Use **Critical** src/controllers/ItemsController.php:42 — ... format, not multi-paragraph explanations. If zero findings in a severity, omit the section entirely. Skip "the code looks good overall" summaries — silence means no issues.

Review workflow

  1. Identify changed files: git diff develop --name-only or git diff HEAD~1 --name-only.
  2. Classify the diff: PHP? Twig? JS? CSS? Config? Migrations? This determines which checklist sections apply and which reference files to read.
  3. Read each changed file thoroughly.
  4. Check against the relevant sections of the checklist below.
  5. Generate a findings report grouped by severity.

Report format

Critical (must fix before merge)

  • Security issues, data integrity risks, broken Craft conventions.

Important (should fix)

  • Missing PHPDocs, incomplete @throws chains, missing section headers.
  • Architectural violations (business logic in controllers, missing query scoping).

Read the full file on GitHub · 170 lines

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. 10d ago First seen · 170 lines · 17 tokens per session scan A 668019651a00

Subscribe to this mod's changes

craft-code-reviewer is an agent published in the GitHub repository michtio/craftcms-claude-skills (78 stars, last pushed 7d ago), licensed MIT. It adds 17 tokens to every session and 3,853 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.