Closed eroo36 closed 3 years ago
Thanks for the feedback, I will updated it. In the meantime you can setup linkedin
like this:
{
linkedin: {
profile_url: 'https://api.linkedin.com/v2/me',
// .. the rest of your configuration
}
}
According to their docs you don't need to specify the querystring parameter, and by default Grant will send your access token as Authorization Bearer header instead.
Let me know if it works.
Thanks for your quick response, I will try this
@Eroo36 this needed a little fix because of some leftovers from the previous API version for LinkedIn. If you pull master branch you will be able to login.
Hey thanks, it works now, but now it has another problem. I was not able to get the email with this
"linkedin": {
"client_id": "",
"secret": "",
"callback": "/callback",
"scope": ["r_emailaddress", "r_liteprofile"],
"response": ["tokens", "profile"]
}
I tried putting other responses but couldn't get it, I looked at it a little, and apparently you are supposed to use another URL to get email which is funny. https://api.linkedin.com/v2/emailAddress?q=members&projection=(elements*(handle~)))
It is possible to get the email as well with that usual method? Maybe I am missing something about the config, if not I guess gotta get email manually
That's a limitation on their end. If that's the case then you will have to pick one of the endpoints and get either the profile or the email. Generally Grant tries to do a single request for the profile_url
endpoint.
Alright, thanks for your help!!
In config/profile.json it is "profile_url": "https://api.linkedin.com/v1/people/~" and I couldn't manage to get profile info from linked in. New URL is "https://api.linkedin.com/v2/me?oauth2_access_token=token". I can use this but I couldn't figure out how I can change the query to oauth2_access_token in the package, so what can we do here?