> ## Documentation Index
> Fetch the complete documentation index at: https://alphaconsultings.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Generators

> Scaffolding flow for models, services, controllers, migrations, and scenarios.

# Generators

Scaffold generators keep runtime and repository structure consistent.

## Typical flow

1. `make:model`
2. `make:migration`
3. `make:controller`
4. `make:service`
5. `make:scenario --mongo` or `--test`

## What each generator produces

### `make:model`

Creates a model class under:

* `src/app/models/<Name>.ts`
* or `src/test/database/models/<Name>.ts` with `--test`

Typical outcome:

* table name
* connection name
* schema skeleton
* relation examples
* validation hooks and model events stubs

### `make:controller`

Creates:

* `src/app/controllers/<Name>Controller.ts`
* or `src/test/controllers/<Name>Controller.ts`

Generated CRUD methods:

* `index`
* `show`
* `store`
* `update`
* `destroy`

With `--soft`, also generates:

* `restore`

### `make:service`

Creates:

* `src/app/services/<Name>Service.ts`
* or `src/test/services/<Name>Service.ts`

Generated CRUD methods:

* `all`
* `find`
* `create`
* `update`
* `delete`
* `restore`

### `make:scenario`

Creates coordinated app or test artifacts for a full preset:

* models
* factories
* migrations
* seeders
* optional controllers
* optional services

## Best practice

Generate in stages and run generated code through tests before committing.

Use next:

* [Controllers](../getting-started/controllers)
* [Services](../getting-started/services)
* [Cookbook](../getting-started/cookbook)
