laravel-actions

Installation
SKILL.md

Laravel Actions

lorisleiva/laravel-actions lets you write a single PHP class that handles one specific task and run it as an object, controller, job, listener, or command — whichever is appropriate.

Install: composer require lorisleiva/laravel-actions Create: php artisan make:action MyAction

Core structure

Every action is a plain PHP class with the AsAction trait and a handle method:

use Lorisleiva\Actions\Concerns\AsAction;

class PublishNewArticle
{
    use AsAction;

    public function handle(User $author, string $title, string $body): Article
Related skills

More from aaronflorey/agent-skills

Installs
24
First Seen
Mar 10, 2026