|Last Updated|| ||Ratings|| ||Unique User Downloads|| ||Download Rankings|
|2020-07-15 (9 months ago) ||Not yet rated by the users||Total: 35 ||All time: 10,122 This week: 269|
This package can be used to generate a REST API from a Laravel model.
It takes the name of given model and generates files to implement a Web services API for handling calls to the model class.
Currently the package can generate controller, resource, collection and route classes.
Laravel API Generator With Resources
This package is used to generate laravel api with Resources
You can install the package via composer:
composer require bhavingajjar/laravel-api-generator
Publish Configuration File
php artisan vendor:publish --provider="Bhavingajjar\LaravelApiGenerator\LaravelApiGeneratorServiceProvider" --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:
add in env
for allow cross origin support
API_ALLOW_CROSS_ORIGIN = true
for json content type
API_JSON_RESPONSE = true
php artisan api:generate --model=User
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security related issues, please email firstname.lastname@example.org instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.
||Applications that use this package
No pages of applications that use this class were specified.
If you know an application of this package, send a message to the author to add a link here.