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.
npx skills add jpcaparas/superpowers-laravel --skill constants-and-configurationgit clone --depth 1 https://github.com/jpcaparas/superpowers-laravelWrote 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.
[](https://agentmods.dev/skills/jpcaparas/superpowers-laravel/constants-and-configuration)<a href="https://agentmods.dev/skills/jpcaparas/superpowers-laravel/constants-and-configuration"><img src="https://agentmods.dev/badge/skills/jpcaparas/superpowers-laravel/constants-and-configuration/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.
<a href="https://agentmods.dev/skills/jpcaparas/superpowers-laravel/constants-and-configuration"><img src="https://agentmods.dev/badge/skills/jpcaparas/superpowers-laravel/constants-and-configuration.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00034 | $0.03751 |
| Opus 5 | $0.00017 | $0.01876 |
| Sonnet 5 | $0.00007 | $0.00750 |
| Haiku 4.5 | $0.00003 | $0.00375 |
Grade A, and why
laravel:constants-and-configuration 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 11d 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.
How it starts
The opening of the file, as written. The whole thing — 605 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Constants and Configuration Values
Avoid hardcoded values throughout your codebase. Use constants, configuration files, and enums to make your application more maintainable, refactorable, and debuggable.
The Problem with Hardcoded Values
// BAD: Magic numbers and strings scattered everywhere
if ($user->role === 'admin') { // What other roles exist?
$cacheTime = 3600; // What does 3600 mean?
}
if ($order->status === 1) { // What does 1 represent?
$discount = 0.15; // Why 15%?
}
Cache::remember('users_list', 600, fn() => ...); // 600 what?
Solution 1: PHP Constants and Enums
Class Constants
// app/Constants/UserRole.php
class UserRole
{
public const ADMIN = 'admin';
public const EDITOR = 'editor';
public const VIEWER = 'viewer';
public const GUEST = 'guest';
public const ALL = [
self::ADMIN,
self::EDITOR,
self::VIEWER,
self::GUEST,
];
public static function hasPermission(string $role, string $action): bool
{
return match($role) {
self::ADMIN => true,
self::EDITOR => in_array($action, ['read', 'write', 'edit']),
self::VIEWER => $action === 'read',
self::GUEST => false,
default => false,
};
}
}
// Usage
if ($user->role === UserRole::ADMIN) {
// Clear intent
}
PHP 8.1+ Enums
// app/Enums/OrderStatus.php
enum OrderStatus: string
{
case PENDING = 'pending';
case PROCESSING = 'processing';
case SHIPPED = 'shipped';
case DELIVERED = 'delivered';
case CANCELLED = 'cancelled';
case REFUNDED = 'refunded';
public function label(): string
{
return match($this) {
self::PENDING => 'Pending Payment',
self::PROCESSING => 'Processing',
self::SHIPPED => 'Shipped',
self::DELIVERED => 'Delivered',
self::CANCELLED => 'Cancelled',
self::REFUNDED => 'Refunded',
};
}
public function color(): string
{
return match($this) {
self::PENDING => 'yellow',
self::PROCESSING => 'blue',
self::SHIPPED => 'indigo',
self::DELIVERED => 'green',
self::CANCELLED => 'red',
self::REFUNDED => 'gray',
};
}
public function canTransitionTo(self $newStatus): bool
{
return match($this) {
self::PENDING => in_array($newStatus, [
self::PROCESSING,
self::CANCELLED,
]),
self::PROCESSING => in_array($newStatus, [
self::SHIPPED,
self::CANCELLED,
]),
self::SHIPPED => $newStatus === self::DELIVERED,
self::DELIVERED => $newStatus === self::REFUNDED,
default => false,
};
}
}
// Model with enum casting
class Order extends Model
{
protected $casts = [
'status' => OrderStatus::class,
];
public function transitionTo(OrderStatus $newStatus): void
{
if (!$this->status->canTransitionTo($newStatus)) {
throw new InvalidStateTransition(
"Cannot transition from {$this->status->value} to {$newStatus->value}"
);
}
$this->update(['status' => $newStatus]);
}
}
// Usage
$order->transitionTo(OrderStatus::PROCESSING);
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.
- 11d ago First seen · 605 lines · 34 tokens per session scan A 610697b1234a
laravel:constants-and-configuration is a skill published in the GitHub repository jpcaparas/superpowers-laravel (153 stars, last pushed 2mo ago), licensed MIT. It adds 34 tokens to every session and 3,751 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.
Other skills, from other repositories
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…
laravel-security
Laravel security best practices for authn/authz, validation, CSRF, mass assignment, file uploads, secrets, rate limiting, and secure deployment.
integration-fixture
Create or validate a .test integration fixture under tests/php/Integration/Fixtures.
create-module
Scaffold a new Marko module — a self-contained Composer package with composer.json, namespaced src/, and Pest tests. Use this skill whenever the user asks to create, add, or scaffold a new Marko module or package. Concrete triggers: 'create a module named payment', 'scaffold an acme/blog package', 'add a new module…
llamaindex-development
Expert guidance for LlamaIndex development including RAG applications, vector stores, document processing, query engines, and building production AI applications.
Behat BDD Testing
PHP BDD testing with Behat framework using Gherkin feature files, Mink browser extension, context classes, and Symfony integration for behavior-driven acceptance testing.