Runtime Requirements
Before installing the Rest Generic Class package, ensure your environment meets these minimum requirements:PHP Version
- PHP 8.0 or higher is required
- The package leverages modern PHP features including typed properties, union types, and attributes
PHP 8.1 or 8.2 is recommended for optimal performance and security updates.
Laravel Framework
- Laravel 12.0 or higher is required
- The package depends on these Laravel components:
illuminate/database^12.0illuminate/http^12.0illuminate/pagination^12.0illuminate/mail^12.0illuminate/support^12.0illuminate/validation^12.0laravel/framework^12.51
Optional Dependencies
These packages are not required for basic functionality but enable additional features:Export Features
If you plan to use export functionality, install these packages:- maatwebsite/excel: Required for the
exportExcel()method to generate Excel spreadsheets - barryvdh/laravel-dompdf: Required for the
exportPdf()method to generate PDF documents
Permission Management
For advanced permission and role management features:- spatie/laravel-permission: Provides permission models, traits, and middleware for role-based access control
- nwidart/laravel-modules: Required when using module-aware permissions in a modular application structure
These optional packages can be installed at any time. The Rest Generic Class will detect their presence and enable the corresponding features automatically.
Environment Considerations
Database
The package works with any database supported by Laravel:- MySQL 5.7+
- PostgreSQL 10+
- SQLite 3.8.8+
- SQL Server 2017+
Cache Stores
For optimal caching performance, consider configuring one of these cache stores:- Redis (recommended for production)
- Memcached
- Database
- File (default, suitable for development)
Server Requirements
Your server should meet Laravel’s standard requirements:- BCMath PHP Extension
- Ctype PHP Extension
- Fileinfo PHP Extension
- JSON PHP Extension
- Mbstring PHP Extension
- OpenSSL PHP Extension
- PDO PHP Extension
- Tokenizer PHP Extension
- XML PHP Extension
Check your PHP configuration with
php -m to verify installed extensions.