Q: Idle period in Worklight 6.2 Hybrid app How are application idle settings configured for Worklight 6.2 Hybrid applications?
We are developing a hybrid app for Android 4.1.x with JQuery and would like to return the user to the login page after a period of inactivity...
Is there any in built capability in the framework we should be looking to make use of for this?

A: There is no built-in idle functionality. You will need to implement a custom one.
One way to achieve this would be to base your custom implementation on counting against the Worklight Server session timeout. 
The session timeout is defined in your-project\server\conf\worklight.properties.
What you could do is: 


*

*Upon a successful WL.Client.connect(), you will start counting for the same amount as set for the session timeout

*For every server action (adapter request...), reset the counting

*If the counting expired (or reaches, say, 5-10 seconds before), logout from the realm and display the login form
I don't think it would be good to count for "general" idle time in the app, since you'll need to account for both the session timeout And whichever "activity" timeout you will set, which will have to be Lower than the session timeout. its just more scenarios to take care of...
Edit: actually I have another idea - use the API for heartbeat in Worklight to keep the connection to the server active, and count for whichever activity timeout you would like for the app... If it expires, logout from the realm and display the login form.

A: You can also do it without pinging the server, with Jquery by attaching the mouse and key listeners to document or body. 
Something like this code: (not tested)
var idleTime = 30*1000; //30 seconds
var idleTimer = null;

$(document.body).bind('mousemove,keydown,click',function(){
    clearTimeout(idleTimer);
    idleTimer = setTimeout(isIdle,idleTime);
});

function isIdle(){
    clearTimeout(idleTimer);
    //logout and go to login form
}

Another option which maybe a better UX (depending on your specific needs) is to capture the screen turn-off/turn-on natively on device. 
