Mahdi
Mahdi

Reputation: 35

Refresh LinkedIn Access Token using Scribe

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.

Upvotes: 2

Views: 1353

Answers (2)

Samer Bechara
Samer Bechara

Reputation: 2109

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.

Upvotes: 2

hs.chandra
hs.chandra

Reputation: 707

 @params={:"oauth_token"=>"XXXXXXXXXXX", 
 :oauth_token_secret=>"XXXXXXXXXXX", 
 :oauth_expires_in=>"5184000"}

Upvotes: 0

Related Questions