This package is used to generate laravel restful api with Requests & Resources
You can install the package via composer:
composer require lararest/laravel-restapi-generator
php artisan vendor:publish --provider="lararest\\RestApiGenerator\RestApiGeneratorServiceProvider" --tag="config"
Next, if you plan for cross origin support, you should add middleware to your api middleware group within your app/Http/Kernel.php file:
'ApiHeaderInject'
add in env
for allow cross origin support
API_ALLOW_CROSS_ORIGIN = true
for json content type
API_JSON_RESPONSE = true
php artisan api:gen --model=User
composer test
Please see CONTRIBUTING for details.
If you discover any security related issues, please email aymannagy.ahmed@gmail.com instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.