Question

I am using Scribe to access the LinkedIn API. I am saving the Access Token along with the Access Token Secret in the database and use them every time I call the API.

The Access Token is supposed to expire 60 days after it has been generated.

I would like to automatically refresh the access token before it expires. I couldn't find a way to do it programatically without the user intervention.

Was it helpful?

Solution

You are not supposed to be able to refresh the access token without the user's intervention. The system was designed this way in order to protect the user's data from being accessed indefinitely.

Linkedin wants to ensure that you cannot access the user's data unless they are actively using your application. To me, if a user doesn't visit your application within 60 days, it means that they aren't using it, and you should not be able to access that data.

I hope this helps.

OTHER TIPS

 @params={:"oauth_token"=>"XXXXXXXXXXX", 
 :oauth_token_secret=>"XXXXXXXXXXX", 
 :oauth_expires_in=>"5184000"}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top