Socialite Laravel Application code example
Example 1: socialite laravel 7
'github' => [
'client_id' => env('GITHUB_CLIENT_ID'),
'client_secret' => env('GITHUB_CLIENT_SECRET'),
'redirect' => 'http://your-callback-url',
],
Example 2: socialite laravel 7
$user = Socialite::driver('github')->user();
$token = $user->token;
$refreshToken = $user->refreshToken;
$expiresIn = $user->expiresIn;
$token = $user->token;
$tokenSecret = $user->tokenSecret;
$user->getId();
$user->getNickname();
$user->getName();
$user->getEmail();
$user->getAvatar();