tracelet library
Tracelet — Production-grade background geolocation for Flutter.
Battery-conscious motion-detection intelligence, geofencing, SQLite persistence, HTTP sync, and headless Dart execution for iOS & Android.
import 'package:tracelet/tracelet.dart' as tl;
// 1. Listen to events
tl.Tracelet.onLocation((location) => print(location));
// 2. Configure & ready
await tl.Tracelet.ready(tl.Config(
geo: tl.GeoConfig(distanceFilter: 10),
));
// 3. Start tracking
await tl.Tracelet.start();
Classes
- ActivityChangeEvent
- Event fired when the detected device activity changes.
- AppConfig
- Application lifecycle and behavior settings.
- AuthorizationEvent
- Event fired when the HTTP Authorization token exchange occurs.
- Config
- Top-level compound configuration for Tracelet.
- ConnectivityChangeEvent
- Event fired when network connectivity changes.
- Coords
- Geographic coordinates with accuracy metrics.
- DeviceInfo
- Information about the device.
- ForegroundServiceConfig
- Configuration for the Android foreground service notification.
- GeoConfig
- Location accuracy and sampling settings.
- Geofence
- A geofence definition.
- GeofenceConfig
- Geofencing settings.
- GeofenceEvent
- Event fired when a geofence transition occurs.
- GeofencesChangeEvent
- Event fired when the set of active geofences changes.
- HeadlessEvent
- Event dispatched to the headless (background isolate) callback.
- HeartbeatEvent
- Event fired on each heartbeat interval.
- HttpConfig
- HTTP synchronization settings.
- HttpEvent
- Event fired during HTTP sync operations.
- Location
- A recorded location from the native platform.
- LocationActivity
- Activity recognition data associated with a location.
- LocationBattery
- Battery state associated with a location.
- LocationFilter
- Location filtering and denoising configuration.
- LoggerConfig
- Logging and debug settings.
- MotionConfig
- Motion detection settings.
- PermissionRationale
- Rationale dialog configuration for background location permission.
- PersistenceConfig
- Data persistence and database retention settings.
- ProviderChangeEvent
- Event fired when the location provider state changes.
- Sensors
- Information about the device's available sensors.
- SQLQuery
- Query parameters for reading stored locations or log entries.
- State
- The current state of the Tracelet plugin.
- Tracelet
- Production-grade background geolocation for Flutter.
Enums
- AccuracyAuthorization
- Accuracy authorization (iOS 14+).
- ActivityConfidence
- Confidence level for activity detection.
- ActivityType
- Activity types detected by the motion detection engine.
- AuthorizationStatus
- Authorization status for location permissions.
- DesiredAccuracy
- Desired accuracy levels for location requests.
- GeofenceAction
- Geofence transition actions.
- HttpMethod
- HTTP method for sync.
- LocationActivityType
- iOS activity type hints for CLLocationManager.
- LocationFilterPolicy
- How the location filter handles rejected locations.
- LocationOrder
- Sort order for location queries.
- LogLevel
- Log levels for the Tracelet logger.
- PersistMode
- Which record types to persist to the local database.
- TrackingMode
- Tracking modes.