Skip to content

AppsFlyer module

From JSDoc (src/module/appsflyer/AffiseAppsFlyer.ts:6):

Send AppsFlyer event data to Affise.

  • AffiseModules.APPSFLYER = "AppsFlyer" (src/module/AffiseModules.ts:1-16)

AffiseAppsFlyer (src/module/appsflyer/AffiseAppsFlyer.ts:6) implements AffiseModuleAppsFlyerApi (src/module/appsflyer/AffiseModuleAppsFlyerApi.ts:3):

Affise.module.appsFlyer.logEvent(eventName: string, eventValues: Record<string, any>): void
// AffiseModuleAppsFlyerApi.ts:3-10
Affise.module.appsFlyer.hasModule(): Promise<boolean>

Pair every appsFlyer.logEvent call with a matching Affise.module.appsFlyer.logEvent call so the event is mirrored to Affise.

Since 1.7.16 the module ships as its own npm package, affise-attribution-module-appsflyer (Android and iOS). Install it next to the core library:

Terminal window
npm install affise-attribution-lib
npm install affise-attribution-module-appsflyer

The package only pulls in the native dependency (com.affise:module-appsflyer / AffiseModule/AppsFlyer at 1.7.16); its JS entry point is empty, so keep importing everything from affise-attribution-lib. Rebuild the native app (and run pod install on iOS) after installing.

pod 'AffiseModule/AppsFlyer', '1.7.16'
implementation "com.affise:module-appsflyer:$affise_version"