AAttendrix Docsv1.0
Mobile
ReferenceImplemented

Custom Actions Reference

Authoritative specifications for FlutterFlow custom actions, local state management, and Supabase RPC invocations.

Custom Actions Reference

FlutterFlow Custom Actions provide the execution bridge between the Flutter UI runtime, local reactive state (FFAppState), and Supabase PostgreSQL. Attendrix implements 51 custom actions located in lib/custom_code/actions/.


Action Inventory

Action NameSource FileReturn TypeParameters
calculateProjectedAttendancecalculate_projected_attendance.dartFuture<AttendanceCalculatorDataStruct>4
calculateWalkRoutecalculate_walk_route.dartFuture<RouteResultStruct>4
cancelClasscancel_class.dartFuture<FeedbackStruct>2
checkForUpdatescheck_for_updates.dartFuture<bool>4
combineEnrolledCoursescombine_enrolled_courses.dartFuture<List<EnrolledCourseStruct>>3
completeCourseEnrollmentcomplete_course_enrollment.dartFuture<FeedbackStruct>1
completeUserOnboardingcomplete_user_onboarding.dartFuture<bool>7
connectGoogleCalendarconnect_google_calendar.dartFuture<void>0
convertPathToUploadedFileconvert_path_to_uploaded_file.dartFuture<FFUploadedFile>1
deleteUserAccountdelete_user_account.dartFuture<bool>3
Functionexecute_schedule_query.dartFuture<T>4
generateDateRangegenerate_date_range.dartFuture<List<DateTime>>3
generateGreetinggenerate_greeting.dartFuture<String>6
generatePastDateRangegenerate_past_date_range.dartFuture<List<DateTime>>3
generateTimelinegenerate_timeline.dartFuture<List<DateTime>>3
generateUsernamegenerate_username.dartFuture<String>1
getCampusBuildingDataget_campus_building_data.dartFuture<CampusBuildingStruct?>2
getCoreCoursesget_core_courses.dartFuture<List<CoreCourseStruct>>1
getElectiveCoursesget_elective_courses.dartFuture<List<ElectiveCourseStruct>>1
getElectiveRequirementsListget_elective_requirements_list.dartFuture<List<String>>2
getLabCoursesget_lab_courses.dartFuture<List<EnrolledCourseStruct>>1
getNextBusInfoget_next_bus_info.dartFuture<RouteResultStruct>2
hasLocationPermissionhas_location_permission.dartFuture<bool>0
hasPushPermissionhas_push_permission.dartFuture<bool>0
initOneSignalinit_one_signal.dartFuture<void>0
isRollNumberUniqueis_roll_number_unique.dartFuture<bool>3
isUsernameAvailableis_username_available.dartFuture<bool>1
linkOneSignalUserlink_one_signal_user.dartFuture<void>3
loadAppBootstrapStatusload_app_bootstrap_status.dartFuture<AppBootstrapStruct>1
loadLatestApodload_latest_apod.dartFuture<ApodStruct>0
loadUserProfileload_user_profile.dartFuture<UserProfileStruct>0
logOutUserlog_out_user.dartFuture<void>0
loginOneSignalUserlogin_one_signal_user.dartFuture<void>1
logoutOneSignalUserlogout_one_signal_user.dartFuture<void>0
markAbsentmark_absent.dartFuture<MarkAbsentResponseStruct>3
openSyllabusPdfopen_syllabus_pdf.dartFuture<bool>1
optInPushNotificationsopt_in_push_notifications.dartFuture<void>0
optOutPushNotificationsopt_out_push_notifications.dartFuture<void>0
parseRollNumberparse_roll_number.dartFuture<RollNumberDetailsStruct>1
recordWalkingTripActionrecord_walking_trip_action.dartFuture<bool>7
reportClassCancelledreport_class_cancelled.dartFuture<bool>1
rescheduleClassreschedule_class.dartFuture<FeedbackStruct>4
resetUserAttendancereset_user_attendance.dartFuture<bool>2
restoreClassrestore_class.dartFuture<FeedbackStruct>1
scheduleClassschedule_class.dartFuture<FeedbackStruct>6
Functionsync_app_data.dartFuture<T>4
syncNowGoogleCalendarsync_now_google_calendar.dartFuture<bool>0
loadFromStoragesync_routing_dataset.dartFuture<bool>0
unMarkAbsentun_mark_absent.dartFuture<MarkAbsentResponseStruct>1
initializeAndroidWidgetBridgeupdate_android_widget_from_app_state.dartFuture<void>0
updateUserPreferencesupdate_user_preferences.dartFuture<bool>1

Core Architectural Actions

markAbsent

File: lib/custom_code/actions/mark_absent.dart
Return Type: Future<MarkAbsentResponseStruct>

Field / PropTypeDefaultDescription
classDatarequired
ScheduledClassStruct—Input parameter `classData` of type `ScheduledClassStruct`.
sourcerequired
String—Input parameter `source` of type `String`.
reason
String?—Input parameter `reason` of type `String?`.

unMarkAbsent

File: lib/custom_code/actions/un_mark_absent.dart
Return Type: Future<MarkAbsentResponseStruct>

Field / PropTypeDefaultDescription
classDatarequired
ScheduledClassStruct—Input parameter `classData` of type `ScheduledClassStruct`.

calculateProjectedAttendance

File: lib/custom_code/actions/calculate_projected_attendance.dart
Return Type: Future<AttendanceCalculatorDataStruct>

Field / PropTypeDefaultDescription
enrolledCourse
EnrolledCourseStruct?—Input parameter `enrolledCourse` of type `EnrolledCourseStruct?`.
addToAttended
int?—Input parameter `addToAttended` of type `int?`.
addToSkip
int?—Input parameter `addToSkip` of type `int?`.
actionTone
ActionTone?—Input parameter `actionTone` of type `ActionTone?`.

connectGoogleCalendar

File: lib/custom_code/actions/connect_google_calendar.dart
Return Type: Future<void>

This action accepts no input arguments.

calculateWalkRoute

File: lib/custom_code/actions/calculate_walk_route.dart
Return Type: Future<RouteResultStruct>

Field / PropTypeDefaultDescription
originrequired
LatLng—Input parameter `origin` of type `LatLng`.
destinationrequired
LatLng—Input parameter `destination` of type `LatLng`.
includeGeometryrequired
bool—Input parameter `includeGeometry` of type `bool`.
targetArrivalTime
DateTime?—Input parameter `targetArrivalTime` of type `DateTime?`.

initOneSignal

File: lib/custom_code/actions/init_one_signal.dart
Return Type: Future<void>

This action accepts no input arguments.

completeUserOnboarding

File: lib/custom_code/actions/complete_user_onboarding.dart
Return Type: Future<bool>

Field / PropTypeDefaultDescription
fullNamerequired
String—Input parameter `fullName` of type `String`.
rollNumberrequired
String—Input parameter `rollNumber` of type `String`.
departmentIdrequired
String—Input parameter `departmentId` of type `String`.
batchIdrequired
String—Input parameter `batchId` of type `String`.
currentSemesterrequired
int—Input parameter `currentSemester` of type `int`.
username
String?—Input parameter `username` of type `String?`.
bio
String?—Input parameter `bio` of type `String?`.

Full Custom Action Catalog

cancelClass

File: lib/custom_code/actions/cancel_class.dart
Signature: Future<FeedbackStruct> cancelClass(String classId, String? reason)

Field / PropTypeDefaultDescription
classIdrequired
String—Parameter `classId` of type `String`.
reason
String?—Parameter `reason` of type `String?`.

checkForUpdates

File: lib/custom_code/actions/check_for_updates.dart
Signature: Future<bool> checkForUpdates(BuildContext context, { String? appVersion, bool showUpToDateToast = true, })

Field / PropTypeDefaultDescription
contextrequired
BuildContext—Parameter `context` of type `BuildContext`.
appVersion
{ String?—Parameter `appVersion` of type `{ String?`.
truerequired
bool showUpToDateToast =—Parameter `true` of type `bool showUpToDateToast =`.
}required
—Parameter `}` of type ``.

combineEnrolledCourses

File: lib/custom_code/actions/combine_enrolled_courses.dart
Signature: Future<List<EnrolledCourseStruct>> combineEnrolledCourses(List<EnrolledCourseStruct>? coreCourses, List<EnrolledCourseStruct>? electives, List<EnrolledCourseStruct>? labs)

Field / PropTypeDefaultDescription
coreCourses
List<EnrolledCourseStruct>?—Parameter `coreCourses` of type `List<EnrolledCourseStruct>?`.
electives
List<EnrolledCourseStruct>?—Parameter `electives` of type `List<EnrolledCourseStruct>?`.
labs
List<EnrolledCourseStruct>?—Parameter `labs` of type `List<EnrolledCourseStruct>?`.

completeCourseEnrollment

File: lib/custom_code/actions/complete_course_enrollment.dart
Signature: Future<FeedbackStruct> completeCourseEnrollment(List<EnrolledCourseStruct> enrolledCourses)

Field / PropTypeDefaultDescription
enrolledCoursesrequired
List<EnrolledCourseStruct>—Parameter `enrolledCourses` of type `List<EnrolledCourseStruct>`.

convertPathToUploadedFile

File: lib/custom_code/actions/convert_path_to_uploaded_file.dart
Signature: Future<FFUploadedFile> convertPathToUploadedFile(String imageUrl)

Field / PropTypeDefaultDescription
imageUrlrequired
String—Parameter `imageUrl` of type `String`.

deleteUserAccount

File: lib/custom_code/actions/delete_user_account.dart
Signature: Future<bool> deleteUserAccount({ required String username, required String password, })

Field / PropTypeDefaultDescription
usernamerequired
{ required String—Parameter `username` of type `{ required String`.
passwordrequired
required String—Parameter `password` of type `required String`.
}required
—Parameter `}` of type ``.

Function

File: lib/custom_code/actions/execute_schedule_query.dart
Signature: Future<T> Function() rpcCall, { Duration timeout = const Duration(seconds: 8), int maxRetries = 1, })

Field / PropTypeDefaultDescription
rpcCallrequired
)—Parameter `rpcCall` of type `)`.
8)required
{ Duration timeout = const Duration(seconds:—Parameter `8)` of type `{ Duration timeout = const Duration(seconds:`.
1required
int maxRetries =—Parameter `1` of type `int maxRetries =`.
}required
—Parameter `}` of type ``.

generateDateRange

File: lib/custom_code/actions/generate_date_range.dart
Signature: Future<List<DateTime>> generateDateRange(DateTime startDate, DateRange dateRange, WeekendPolicy weekendPolicy)

Field / PropTypeDefaultDescription
startDaterequired
DateTime—Parameter `startDate` of type `DateTime`.
dateRangerequired
DateRange—Parameter `dateRange` of type `DateRange`.
weekendPolicyrequired
WeekendPolicy—Parameter `weekendPolicy` of type `WeekendPolicy`.

generateGreeting

File: lib/custom_code/actions/generate_greeting.dart
Signature: Future<String> generateGreeting(String? username, String toneString, List<ScheduledClassStruct>? classes, List<String>? recentHistory, bool? useScheduleClasses, bool? useActionTone)

Field / PropTypeDefaultDescription
username
String?—Parameter `username` of type `String?`.
toneStringrequired
String—Parameter `toneString` of type `String`.
classes
List<ScheduledClassStruct>?—Parameter `classes` of type `List<ScheduledClassStruct>?`.
recentHistory
List<String>?—Parameter `recentHistory` of type `List<String>?`.
useScheduleClasses
bool?—Parameter `useScheduleClasses` of type `bool?`.
useActionTone
bool?—Parameter `useActionTone` of type `bool?`.

generatePastDateRange

File: lib/custom_code/actions/generate_past_date_range.dart
Signature: Future<List<DateTime>> generatePastDateRange(DateTime startDate, DateRange dateRange, WeekendPolicy weekendPolicy)

Field / PropTypeDefaultDescription
startDaterequired
DateTime—Parameter `startDate` of type `DateTime`.
dateRangerequired
DateRange—Parameter `dateRange` of type `DateRange`.
weekendPolicyrequired
WeekendPolicy—Parameter `weekendPolicy` of type `WeekendPolicy`.

generateTimeline

File: lib/custom_code/actions/generate_timeline.dart
Signature: Future<List<DateTime>> generateTimeline(DateTime selectedDate, List<DateTime>? startTimes, List<DateTime>? endTimes)

Field / PropTypeDefaultDescription
selectedDaterequired
DateTime—Parameter `selectedDate` of type `DateTime`.
startTimes
List<DateTime>?—Parameter `startTimes` of type `List<DateTime>?`.
endTimes
List<DateTime>?—Parameter `endTimes` of type `List<DateTime>?`.

generateUsername

File: lib/custom_code/actions/generate_username.dart
Signature: Future<String> generateUsername(String? selectedGenre)

Field / PropTypeDefaultDescription
selectedGenre
String?—Parameter `selectedGenre` of type `String?`.

getCampusBuildingData

File: lib/custom_code/actions/get_campus_building_data.dart
Signature: Future<CampusBuildingStruct?> getCampusBuildingData(String? buildingId, DateTime? startTime)

Field / PropTypeDefaultDescription
buildingId
String?—Parameter `buildingId` of type `String?`.
startTime
DateTime?—Parameter `startTime` of type `DateTime?`.

getCoreCourses

File: lib/custom_code/actions/get_core_courses.dart
Signature: Future<List<CoreCourseStruct>> getCoreCourses(String batchId)

Field / PropTypeDefaultDescription
batchIdrequired
String—Parameter `batchId` of type `String`.

getElectiveCourses

File: lib/custom_code/actions/get_elective_courses.dart
Signature: Future<List<ElectiveCourseStruct>> getElectiveCourses(String batchId)

Field / PropTypeDefaultDescription
batchIdrequired
String—Parameter `batchId` of type `String`.

getElectiveRequirementsList

File: lib/custom_code/actions/get_elective_requirements_list.dart
Signature: Future<List<String>> getElectiveRequirementsList(String batchId, int semesterNumber)

Field / PropTypeDefaultDescription
batchIdrequired
String—Parameter `batchId` of type `String`.
semesterNumberrequired
int—Parameter `semesterNumber` of type `int`.

getLabCourses

File: lib/custom_code/actions/get_lab_courses.dart
Signature: Future<List<EnrolledCourseStruct>> getLabCourses(String batchId)

Field / PropTypeDefaultDescription
batchIdrequired
String—Parameter `batchId` of type `String`.

getNextBusInfo

File: lib/custom_code/actions/get_next_bus_info.dart
Signature: Future<RouteResultStruct> getNextBusInfo(List<BusRouteStruct>? routes, LatLng? userLocation)

Field / PropTypeDefaultDescription
routes
List<BusRouteStruct>?—Parameter `routes` of type `List<BusRouteStruct>?`.
userLocation
LatLng?—Parameter `userLocation` of type `LatLng?`.

hasLocationPermission

File: lib/custom_code/actions/has_location_permission.dart
Signature: Future<bool> hasLocationPermission()

hasPushPermission

File: lib/custom_code/actions/has_push_permission.dart
Signature: Future<bool> hasPushPermission()

isRollNumberUnique

File: lib/custom_code/actions/is_roll_number_unique.dart
Signature: Future<bool> isRollNumberUnique(String? rollNumber, { String? excludeUserId, })

Field / PropTypeDefaultDescription
rollNumber
String?—Parameter `rollNumber` of type `String?`.
excludeUserId
{ String?—Parameter `excludeUserId` of type `{ String?`.
}required
—Parameter `}` of type ``.

isUsernameAvailable

File: lib/custom_code/actions/is_username_available.dart
Signature: Future<bool> isUsernameAvailable(String username)

Field / PropTypeDefaultDescription
usernamerequired
String—Parameter `username` of type `String`.

linkOneSignalUser

File: lib/custom_code/actions/link_one_signal_user.dart
Signature: Future<void> linkOneSignalUser(String? supabaseUserId, String? email, String? batchId)

Field / PropTypeDefaultDescription
supabaseUserId
String?—Parameter `supabaseUserId` of type `String?`.
email
String?—Parameter `email` of type `String?`.
batchId
String?—Parameter `batchId` of type `String?`.

loadAppBootstrapStatus

File: lib/custom_code/actions/load_app_bootstrap_status.dart
Signature: Future<AppBootstrapStruct> loadAppBootstrapStatus(String? storedVersionId)

Field / PropTypeDefaultDescription
storedVersionId
String?—Parameter `storedVersionId` of type `String?`.

loadLatestApod

File: lib/custom_code/actions/load_latest_apod.dart
Signature: Future<ApodStruct> loadLatestApod()

loadUserProfile

File: lib/custom_code/actions/load_user_profile.dart
Signature: Future<UserProfileStruct> loadUserProfile()

logOutUser

File: lib/custom_code/actions/log_out_user.dart
Signature: Future<void> logOutUser()

loginOneSignalUser

File: lib/custom_code/actions/login_one_signal_user.dart
Signature: Future<void> loginOneSignalUser(String? userId)

Field / PropTypeDefaultDescription
userId
String?—Parameter `userId` of type `String?`.

logoutOneSignalUser

File: lib/custom_code/actions/logout_one_signal_user.dart
Signature: Future<void> logoutOneSignalUser()

openSyllabusPdf

File: lib/custom_code/actions/open_syllabus_pdf.dart
Signature: Future<bool> openSyllabusPdf(String? syllabusPath)

Field / PropTypeDefaultDescription
syllabusPath
String?—Parameter `syllabusPath` of type `String?`.

optInPushNotifications

File: lib/custom_code/actions/opt_in_push_notifications.dart
Signature: Future<void> optInPushNotifications()

optOutPushNotifications

File: lib/custom_code/actions/opt_out_push_notifications.dart
Signature: Future<void> optOutPushNotifications()

parseRollNumber

File: lib/custom_code/actions/parse_roll_number.dart
Signature: Future<RollNumberDetailsStruct> parseRollNumber(String rollNumber)

Field / PropTypeDefaultDescription
rollNumberrequired
String—Parameter `rollNumber` of type `String`.

recordWalkingTripAction

File: lib/custom_code/actions/record_walking_trip_action.dart
Signature: Future<bool> recordWalkingTripAction(String originNodeId, String destinationNodeId, DateTime startedAt, DateTime arrivedAt, double? distanceMeters, int gpsFixCount, double? avgAccuracyMeters)

Field / PropTypeDefaultDescription
originNodeIdrequired
String—Parameter `originNodeId` of type `String`.
destinationNodeIdrequired
String—Parameter `destinationNodeId` of type `String`.
startedAtrequired
DateTime—Parameter `startedAt` of type `DateTime`.
arrivedAtrequired
DateTime—Parameter `arrivedAt` of type `DateTime`.
distanceMeters
double?—Parameter `distanceMeters` of type `double?`.
gpsFixCountrequired
int—Parameter `gpsFixCount` of type `int`.
avgAccuracyMeters
double?—Parameter `avgAccuracyMeters` of type `double?`.

reportClassCancelled

File: lib/custom_code/actions/report_class_cancelled.dart
Signature: Future<bool> reportClassCancelled(String? classId)

Field / PropTypeDefaultDescription
classId
String?—Parameter `classId` of type `String?`.

rescheduleClass

File: lib/custom_code/actions/reschedule_class.dart
Signature: Future<FeedbackStruct> rescheduleClass(String classId, DateTime scheduledStart, DateTime scheduledEnd, String? venue)

Field / PropTypeDefaultDescription
classIdrequired
String—Parameter `classId` of type `String`.
scheduledStartrequired
DateTime—Parameter `scheduledStart` of type `DateTime`.
scheduledEndrequired
DateTime—Parameter `scheduledEnd` of type `DateTime`.
venue
String?—Parameter `venue` of type `String?`.

resetUserAttendance

File: lib/custom_code/actions/reset_user_attendance.dart
Signature: Future<bool> resetUserAttendance(String? userId, String? password)

Field / PropTypeDefaultDescription
userId
String?—Parameter `userId` of type `String?`.
password
String?—Parameter `password` of type `String?`.

restoreClass

File: lib/custom_code/actions/restore_class.dart
Signature: Future<FeedbackStruct> restoreClass(String classId)

Field / PropTypeDefaultDescription
classIdrequired
String—Parameter `classId` of type `String`.

scheduleClass

File: lib/custom_code/actions/schedule_class.dart
Signature: Future<FeedbackStruct> scheduleClass(String courseId, DateTime scheduledStart, DateTime scheduledEnd, String? venue, bool isExtraClass, bool isPlusSlot)

Field / PropTypeDefaultDescription
courseIdrequired
String—Parameter `courseId` of type `String`.
scheduledStartrequired
DateTime—Parameter `scheduledStart` of type `DateTime`.
scheduledEndrequired
DateTime—Parameter `scheduledEnd` of type `DateTime`.
venue
String?—Parameter `venue` of type `String?`.
isExtraClassrequired
bool—Parameter `isExtraClass` of type `bool`.
isPlusSlotrequired
bool—Parameter `isPlusSlot` of type `bool`.

Function

File: lib/custom_code/actions/sync_app_data.dart
Signature: Future<T> Function() dbCall, { Duration timeout = const Duration(seconds: 8), int maxRetries = 2, })

Field / PropTypeDefaultDescription
dbCallrequired
)—Parameter `dbCall` of type `)`.
8)required
{ Duration timeout = const Duration(seconds:—Parameter `8)` of type `{ Duration timeout = const Duration(seconds:`.
2required
int maxRetries =—Parameter `2` of type `int maxRetries =`.
}required
—Parameter `}` of type ``.

syncNowGoogleCalendar

File: lib/custom_code/actions/sync_now_google_calendar.dart
Signature: Future<bool> syncNowGoogleCalendar()

loadFromStorage

File: lib/custom_code/actions/sync_routing_dataset.dart
Signature: Future<bool> loadFromStorage()

initializeAndroidWidgetBridge

File: lib/custom_code/actions/update_android_widget_from_app_state.dart
Signature: Future<void> initializeAndroidWidgetBridge()

updateUserPreferences

File: lib/custom_code/actions/update_user_preferences.dart
Signature: Future<bool> updateUserPreferences(UserPreferencesStruct? userPrefs)

Field / PropTypeDefaultDescription
userPrefs
UserPreferencesStruct?—Parameter `userPrefs` of type `UserPreferencesStruct?`.

Was this page helpful?

Your feedback directly guides the engineering documentation roadmap.

On this page