Open Fatman13 opened 10 years ago
I have it
+1
this is the params
hash I'm getting in the omniauth failure controller action:
{"message"=>"server_error", "strategy"=>"linkedin"}
. no further explanations. any idea anyone?
I'm getting the same thing. This issue was opened in 2014 and still have no solution?
FYI I switched to the omniauth-linkedin gem and this one works.
I had the following error:
I, [2019-01-11T12:34:11.289315 #7478] INFO -- omniauth: (linkedin) Request phase initiated.
I, [2019-01-11T12:34:12.237318 #7478] INFO -- omniauth: (linkedin) Request phase initiated.
I, [2019-01-11T12:34:17.953765 #7478] INFO -- omniauth: (linkedin) Callback phase initiated.
E, [2019-01-11T12:34:18.598240 #7478] ERROR -- omniauth: (linkedin) Authentication failure! invalid_credentials: OAuth2::Error, :
{"serviceErrorCode":100,"message":"Not enough permissions to access: GET /me","status":403}
Just changed my gem from gem omniauth-linkedin-oauth2
to gem 'omniauth-linkedin
, ran bundle install
and it worked! :)
@henricazottes that is being deprecated no? since it uses v1?
Well, I can see that it was supposed to be deprecated but it still works.
I managed to switch to oauthv2, the problem the op is describing comes from the scope permissions that are different in v2. I went back to omniauth-linkedin-oauth2
and changed
r_basicprofile
to r_liteprofile
auth.info.image
anymore but now auth.info.picture_url
With those changes everything seems to work :)
@henricazottes I think I will try to squeeze v1 as long as possible!
@henricazottes found a way to get the profile url? Really sucks if there isn't a way to get that info
Didn't try :/
I fix it using gem omniauth-linkedin-oauth2 1.0.0 and in devise.rb config.omniauth :linkedin, ENV['LINKEDIN_APP_ID'], ENV['LINKEDIN_APP_SECRET'], scope: 'r_liteprofile,r_emailaddress'
/auth/linkedin
took me directly to/auth/failure
in dev environment. Not seeing linkedin login page.