njaaazi / laravel-fpl
Fantasy Premier League API wrapper for Laravel.
Fund package maintenance!
njaaazi
Requires
- php: ^8.2
- guzzlehttp/guzzle: ^7.7
- illuminate/contracts: ^10.19
- spatie/laravel-package-tools: ^1.16
Requires (Dev)
- nunomaduro/collision: ^7.8
- orchestra/testbench: ^8.8
- phpunit/phpunit: ^10.3
This package is auto-updated.
Last update: 2024-04-09 05:29:00 UTC
README
Fantasy Premier League API wrapper for Laravel.
Installation
You can install the package via composer:
composer require njaaazi/laravel-fpl
You can publish the config file with:
php artisan vendor:publish --tag="laravel-fpl-config"
This is the contents of the published config file:
return [ "base-url" => env( "FPL_BASE_URL", "https://fantasy.premierleague.com/api", ), ];
Usage
use Njaaazi\Fpl\FplClient; $fpl = new FplClient; $generalInfo = $fpl->generalInfo(); $allFixtures = $fpl->allFixtures();
Using Facade
use Njaaazi\Fpl\Facades\Fpl; $generalInfo = Fpl::generalInfo(); $allFixtures = Fpl::allFixtures();
Testing
vendor/bin/phpunit
or
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.