1
![Stack Overflow](http://cdn.sstatic.net/stackoverflow/img/apple-touch-icon.png)
You can handle each ajax response and check it for 401 code which means - Not Authorized. Then reset your timer.
$(document).ajaxComplete(function (event, request, settings) {
if(request.status === 401) {
// reset timer
}
});
You may try to handle another AJAX events:
Global ajax...