The Laravel Artisan Cheatsheet now has an API. Learn more.

make:rule

Create a new validation rule

Options

  • force - Create the class even if the rule already exists Optional
  • implicit - Generate an implicit rule Optional
  • invokable - Generate a single method, invokable rule class Optional

Arguments

  • name - The name of the rule Required
php artisan make:rule [-f|--force] [-i|--implicit] [--invokable] [--] <name>