getRegisteredProfile

abstract suspend fun getRegisteredProfile(): SmartWalkingProfile?

Retrieves the current SmartWalking profile/status from the server.

Return

true if the profile is valid and the server reports an active/ok status; false otherwise.

Throws

if retrieval fails.

Android (Kotlin)

lifecycleScope.launch {
try {
val ok = AFCore.smartWalking().getProfile()
if (ok) showMessage("SmartWalking is configured") else showMessage("Not configured")
} catch (t: Throwable) {
showError("Failed to fetch SmartWalking status: ${t.message}")
}
}

iOS (Swift)

Task {
do {
let ok = try await AFCore.shared.smartWalking().getProfile()
ok ? self.showMessage("SmartWalking is configured")
: self.showMessage("Not configured")
} catch {
self.showError("Failed to fetch SmartWalking status: \\(error.localizedDescription)")
}
}