Activities
Activities is the member's history, one month at a time: gym visits, self-reports, Fit@Home workouts and SmartWalking steps, each with its review status, plus a monthly summary of progress toward the member's goal. It is what an app's activity calendar is built from.
What you can do
- Load a month's summary (accepted, pending and rejected activities, goal days) and its activity list.
- Refresh automatically when the SDK confirms a change: a step sync, a visit, a self-report or a selfie added or removed.
- Let members delete only their pending activities; accepted, rejected and SmartWalking entries stay.
Key APIs
| Call | What it is for |
|---|---|
activities().get(month, year) | The month's summary and activities |
activities().subscribeToActivityEvents() | A "refresh now" signal when the history changes |
activities().deleteAutomaticVisit(date) | Delete a pending automatic gym visit |
Example
- Android (Kotlin)
- iOS (Swift)
lifecycleScope.launch {
val month = AFCore.activities().get(month = 2, year = 2026)
showSummary(month.monthlySummary)
showCalendar(month.activities)
}
Task {
let month = try await AFCore.shared.activities().get(month: 2, year: 2026)
showSummary(month.monthlySummary)
showCalendar(month.activities)
}
UI Reference
A monthly calendar that color-codes each day by activity type and status, with the month's progress on top.
Learn more
- API Reference for
activities()and its models. - Complete integration guides, including the activity calendar, are in AIDE Docs.