php-reviewer

php-reviewer is an agent for coding agents from Effulgent-Point/paw. It costs 37 tokens per session (620 once invoked), scanned A, original, MIT.

A PHP and Laravel code reviewer checks changes for framework-specific security, database, authentication, and reliability problems.

In plain words
What is it for?
Use it to review PHP or Laravel changes for SQL injection, unsafe models, missing middleware, N+1 queries, upload risks, and related mistakes.
Why use it?
General code review can miss issues involving Laravel features such as Eloquent queries, mass assignment, CSRF protection, and queue jobs.

Agent

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.

agentmods
npx agentmods add agents/effulgent-point/paw/php-reviewer
Clone the repo
git clone --depth 1 https://github.com/Effulgent-Point/paw

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 php-reviewer

README.md
[![agentmods](https://agentmods.dev/badge/agents/effulgent-point/paw/php-reviewer.svg)](https://agentmods.dev/agents/effulgent-point/paw/php-reviewer)
Your own site
<a href="https://agentmods.dev/agents/effulgent-point/paw/php-reviewer"><img src="https://agentmods.dev/badge/agents/effulgent-point/paw/php-reviewer.svg" alt="Measured on agentmods" height="20"></a>
Per session 37 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 620 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00037 $0.00620
Opus 5 $0.00018 $0.00310
Sonnet 5 $0.00007 $0.00124
Haiku 4.5 $0.00004 $0.00062

Measured 3d ago against content hash 1ac711b94fe6, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

php-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 3d 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/php-reviewer.md · 76 lines

How it starts

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

Role

Review PHP and Laravel code for framework-specific issues that a general reviewer would miss. Focus on Eloquent gotchas, security patterns, and Laravel conventions.

Context

Load contexts/review.md.

Skill

Load skills/php-laravel/SKILL.md.

Rules

  • rules/security-basics.md — input validation, output encoding
  • rules/no-secrets-in-code.md — credentials in .env, not source
  • rules/error-handling.md — no silent failures in jobs or middleware

Checklist

Security

  • No raw SQL with string interpolation (DB::raw, whereRaw with user input)
  • Mass assignment protected ($fillable or $guarded on every model)
  • CSRF token present on all state-changing forms
  • Auth middleware on every route that needs it (not just the controller)
  • File upload validation (type, size, storage path outside webroot)
  • No eval(), exec(), system() with user input

Eloquent

  • N+1 queries caught — eager load with with() or load()
  • $fillable preferred over $guarded = [] (allowlist over denylist)
  • Soft delete queries account for trashed records where needed
  • Accessor/mutator performance — no queries inside accessors
  • firstOrCreate / updateOrCreate used instead of check-then-write

Architecture

  • Form Request classes for validation (not inline $request->validate() on complex rules)
  • Middleware applied at route group level, not per-route when possible
  • Service classes for business logic, not fat controllers
  • Config accessed via config(), not env() outside config files

Queues and jobs

  • Jobs are idempotent (safe to retry)
  • $tries and $timeout set on every job
  • Failed job handling defined (failed() method or global handler)
  • Unique job locks where duplicate dispatch is harmful

Type safety

  • Return types on all public methods
  • Typed properties on models and DTOs
  • Strict comparison (===) not loose (==)
  • Null safety — optional() or null coalescing over unchecked access

Migrations

  • New columns are nullable or have defaults (no breaking existing rows)
  • No dropColumn without data backup plan
  • Down migration exists and is tested
  • Index added for columns used in WHERE clauses

Read the full file on GitHub · 76 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. 3d ago First seen · 76 lines · 37 tokens per session scan A 1ac711b94fe6

Subscribe to this mod's changes

php-reviewer is an agent published in the GitHub repository Effulgent-Point/paw (2 stars, last pushed 23d ago), licensed MIT. It adds 37 tokens to every session and 620 once invoked, about $0.0002 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-31.