appwin_analytics library

Product analytics for Appwin.

Sessions, screens and custom events, ingested by the Appwin backend and explored in the web dashboard (trends, funnels, retention). The native SDK owns the pipeline: batching, offline persistence and upload all happen below this thin Dart layer.

Depends on appwin_core, which it re-exports: one configure() covers this package and its siblings.

import 'package:appwin_analytics/appwin_analytics.dart';

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await AppwinCore.instance.configure(appId: 'your-app-id');

  final analytics = await AppwinAnalytics.instance.initialize();
  if (analytics.isReady) {
    AppwinCore.instance.track('level_completed', props: {'level': 3});
  }
}

Classes

AppwinAnalytics
Public facade of the Appwin Analytics SDK.
AppwinCore
Shared foundation for every Appwin SDK.
AppwinInitResult
What a product's initialize() answers.
AppwinMask
Hides child in session replays, whatever the project's replay settings.
AppwinNavigatorObserver
Reports the visible page route as a screen: the screen_view event, and the screen names on the session replay timeline.
AppwinPush
Routes Appwin pushes to the product that owns them (a Support reply opens that conversation, a campaign its link).
AppwinUnmask
Shows child in session replays even when the project masks all text or all images. Text fields inside stay masked, always.
AppwinUserAttributes
What your app knows about its user, sent to Appwin by AppwinCore.instance.identify and AppwinCore.instance.updateUser.

Enums

AppwinConsentPurpose
What an event stream may be used for. Each purpose has its own AppwinConsentState.
AppwinConsentState
What a user answered for a consent purpose.
AppwinInitStatus
Coarse outcome of a product's initialize().
AppwinProduct
An Appwin product, as the server names it in its availability verdict.
AppwinUnavailableReason
Why a product is closed to this app.

Typedefs

AppwinAnalyticsConsent = AppwinConsentState
Replaced by AppwinConsentState, which AppwinCore.instance.setConsent takes for one purpose or all three.
AppwinScreenNameExtractor = String? Function(RouteSettings settings)
Returns the screen name of settings, or null to skip the route.