+ Start a Discussion

INVALID_SESSION_ID: Session timed out



I got a weired problem about the api call to session. 


We use same username and password to login salesforce to do some operations for different cron job . but about every 2 hours, I got the error message ".UnexpectedErrorFault_Exception: INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Session timed out".


I removed all the logout from my code and did login before do the operations . but still got same problem.


I am using WSC 20.0 and partner API,


I would be very appreciated if someone can help me 







your session timeout sets to 2 hours in security controls = > session settings.