Events (Dynamics 365 Channel Integration Framework 2.0 JavaScript API reference)

All client-side code is initiated by events and the events occur in Dynamics 365 Unified Interface. You associate s specific function in a JavaScript library to run when an event occurs. This specific function is called an event handler.

Each event handler specifies a function within a JavaScript library and the parameters that you can pass to the function. The JavaScript API provides methods that you can use to attach event handlers to the events.

Events

Events Description
CIFInitDone Invoked when Dynamics 365 Channel Integration Framework 2.0 is loaded to determine if the APIs are ready to be consumed.
onclicktoact Invoked when user selects the outbound communication (ClickToAct) field in a form.
onmodechanged Invoked when the panel mode is manually toggled between Minimized (0), Docked (1), and Hidden (2).
onpagenavigate Invoked when the main Unified Interface page navigation occurs.
onsendkbarticle Invoked when the user selects the Send button in the Knowledge Base control.
onsizechanged Invoked when the side panel width is changed.
onSessionSwitched Invoked when the session is switched.
onSessionClosed Invoked when the session is closed.
onPresenceChange​ Invoked when the presence or availability state of the agent has changed either manually or programmatically.