Documentation

Listening for Events

You can listen for events by running the following code:

UpscopeManager.shared?.on(MessageType.EVENT_NAME) { data ->
    // Handle event
}

List of Events

Event NameAdditional ArgumentsDescription
BEGIN_SESSIONA session has started.
CONTINUE_SESSIONA session is continuing from a previous app launch.
END_SESSIONA session has ended.
STOP_SESSIONThe session was stopped by the visitor.
NEW_OBSERVERobserverId: String, observerData: { id: String, name: String?, screenWidth: Int, screenHeight: Int, windowWidth: Int, windowHeight: Int, hasFocus: Boolean }Indicates a new agent is observing.
OBSERVER_UPDATEobserverId: String, data: MapAn observer's data has changed.
CUSTOM_MESSAGEmessage: StringA custom message sent by an observer or visitor.