PHP code example of optimus / oauth2-server-lumen

1. Go to this page and download the library: Download optimus/oauth2-server-lumen library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

optimus / oauth2-server-lumen example snippets

 artisan migrate --path=vendor/lucadegasperi/oauth2-server-laravel/migrations
bootstrap/app.php

$app->routeMiddleware([
    'check-authorization-params' => 'Optimus\OAuth2Server\Middleware\CheckAuthCodeRequestMiddleware',
    'csrf' => 'Laravel\Lumen\Http\Middleware\VerifyCsrfToken',
    'oauth' => 'Optimus\OAuth2Server\Middleware\OAuthMiddleware',
    'oauth-owner' => 'Optimus\OAuth2Server\Middleware\OAuthOwnerMiddleware'
]);
vendor/lucadegasperi/oauth2-server-laravel/config/oauth2.php
config/oauth2.php
class_alias('Illuminate\Support\Facades\Config', 'Config');
bootstrap/app.php