1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-28 17:02:04 +03:00

Filled out base Book API endpoints, added example responses

This commit is contained in:
Dan Brown
2020-01-12 14:45:54 +00:00
parent a8595d8aaf
commit 04a8614136
12 changed files with 284 additions and 20 deletions

View File

@ -8,6 +8,8 @@ use Illuminate\Http\JsonResponse;
class ApiController extends Controller
{
protected $rules = [];
/**
* Provide a paginated listing JSON response in a standard format
* taking into account any pagination parameters passed by the user.
@ -17,4 +19,12 @@ class ApiController extends Controller
$listing = new ListingResponseBuilder($query, request(), $fields);
return $listing->toResponse();
}
/**
* Get the validation rules for this controller.
*/
public function getValdationRules(): array
{
return $this->rules;
}
}