Linkedin auth token generated from android device is not working on web server

687 views Asked by At

I am trying to get LinkedIn User Access token using linkedin-j-android library. I am able to get a Valid auth token (60 days validity) and secret.

I am able to fetch all the user details using that auth token in the android device but when I am passing the same auth token to the web server and there I am using the same auth token to fetch the same user details, I am getting Invalid access token response.

The same token is working in Android device but on server It is not working. On the server, I am using same API keys and Secret of the LinkedIn App which I have used in Android device.

2

There are 2 answers

8
Vaibhav Agarwal On BEST ANSWER

According to me auth-token generated on device can't work on your server. You have to generate different auth-token there to maintain session. Auth token can be used only on single device at a time. You can't pass it to different devices.

You can get more details about it here

http://docs.oracle.com/cd/E19728-01/820-2550/authtoken_auth.html

0
Jambaaz On

I been able to generate an auth token which works over Mobile and Web simultaneously .

refer https://github.com/Hafiz-Waleed-Hussain/EasyLinkedInAndroid