api.chat.onOperatorsAway
Whenever any operator goes away or offline, the given callback will be triggered.
Examples
Maybe you want to show a red icon whenever you do not have operators around to chat:
olark('api.chat.onOperatorsAway', function() {
document.getElementById('chat-indicator').className = 'red-icon';
});
Discussion
Feel free to propose good uses for this method, or even drop us some suggestions for improvement! You can also join our mailing list to collaborate with other developers and get updates from us.