PHPackages                             signifly/laravel-domain-commands - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. signifly/laravel-domain-commands

AbandonedArchivedLibrary[CLI &amp; Console](/categories/cli)

signifly/laravel-domain-commands
================================

Artisan commands to Laravel apps that utilizes Domain Driven Design.

v1.0.0(2y ago)222.8k14[1 issues](https://github.com/signifly/laravel-domain-commands/issues)MITPHPPHP ^7.2|^8.0

Since Jun 18Pushed 2y agoCompare

[ Source](https://github.com/signifly/laravel-domain-commands)[ Packagist](https://packagist.org/packages/signifly/laravel-domain-commands)[ Docs](https://github.com/signifly/laravel-domain-commands)[ RSS](/packages/signifly-laravel-domain-commands/feed)WikiDiscussions master Synced yesterday

READMEChangelog (10)Dependencies (3)Versions (11)Used By (0)

Laravel Domain Commands
=======================

[](#laravel-domain-commands)

The `signifly/laravel-domain-commands` package adds a handful of useful Artisan commands to your Laravel application. It assumes you are utilizing the Domain Driven Design approach.

It is heavily inspired by the DDD approach mentioned in [this great article](https://stitcher.io/blog/organise-by-domain) by Brent from Spatie.

In addition, it assumes that you have a separate namespace for your domain. Take a look of this example of the autoload section from a composer.json file:

```
{
    "autoload": {
        "psr-4": {
            "App\\" : "app/App/",
            "Domain\\" : "app/Domain/",
            "Support\\" : "app/Support/"
        },
        "classmap": [
            "database"
        ],
        "files": [
            "app/helpers.php"
        ]
    }
}
```

Basic Usage
-----------

[](#basic-usage)

The package comes with a handful of commands out of the box.

**Actions**

Generate a new Action using the `domain:action` command:

```
php artisan domain:action CreateUserAction -d User
```

*NOTE: You may use the -d|--domain option to specify the given domain for the action. If you do not specify a domain, it will be generated within the default namespace. You may configure that in the config file.*

**Data Transfer Objects**

Generate a new Data Transfer Object class using the `domain:dto` command:

```
php artisan domain:dto UserData -d User
```

**Enums**

Generate a new Enum class using the `domain:enum` command:

```
php artisan domain:enum UserType -d User
```

**Events**

Generate a new Event class using the `domain:event` command:

```
php artisan domain:event UserCreated -d User
```

**Models**

Generate a new Eloquent model class using the `domain:model` command:

```
php artisan domain:model User -d User
```

**Observers**

Generate a new Observer class using the `domain:observer` command:

```
php artisan domain:observer UserObserver -d User
```

**Policies**

Generate a new Policy class using the `domain:policy` command:

```
php artisan domain:policy UserPolicy -d User
```

**Rules**

Generate a new Rule class usign the `domain:rule` command:

```
php artian domain:rule CustomEmailRule -d User
```

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require signifly/laravel-domain-commands
```

The package will automatically register itself.

You can optionally publish the config file with:

```
php artisan vendor:publish --tag="domain-commands-config"
```

Testing
-------

[](#testing)

```
composer test
```

Security
--------

[](#security)

If you discover any security issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Morten Poul Jensen](https://github.com/pactode)
- [All contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

36

—

LowBetter than 82% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 56.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~179 days

Recently: every ~402 days

Total

10

Last Release

903d ago

Major Versions

v0.0.9 → v1.0.02023-11-21

PHP version history (2 changes)v0.0.1PHP ^7.1

v0.0.8PHP ^7.2|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/cd06d3bd4452ca3ce5c956b4c0bcb1240ca692f590bc4cdabe104fd07156e0bf?d=identicon)[signifly](/maintainers/signifly)

---

Top Contributors

[![pactode](https://avatars.githubusercontent.com/u/5956778?v=4)](https://github.com/pactode "pactode (21 commits)")[![michaelklopf](https://avatars.githubusercontent.com/u/2892138?v=4)](https://github.com/michaelklopf "michaelklopf (8 commits)")[![Razorsheep](https://avatars.githubusercontent.com/u/459217?v=4)](https://github.com/Razorsheep "Razorsheep (5 commits)")[![Tjoosten](https://avatars.githubusercontent.com/u/5157609?v=4)](https://github.com/Tjoosten "Tjoosten (3 commits)")

---

Tags

artisancommandsdomain-driven-designlaravel

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/signifly-laravel-domain-commands/health.svg)

```
[![Health](https://phpackages.com/badges/signifly-laravel-domain-commands/health.svg)](https://phpackages.com/packages/signifly-laravel-domain-commands)
```

###  Alternatives

[acdphp/laravel-schedule-police

Stop, start or execute scheduled commands from a simple dashboard without redeploying, while maintaining the visibility, control, and reviewability of the configurations in your codebase.

5116.9k](/packages/acdphp-laravel-schedule-police)[jakyeru/laravel-shell

Laravel-Shell adds a terminal interface to your web application, allowing you to run shell commands directly from your browser.

166.1k](/packages/jakyeru-laravel-shell)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
