laravel-restive / restive
An API framework for Laravel
Fund package maintenance!
zcwilt
Requires
- illuminate/auth: ^8.0|^9.0|^10.0
- illuminate/database: ^8.0|^9.0|^10.0
Requires (Dev)
- codedungeon/phpunit-result-printer: ^0.32.0
- mockery/mockery: ^1.1
- nunomaduro/collision: ^4.0
- orchestra/testbench: ~5.0|~6.0
- phpunit/phpunit: ^8.0|^9.0
This package is auto-updated.
Last update: 2024-12-15 19:49:16 UTC
README
Introduction
Api Query Builder allows for complex filtering, sorting via an api endpoint.
It is intended to be part of a larger package that also provides full CRUD abilities for a Laravel API.
Full documentation is available here
but see examples below for an idea of what the package provides.
Installation
There is no current release so to install you will need to do
composer require laravel-restive/restive dev-master
Filtering
Examples
where[]=id:eq:1
whereIn[]=id:(1,2,3)
whereBetween[]=age:18,45
Sorting
sort[]=id,-name
would sort ascending on id, the sort descending on name
Columns
By default queries will return all columns
You can restrict columns using
columns[]=id,name
Lots More
Lots more filtering options are available. see the Documentation