Package to use FreeBoxPHP library to access you FreeBox/IliadBox from Laravel apps.
Using composer:
composer require madpilot78/Laravel-FreeBoxPHP
This package provides in laravel a madpilot78\FreeBoxPHP\Box
class that can be
injected in controllers.
Otherwise it can be instantiated via the Laravel Service Container like this:
namespace App\Repositories;
use Illuminate\Support\Facades\App;
use madpilot78\FreeBoxPHP\Box;
class RouterRepository
{
private Box $box;
public function __construct()
{
$this->box = App::make(Box::class);
if (empty($this->box->getBoxInfo())) {
$this->box->discover();
}
}
/* ... */
}
Refer to FreeBoxPHP for details on how to use the underlying library.