Skip to content

Installation

v1.1.0

Installing the package takes only a few minutes.


Requirements

RequirementVersion
PHP8.2+
Laravel11, 12 or 13
ComposerLatest

Install

Run:

bash
composer require domain/laravel-domain-generator

The package supports Laravel 11, 12 and 13.


Publish Configuration

bash
php artisan vendor:publish --provider="Domain\DomainGenerator\DomainGeneratorServiceProvider"

This publishes the configuration file:

text
config/domain-generator.php

Generate JWT Secret

bash
php artisan jwt:secret

Your application is now ready to generate domains and use the built-in authentication endpoints.


Generate your first domain

bash
php artisan make:domain User

Generated structure:

text
app/
├── Domain/
│   └── User/
│       ├── DTO/
│       ├── Repositories/
│       └── Service/
├── Http/
│   ├── Controllers/
│   ├── Requests/
│   └── Resources/
└── Models/

Next Step

Continue to JWT Authentication.

Released under the MIT License.