PHP code example of dezinger / socialiteproviders-alfaid

1. Go to this page and download the library: Download dezinger/socialiteproviders-alfaid 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/ */

    

dezinger / socialiteproviders-alfaid example snippets


'alfaid' => [    
  'domain' => env('ALFAID_DOMAIN'),
  'domain_api' => env('ALFAID_DOMAIN_API'),  
  'client_id' => env('ALFAID_CLIENT_ID'),  
  'client_secret' => env('ALFAID_CLIENT_SECRET'),  
  'redirect' => env('ALFAID_REDIRECT_URI'),
  'guzzle' => [
    \GuzzleHttp\RequestOptions::CERT => env('ALFAID_PATH_CER'),
    \GuzzleHttp\RequestOptions::SSL_KEY => [
        env('ALFAID_PATH_KEY'),
        env('ALFAID_KEY_PASS')
    ],
  ],
],

protected $listen = [
    \SocialiteProviders\Manager\SocialiteWasCalled::class => [
        // ... other providers
        \SocialiteProviders\AlfaID\AlfaIDExtendSocialite::class.'@handle',
    ],
];

return Socialite::driver('alfaid')->redirect();