laravel

laravel is a skill for Claude Code, Codex from SumonMSelim/agentguard. It costs 36 tokens per session (1,378 once invoked), scanned A, original, MIT.

A guide to writing and reviewing Laravel 13 applications. Laravel is a PHP framework for building web applications, with features for routing, databases, validation, background jobs, and testing.

In plain words
What is it for?
Use it when building or reviewing Laravel controllers, models, validation, services, queues, security, database queries, and tests.
Why use it?
It helps keep application logic organized and reduces problems such as unsafe data handling, slow database queries, and hard-to-test controllers.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when building or reviewing Laravel controllers, models, validation, services, queues, security, database queries, and tests.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sumonmselim/agentguard/laravel
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 SumonMSelim/agentguard --skill laravel
Clone the repo
git clone --depth 1 https://github.com/SumonMSelim/agentguard

Made for: Claude Code, Codex.

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 laravel

README.md
[![agentmods](https://agentmods.dev/badge/skills/sumonmselim/agentguard/laravel/github.svg)](https://agentmods.dev/skills/sumonmselim/agentguard/laravel)
Your own site
<a href="https://agentmods.dev/skills/sumonmselim/agentguard/laravel"><img src="https://agentmods.dev/badge/skills/sumonmselim/agentguard/laravel/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 laravel

Your own site · 80×15
<a href="https://agentmods.dev/skills/sumonmselim/agentguard/laravel"><img src="https://agentmods.dev/badge/skills/sumonmselim/agentguard/laravel.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,378 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.00036 $0.01378
Opus 5 $0.00018 $0.00689
Sonnet 5 $0.00007 $0.00276
Haiku 4.5 $0.00004 $0.00138

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

Security

Grade A, and why

laravel 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 9d 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.

skills/laravel/SKILL.md · 94 lines

How it starts

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

Laravel

Architecture

  • Thin controllers: validate input, call service or action, return response. No business logic in controllers
  • Form Requests for validation and authorisation. Never validate in controller body
  • Service classes or Actions for domain logic. One responsibility each
  • Repositories only when swapping data sources is a real requirement
  • No logic in routes or middleware beyond stated purpose
  • Strict mode in AppServiceProvider: Model::shouldBeStrict() in non-production, Model::preventLazyLoading() in all envs

PHP Attributes (Laravel 13+)

  • PHP Attributes are optional but preferred for co-locating config with classes
  • Models: #[Fillable], #[Guarded], #[Hidden] replace $fillable, $guarded, $hidden properties
  • Controllers: #[Middleware], #[Authorize] replace $this->middleware() in constructor
  • Jobs: #[Tries], #[Backoff], #[Timeout], #[FailOnTimeout] replace class properties
  • Adopt Attributes on new code. No need to migrate existing property-based code — not deprecated

Eloquent

  • Eager-load all relationships with with(). Enable Model::preventLazyLoading() to catch N+1 in dev
  • Scope complex query logic into named scopes on the model
  • firstOrFail() / findOrFail() — never manually null-check query results
  • Mass assignment: #[Fillable] or explicit $fillable. Never $guarded = [] in production
  • Observers and model events for cross-cutting concerns only. No core logic inside them
  • DB::transaction(fn() => ...) for all multi-step writes
  • UUID or ULID primary keys for distributed systems: HasUuids / HasUlids traits
  • Always add indexes for foreign keys, frequently filtered columns, and unique constraints in migrations

Security

  • Sanctum for SPA/mobile API auth. Passport for OAuth server. Never hand-rolled token auth
  • Passkey auth available via Laravel 13 first-party support — prefer for new user-facing apps
  • Authorise with Policies or Gates. Never inline ownership checks
  • CSRF on by default — never disable
  • Validate all input with Form Requests. Use sometimes and nullable intentionally
  • Secrets in secret manager (AWS Secrets Manager, Vault). Never in .env committed to repo
  • Encrypt sensitive data at rest via Crypt facade
  • Rate-limit sensitive routes (login, register, password reset) with throttle middleware
  • Never DB::statement() with user input. Use query builder or Eloquent
  • Sanctum tokens: set expiry. Revoke on logout. Store hashed in DB (default behaviour — don't bypass)

Read the full file on GitHub · 94 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. 9d ago First seen · 94 lines · 0 tokens per session scan A 01ec6a8a884d

Subscribe to this mod's changes

laravel is a skill published in the GitHub repository SumonMSelim/agentguard (56 stars, last pushed 1mo ago), licensed MIT. It adds 36 tokens to every session and 1,378 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-30.

Related

Other skills, from other repositories

php-pro

A set of practices for building PHP applications with modern PHP, Laravel, or Symfony. PHP is a programming language commonly used for server-side web applications.

sutchan/Agent-Skills-Hub · 120 tokens

laravel-specialist

Build and configure Laravel 10+ applications, including creating Eloquent models and relationships, implementing Sanctum authentication, configuring Horizon queues, designing RESTful APIs with API resources, and building reactive interfaces with Livewire. Use when creating Laravel models, setting up queue workers…

Jeffallan/claude-skills · 86 tokens

create-powergrid-plugin

Create a complete PowerGrid plugin from scratch, including PHP class, Column macro, Blade view, Alpine.js component, and registration.

Power-Components/livewire-powergrid · 31 tokens

owl-admin-devtools-generator

A development guide for Owl Admin, a Laravel-based administration system, covering its code generator, API templates, relationships, and visual pages.

slowlyo/owl-admin · 82 tokens

llamaindex-development

Expert guidance for LlamaIndex development including RAG applications, vector stores, document processing, query engines, and building production AI applications.

Mindrally/skills · 32 tokens

craftcms

Craft CMS 5 plugin and module development — extending Craft with PHP. Covers elements, element queries, services, models, records, controllers, migrations, queue jobs, console commands, field types, native fields, events, behaviors, Twig extensions, widgets, filesystems, permissions, project config, GraphQL, testing…

michtio/craftcms-claude-skills · 327 tokens