Skip to main content

herald_amplitude 1.0.0-dev.1 copy "herald_amplitude: ^1.0.0-dev.1" to clipboard
herald_amplitude: ^1.0.0-dev.1 copied to clipboard

A Herald vendor adapter that sends to Amplitude: events, user properties, screen views and revenue.

Herald for Amplitude #

Sends Herald events and properties to Amplitude, over amplitude_flutter: events, user properties, screen views and revenue.

final amplitude = Amplitude(
  Configuration(
    apiKey: apiKey,
    optOut: true, // silent until consent
    autocapture: const AutocaptureOptions(screenViews: false), // Herald sends screen views
  ),
);
final tracker = AmplitudeAnalyticsTrackerService(
  eventTrackerFactory: CompositeAmplitudeEventTrackerFactory([
    ScreenViewAmplitudeEventTrackerFactory(amplitude),
    GenericAmplitudeEventTrackerFactory(amplitude),
  ]),
  propertySetterFactory: CompositeAmplitudePropertySetterFactory([
    GenericAmplitudePropertySetterFactory(amplitude),
  ]),
);
final service = AmplitudeAnalyticsService(amplitude);

Values keep their types. A ScreenViewEvent becomes [Amplitude] Screen Viewed, and purchases go through AmplitudeRevenueEvent and RevenueAmplitudeEventTracker, deduplicated by insertId. Amplitude forgets the opt-out between launches, so re-apply the stored answer after start().

Documentation #

The Herald website has the guides, and the repository has the other packages and an example app.

0
likes
0
points
557
downloads

Publisher

unverified uploader

Weekly Downloads

A Herald vendor adapter that sends to Amplitude: events, user properties, screen views and revenue.

Repository (GitHub)
View/report issues

Topics

#analytics #amplitude #tracking

License

unknown (license)

Dependencies

amplitude_flutter, flutter, herald

More

Packages that depend on herald_amplitude