Login Html Page :
LinkedIn Credential :
LINKEDIN_APP_ID=myappid LINKEDIN_APP_SECRET=appsecreretcode LINKEDIN_REDIRECT=http://portal-locall.com/auth/linkedin/callback
Socialite LinkedInProvider
Hi, I have a query with Laravel Socialite Package.
I am facing problem only for LinkedIn as it was working fine before.
Getting problem when LinkedIn remove auth1 support. I am using laravel 5.8 version with 4.1 socialite.
I got following error message
Client error: POST https://www.linkedin.com/oauth/v2/accessToken resulted in a 400 Bad Request response:
{"error":"invalid_request","error_description":"A required parameter "code" is missing"}
Thanks
Login Html Page :
LinkedIn Credential :
LINKEDIN_APP_ID=myappid LINKEDIN_APP_SECRET=appsecreretcode LINKEDIN_REDIRECT=http://portal-locall.com/auth/linkedin/callback
Socialite LinkedInProvider
I am unable to put all code here. There is no attachment option
Did anyone find a solution yet? Out of 100 user, this error happens only to some linkedin accounts which are registered in our database
I have the same error, please help me :)
If someone comes across this thread and is wondering: I'm not 100% sure if it's the only cause but this definitely happens if a user cancels the Linkedin Login. The user gets redirected back. After that laravel tries to issue an Request but has no code so the API Error appears.
Easy fix is to just try/catch the Socialite::driver('linkedin')->user();
Hi,
Please let me know anyone fixes this issue. I am getting the same error
Client error: POST https://www.linkedin.com/oauth/v2/accessToken resulted in a 400 Bad Request response: {"error":"invalid_request","error_description":"A required parameter "code" is missing"}
That does not work for me. here is my code
$provider = Socialite::driver($provider);
try{
$user = $provider->user();
}
catch (ClientException $ex){
// echo $ex->getMessage();exit;
return redirect()->route('login');
}
catch (InvalidStateException $ex){
// echo $ex->getMessage();exit;
return redirect()->route('login');
}
make sure you activated the
Sign In with LinkedIn (product)
Try this tutorial, it's work for me. I'm sorry i can't include the link because i'm already sign up Laracast today. You can found the tutorial in your search engine using keyword "How to Get SignIn with LinkedIn to work" with author Taric A. as a product manager from LinkedIn.
The main problem is beacuse you haven't activated "Sign In with LinkedIn" product on your application.
I have the same problem. guide me if you have any solution
if someone use "Sign In with LinkedIn Using OpenID Connect" in Laravel please guide us.
@iffikhan you should update your services in config/services.php to 'linkedin-openid' => [...] also the redirect function : return Socialite::driver('linkedin-openid')->redirect(); it works for me
@MohammedAmineELHARCHI Lot of thanks dear its really work for me. i spent 3 days for this Thanks again.
@MohammedAmineELHARCHI Thanks 1 Million Times. Works like charm. https://laravel.com/docs/11.x/socialite#configuration
User Driver Provider name (linkedin-openid) return Socialite::driver('linkedin-openid')->scopes(['w_member_social','openid','profile','email'])->redirect();
Note: In scopes use scope parameter from your linkedin account
same as change in config/services.php if you use provider name (linkedin) change to (linkedin-openid) 'linkedin-openid' => [ 'client_id' => env('LINKEDIN_CLIENT_ID'), 'client_secret' => env('LINKEDIN_SECRET_ID'), 'redirect' => env('LINKEDIN_REDIRECT_URL'), ],
Please or to participate in this conversation.