deleteAutomaticVisit

abstract suspend fun deleteAutomaticVisit(date: String): AFResult

Deletes an automatic visit previously recorded via submitAutomaticVisit.

Use this if a previously submitted visit is determined to be invalid (e.g., the member indicates it was a mistake, or a later system process flags it).

The visit is identified by the same parameters used to submit it.

Return

true if the visit was successfully deleted; false otherwise (e.g., not found).

Parameters

date

The date of the visit. E.g. "2025-08-01".

Throws

on network or validation errors.

Android (Kotlin) — user-initiated deletion

// User swiped to delete an automatic visit from their timeline.
val ok = AFCore.activities.deleteAutomaticVisit(
date = "2025-08-01"
)
if (ok) refreshUi() // remove the item from the list

iOS (Swift) — user-initiated deletion

// User confirms deletion of an automatic visit.
let ok = try await AFCore.shared.activities.deleteAutomaticVisit(
date: "2025-09-01"
)
if ok { refreshUI() } // remove the item from the list