Download the PHP package magetech/laravel-query-toolkit without Composer

On this page you can find all versions of the php package magetech/laravel-query-toolkit. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-query-toolkit

# MTS Laravel Query Toolkit

Latest Stable Version Total Downloads License PHP Version Require

Enterprise-grade query builder for Laravel APIs with filtering, sorting, searching, pagination, and relationship support.

Features

Requirements

Installation

ash composer require magetech/laravel-query-toolkit php artisan mts:query:install

Quick Start

`php use MageTech\QueryToolkit\Support\Facades\MtsQuery;

// In your controller public function index() { = MtsQuery::for(User::class) ->allowedFilters(['name', 'email', 'status']) ->allowedSorts(['name', 'created_at']) ->allowedIncludes(['posts', 'roles']) ->searchable(['name', 'email']) ->paginate();

return response()->json();

} `

API Parameters

Filtering

GET /api/users?filter[name]=John GET /api/users?filter[status]=active GET /api/users?filter[salary][gte]=50000 GET /api/users?filter[created_at][from]=2026-01-01&filter[created_at][to]=2026-12-31

Sorting

GET /api/users?sort=name GET /api/users?sort=-created_at GET /api/users?sort=name,-created_at

Searching

GET /api/users?search=john

Includes

GET /api/users?include=posts,roles

Field Selection

GET /api/users?fields[users]=id,name,email

Pagination

GET /api/users?page=2&per_page=25

Filter Types

Exact Filter

php AllowedFilter::exact('name') AllowedFilter::exact('status', 'status_column') // with alias

Partial Filter

php AllowedFilter::partial('name') // LIKE %value%

Boolean Filter

php AllowedFilter::boolean('is_active')

Numeric Filters

php AllowedFilter::numeric('price') AllowedFilter::gt('price') // greater than AllowedFilter::lt('price') // less than AllowedFilter::gte('price') // greater than or equal AllowedFilter::lte('price') // less than or equal

Date Filters

php AllowedFilter::date('created_at') AllowedFilter::date('created_at', null, '>=') AllowedFilter::dateRange('created_at') // from/to

Enum Filter

php AllowedFilter::enum('status', ['active', 'inactive', 'banned'])

Scope Filter

php AllowedFilter::scope('active')

Callback Filter

php AllowedFilter::callback('custom', function (, , ) { return ->where('column', 'value'); })

Relationship Filter

php AllowedFilter::relationship('posts', 'is_published', BooleanFilter::make('is_published'))

JSON Filter

php AllowedFilter::json('metadata', '$.key')

Sorting

php ->allowedSorts(['name', 'created_at', 'email'])

Includes

`php ->allowedIncludes(['posts', 'roles', 'comments'])

// Count includes ->allowedIncludes([ AllowedInclude::count('posts_count', 'posts'), ]) `

Search

`php // LIKE search ->searchable(['name', 'email', 'description'])

// Full-text search ->searchable(['name', 'description'], SearchDriver::FullText) `

Custom Filters

ash php artisan mts:query:make-filter ProductStatusFilter

php

Configuration

php // config/mts-query.php return [ 'parameters' => [ 'filter' => 'filter', 'sort' => 'sort', 'include' => 'include', 'fields' => 'fields', 'search' => 'search', 'per_page' => 'per_page', 'page' => 'page', ], 'default_per_page' => 15, 'max_per_page' => 100, // ... ];

Security

Testing

ash composer test

License

MTS License. See LICENSE for details.


All versions of laravel-query-toolkit with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/database Version ^11.0|^12.0|^13.0
illuminate/http Version ^11.0|^12.0|^13.0
illuminate/support Version ^11.0|^12.0|^13.0
illuminate/routing Version ^11.0|^12.0|^13.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package magetech/laravel-query-toolkit contains the following files

Loading the files please wait ...