is Visit Detection Active
Whether a monitoring session started with startVisitDetection is currently ACTIVE.
Use it for an on-demand snapshot, such as the initial state of a toggle - it replaces facilities().isMonitoringActive(). A session still running from facilities().startMonitoring() reads false. To follow changes, observe subscribeToVisitDetectionStatus.
Android (Kotlin)
lifecycleScope.launch {
autoCheckInSwitch.isChecked = AFCore.locations().isVisitDetectionActive()
}Content copied to clipboard
iOS (Swift)
Task {
let isOn = (try? await AFCore.shared.locations().isVisitDetectionActive())?.boolValue ?? false
autoCheckInToggle.isOn = isOn
}Content copied to clipboard