cleaniquecoders / eligify
Eligify is a flexible rule and criteria engine that determines whether an entity — such as a person, application, or transaction — meets the defined acceptance conditions. It powers decision-making systems by making eligibility data-driven, traceable, and automatable.
Fund package maintenance!
Cleanique Coders
Installs: 11
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 0
Forks: 2
Open Issues: 0
pkg:composer/cleaniquecoders/eligify
Requires
- php: ^8.4
- cleaniquecoders/php-env-key-manager: ^1.1
- cleaniquecoders/traitify: ^1.2
- illuminate/contracts: ^11.0||^12.0
- livewire/livewire: ^3
- lorisleiva/laravel-actions: ^2.9
- spatie/laravel-package-tools: ^1.16
Requires (Dev)
- larastan/larastan: ^3.0
- laravel/pint: ^1.14
- nunomaduro/collision: ^8.8
- orchestra/testbench: ^10.0.0||^9.0.0
- pestphp/pest: ^4.0
- pestphp/pest-plugin-arch: ^4.0
- pestphp/pest-plugin-laravel: ^4.0
- phpstan/extension-installer: ^1.4
- phpstan/phpstan-deprecation-rules: ^2.0
- phpstan/phpstan-phpunit: ^2.0
README
Eligify is a flexible rule and criteria engine that determines whether an entity — such as a person, application, or transaction — meets the defined acceptance conditions. It powers decision-making systems by making eligibility data-driven, traceable, and automatable.
Features
- 🧱 Criteria Builder - Define eligibility requirements with weighted rules
- ⚖️ Rule Engine - 16+ operators for comprehensive validation
- 🎯 Evaluator - Real-time eligibility checks with detailed scoring
- 🔄 Workflow Manager - Trigger actions on pass/fail/excellent scores
- 🧾 Audit Log - Complete traceability of all decisions
- 🎨 Web Dashboard - Optional Telescope-style UI for management (disabled by default)
- 🧩 Model Integration - Seamless Laravel Eloquent integration
- 📊 Flexible Scoring - Weighted, pass/fail, percentage, and custom methods
Installation
You can install the package via composer:
composer require cleaniquecoders/eligify
You can publish and run the migrations with:
php artisan vendor:publish --tag="eligify-migrations"
php artisan migrate
You can publish the config file with:
php artisan vendor:publish --tag="eligify-config"
Usage
Quick Example
use CleaniqueCoders\Eligify\Facades\Eligify; // Define criteria $criteria = Eligify::criteria('loan_approval') ->addRule('credit_score', '>=', 650, 30) ->addRule('annual_income', '>=', 30000, 25) ->addRule('debt_ratio', '<=', 43, 20) ->passThreshold(70) ->save(); // Evaluate $result = Eligify::evaluate('loan_approval', [ 'credit_score' => 720, 'annual_income' => 55000, 'debt_ratio' => 35, ]); // Result: ['passed' => true, 'score' => 85, 'decision' => 'Approved', ...]
Optional Web Dashboard
Enable the dashboard for visual management:
# .env
ELIGIFY_UI_ENABLED=true
Access: http://your-app.test/eligify
Authorization (Production):
// AppServiceProvider.php Gate::define('viewEligify', function ($user) { return $user->hasRole('admin'); });
Complete Documentation
Key Guides:
- Quick Start Guide
- UI Setup Guide - Dashboard configuration & authorization
- Environment Variables - Complete
.envreference - Configuration Guide - All config options
- Model Data Extraction - Extract & evaluate Eloquent models
- CLI Commands - Artisan command reference
- Examples - 12+ real-world examples
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.

