You can install the package via composer:
composer require yabhq/flightdeck
Generate new API key for authorization
php artisan flightdeck:generate app1
List all available API keys
php artisan flightdeck:list
FlightDeck makes authenticating users with multiple guards a breeze.
Suppose you wish to add support for login, logout and token refreshing for a hypothetical "customer" user type.
Simply extend the FlightDeck AuthController
class as follows:
<?php
namespace App\Http\Controllers\Customer;
use Yab\FlightDeck\Http\Controllers\AuthController as FlightAuthController;
class AuthController extends FlightAuthController
{
/**
* Get the guard to be used for login, logout and token refreshes.
*
* @return \Illuminate\Contracts\Auth\StatefulGuard
*/
protected function guard()
{
return auth()->guard('customer');
}
}
You can also extend FlightDeckForgotPasswordController
and FlightDeckResetPasswordController
in a similar way.
composer test
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security related issues, please email us instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.