+ Start a Discussion
timgumtotimgumto 

OAuth: inconsistent token expiration

Hi,

I've implemented OAuth for our Salesforce integration over the last couple of years.  During that time we've been supporting over 100 different Salesforce orgs.  However, even though all of them are authenticating using the same OAuth flow, I've noticed that some orgs have expired token errors from time to time.  However, this seems inconsistent.  Some orgs have never needed to reauthenticate, while some need to reauthenticate every few months.
Recently we had a new org that seems to need to reauthenticate every few days, which obviously isn't going to work.  Are there additional settings at the org level (security perhaps?) that would cause this inconsistency?  Has anyone else experienced this?  What methods could be used to troubleshoot?

Thanks,
tim
sandeep@Salesforcesandeep@Salesforce
Hi timgumto,

Accesstoken gets expired in a particual time duration if it is binded with Refresh token and getting refeteched in code on run time when it is expried then you would not see problem but if itis not handeled then you wouls see thsi issue. One more thing if you have written your code to generate access token before every call then also you would not see the issue.

Please let me know in case of any further query.

Thanks 
Sandeep Singhal
http://www.codespokes.com/