Overview

You can dynamically open/close the widget using the open and close methods.
window.chatbase.open(); // opens the widget
window.chatbase.close(); // closes the widget