Download the PHP package viralsbackpack/backpackapi without Composer
On this page you can find all versions of the php package viralsbackpack/backpackapi. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download viralsbackpack/backpackapi
More information about viralsbackpack/backpackapi
Files in viralsbackpack/backpackapi
Package backpackapi
Short Description CRUD Api in Backpack
License MIT
Homepage https://github.com/viralsbackpack/backpackapi
Informations about the package backpackapi
BackPackAPI
Quickly build an api interface for your Eloquent models, using Laravel 5. Erect a complete CMS at 10 minutes/model, max.
Features:
- Crud and search call api
- Back-end validation using Requests
- Easily overwrite functionality (customising how the create/update/delete process works is as easy as creating a new function with the proper name in your EntityCrudAPICrontroller)
Installation
Setup
1. Command
_Create controller and add route for api:
This command will create NameAPICrudController in folder app/Http/Api and add route api route resource in routes/backpack/api.php
or particular command
_Create controller:
_Add route for api:
2. Setup api
All the settings below can be added to any method in the controller.
_Add validate request:
_Setup structure data in response
or custom fields
Output:
_Set up extra data
Output:
_Set up return list entries after delete:
_Set message:
_Set status:
Usage
Method | URI | Name | Action | Parameter obligatory | Form data obligatory |
---|---|---|---|---|---|
GET/HEAD | api/name | crud-api.name.index | App\Http\Controllers\Api\NameCrudAPIController@index | ||
POST | api/name | crud-api.name.store | App\Http\Controllers\Api\NameCrudAPIController@store | ||
POST | api/name/search | crud-api.name.search | App\Http\Controllers\Api\TagCrudAPIController@search | search[value] | |
GET/HEAD | api/name/{id} | crud-api.name.show | App\Http\Controllers\Api\NameCrudAPIController@show | id | |
PUT/PATCH | api/name/{id} | crud-api.name.update | App\Http\Controllers\Api\NameCrudAPIController@update | id | _method = PUT ; id |
DELETE | api/name/{id} | crud-api.name.destroy | App\Http\Controllers\Api\NameCrudAPIController@destroy | id | _method = DELETE |
Credits
- [author name][[email protected]]
License
license. Please see the license file for more information.