Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid access token #77

Open
antoinealej opened this issue Aug 19, 2022 · 7 comments
Open

Invalid access token #77

antoinealej opened this issue Aug 19, 2022 · 7 comments

Comments

@antoinealej
Copy link

Hi guys,

When I'm getting the access token using Postman I receive a 350 character long token.

When I'm doing it using react-linkedin-login-oauth2 I receive a 211 character long token.

There is a length difference between the 2, the one from Postman is longer.

When I use the Postman token to query https://api.linkedin.com/v2/emailAddress?q=members&projection=(elements*(handle~)) it works properly but when I use the shorter token from react-linkedin-login-oauth2 I receive an error from linkedin:

{
  serviceErrorCode: 65600,
  message: 'Invalid access token',
  status: 401
}

Any idea what I could be doing wrong?

Thanks

@chinmay4o
Copy link

same here

@antoinealej
Copy link
Author

@nvh95 any tips about that?

@Mohammad-Sahil
Copy link

same here

@samirahosseini937
Copy link

Same here... Has anyone found a solution?

@emrests
Copy link

emrests commented Apr 26, 2024

Same here. This token doesn’t look right, check the value and try again.

@Filipos93
Copy link

I have exactly the same issue.

@Filipos93
Copy link

I have found an answer in the official linkedin authorization code flow documentation. This 211 character string that you're receiving is not the access token. It is an authorization code. Authorization code can be exchanged for an access token. To exchange it for an access token you can use linkedin-api-client library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants