Mobile AppsFlyer

The Mobile AppsFlyer plugin is specifically designed to implement native mobile attribution, analytics, tracking and marketing features through the AppsFlyer Android SDK and AppsFlyer iOS SDK in both Android and iOS, for games built using Construct 3.


The Mobile AppsFlyer plugin supports all essential mobile attribution features for applications and games. This includes event tracking, analytics, cross-promotion, open store tracking, device account management, device tracking, info tracking, etc.


The Mobile AppsFlyer plugin includes all features in the AppsFlyer Core SDK, and other essential additional features.

PlayFab API v2.png

Introduction

Step 1.png

The Construct Master Collection supports the full and easy integration of native mobile Android SDKs and iOS SDKs for both Construct 3 and Construct 2.


Please click here to learn more about Mobile.

Features


The Mobile AppsFlyer plugin integrates the native mobile AppsFlyer Android SDK and AppsFlyer iOS SDK into an application project made in Construct 3, with support for both Android and iOS. It allows you to integrate AppsFlyer's mobile attribution features, all features from the Core SDK and all essential additional features.


Here are some of the native features of the mobile plugin:

  • AppsFlyer Android SDK

  • AppsFlyer iOS SDK

  • AppsFlyer mobile attribution

  • Full event tracking features

  • Built-in device tracking

  • Built-in information tracking

  • Cross-promotion features

  • Privacy compliance features

  • AppsFlyer tools

  • Asynchronous API tools

  • Construct 3 Scripting support (JavaScript)

  • Well maintained and fully tested for production release.


For more information about native mobile or Android and iOS features, please click here to learn the introductory lessons to Mobile.


Platform Integration


Here are some of the platforms that are natively supported:

  • Android

  • iOS

  • Native Android

  • Native iOS


Build Support


Here are some of the supported build options:


Editor Features


Here are some of the features in the Construct editor:

  • Construct 3

 
 

How to use?

It is easy to use the Mobile AppsFlyer plugin, you will only need to follow the steps below.

1. The first step is to add the Mobile AppsFlyer object into the project.


2. If the Debug Mode property is checked, the plugin will log information and errors in the console for mobile debugging. Set this unchecked for your production release builds.



3. The Mobile AppsFlyer Android SDK or Mobile AppsFlyer iOS SDK is now fully integrated into your application or game application project.

 
 

Documentation

The Mobile AppsFlyer plugin is specifically designed to implement native mobile attribution, analytics, tracking and marketing features through the AppsFlyer Android SDK and AppsFlyer iOS SDK in both Android and iOS, for games built using Construct 3.



Integration Tutorial


The Mobile AppsFlyer plugin includes a tutorial project in the package that will guide you through the event sheet and JavaScript scripting usage.



  • The tutorial project explains the proper workflow in using the Mobile AppsFlyer plugin.

  • It explains all the basic features, including the actions, conditions and expressions of the Mobile AppsFlyer object.



Track Events


The Mobile AppsFlyer plugin allows you to send in-app events to AppsFlyer analytics. This method allows you to add events dynamically by adding them directly to the application code.

  • AppsFlyer methods internally used include trackEvent() and logEvent().

  • These in-app events help you track how loyal users discover your app, and attribute them to specific campaigns/media-sources.

  • Please take the time define the event/s you want to measure to allow you to track ROI (Return on Investment) and LTV (Lifetime Value).



  • The Mobile AppsFlyer plugin's most important feature is the event tracking.

  • You can track events with parameters. You can also use the predefined event parameters from the official list (5.2.2) below in the Event Parameters documentation section.



  • There is a JS Scripting counterpart of the Track Event action called the Track Event (JS) action.

  • Same as the previous one above, you can track events with parameters and also use the predefined event parameters from the official list (5.2.2) below in the Event Parameters documentation section.



AppsFlyer Events


Event Names:

  • af_level_achieved

  • af_add_payment_info

  • af_add_to_cart

  • af_add_to_wishlist

  • af_complete_registration

  • af_tutorial_completion

  • af_initiated_checkout

  • af_purchase

  • af_rate

  • af_search

  • af_spent_credits

  • af_achievement_unlocked

  • af_content_view

  • af_list_view

  • af_travel_booking

  • af_share

  • af_invite

  • af_login

  • af_re_engage

  • af_update

  • af_opened_from_push_notification

  • af_location_coordinates

  • af_customer_segment

  • af_subscribe

  • af_start_trial

  • af_ad_click

  • af_ad_view



Event Parameters


Event Parameters:

  • af_content

  • af_achievement_id

  • af_level

  • af_score

  • af_success

  • af_price

  • af_content_type

  • af_content_id

  • af_content_list

  • af_currency

  • af_quantity

  • af_registration_method

  • af_payment_info_available

  • af_max_rating_value

  • af_rating_value

  • af_search_string

  • af_date_a

  • af_date_b

  • af_destination_a

  • af_destination_b

  • af_description

  • af_class

  • af_event_start

  • af_event_end

  • af_lat

  • af_long

  • af_customer_user_id

  • af_validated

  • af_revenue

  • af_projected_revenue

  • af_receipt_id

  • af_tutorial_id

  • af_achievement_id

  • af_virtual_currency_name

  • af_deep_link

  • af_old_version

  • af_new_version

  • af_review_text

  • af_coupon_code

  • af_order_id

  • af_param_1

  • af_param_2

  • af_param_3

  • af_param_4

  • af_param_5

  • af_param_6

  • af_param_7

  • af_param_8

  • af_param_9

  • af_param_10


  • af_departing_departure_date

  • af_returning_departure_date

  • af_destination_list (scripting only)

  • af_city

  • af_region

  • af_country


  • af_departing_arrival_date

  • af_returning_arrival_date

  • af_suggested_destinations (scripting only)

  • af_travel_start

  • af_travel_end

  • af_num_adults

  • af_num_children

  • af_num_infants

  • af_suggested_hotels (scripting only)


  • af_user_score

  • af_hotel_score

  • af_purchase_currency

  • af_preferred_star_ratings (scripting only)


  • af_preferred_price_range (scripting only)

  • af_preferred_neighborhoods (scripting only)

  • af_preferred_num_stops


  • af_adrev_ad_type

  • af_adrev_network_name

  • af_adrev_placement_id

  • af_adrev_ad_size

  • af_adrev_mediated_network_name



Additional Notes


The Mobile AppsFlyer plugin has a sample In-App Purchases and In-App Subscriptions demo project using the event sheet.



  • The AppsFlyer SDK does not accept number parameter values. Although, in the Construct 3 editor, the Mobile AppsFlyer plugin simplifies the process.

  • You can input numbers in parameters, and it is automatically converted into a string in the background.

  • The AppsFlyer SDK accepts boolean values, but in Construct 3 events, you can input "true" or "false" in string to set the same parameter value.

  • The AppsFlyer SDK also accepts list (array) values, but at the moment the plugin does not support that through solely events. You can however still use the JS Scripting feature to set a list parameter value.



The Mobile AppsFlyer plugin has a sample In-App Purchases and In-App Subscriptions demo project using Construct 3's JavaScript scripting feature.



  • The Mobile AppsFlyer plugin supports Construct 3's JavaScript scripting feature, you can input the parameter values through JavaScript.

  • The Mobile AppsFlyer plugin with JavaScript supports strings, booleans and lists (array) as event parameter values.

 

Actions, Conditions & Expressions

Actions

press to zoom

press to zoom

press to zoom
1/2

The following action groups:

  • Pre-Initialization

  • Analytics

  • General

  • Tools

  • Cross Promotion

Pre-Initialization

  • Collect IMEI - If checked, it will enable the collection of IMEI. Default is checked.

  • Collect IMEI - Check to enable the collection of IMEI.


  • Set User ID - Setting your own Custom ID enables you to cross-reference your own unique ID with AppsFlyer’s user ID and the other devices’ IDs. Must be set before initialization, preferably "On Loader Layout Complete".

  • Customer User ID - User's own customer id for this Mobile AppsFlyer application.


  • Collect Android ID - If checked, it will enable the collection of Android ID. Default is checked.

  • Collect Android ID - Check to enable the collection of Android ID.


Analytics

  • Track Event - Send in-app events to AppsFlyer analytics. These in-app events help you track how loyal users discover your app, and attribute them to specific campaigns/media-sources. Please take the time define the event/s you want to measure to allow you to track ROI (Return on Investment) and LTV (Lifetime Value). Kindly see the list of predefined event names and event parameters.

  • Event Name - The event name, this is presented in your dashboard.


  • Add Event Parameter - Add a tracking parameter to an event.

  • Parameter Name - The parameter name.

  • Parameter Value - The parameter value.

  • Event Name - The event name where this parameter will be added into the next "Track Event" action.


  • Remove Event Parameter - Remove a parameter from an event.

  • Parameter Name - The name of the parameter to remove.

  • Event Name - The event name where this parameter will be removed from the next "Track Event" action.


  • Clear Event Parameters - Clear all the parameters of an event.

  • Event Name - The event name where all the parameters will be removed.


  • Track Event (JS) - Send in-app events to AppsFlyer analytics. This is similar to the Track Event action, but with Construct 3's JS Scripting support. You can declare here the event parameters using JavaScript or JSON.

  • Event Name - The event name, this is presented in your dashboard.

  • Parameter JS - The parameters in JSON string. [For the Scripting Feature.]


General

  • Initialize - Initialize the Mobile AppsFlyer SDK.

  • DevKey - The AppsFlyer Dev key.

  • AppID - The Apple Application ID (for iOS only).

  • Debug Mode - If checked, the Mobile AppsFlyer SDK will enter debug mode.

  • On Install Conversion Data Listener - Accessing AppsFlyer Attribution / Conversion Data from the SDK (Deferred Deeplinking).

  • Wait for ATTUserAuthorization - The time for the SDK to wait before launch, IOS 14 only!



  • Set Currency - Set the currency in ISO4217 Currency Code. For example: 'USD', 'GBP' or 'PHP'.\

  • Currency Code - Currency in ISO4217. For example: 'USD', 'GBP' or 'PHP'.


  • Set Sharing Filter - Used by advertisers to exclude specified networks/integrated partners from getting data. Learn more here.

  • Partners - Partners separated by comma. Example: "facebook_int,googleadwords_int,snapchat_int,doubleclick_int".


  • Set Sharing Filter To All Partners - Used by advertisers to exclude all networks/integrated partners from getting data. Learn more here.

Tools

  • Set Device Tracking - AppsFlyer provides you a method to opt‐out specific users from AppsFlyer analytics. Mobile AppsFlyer provides you a method to opt-out specific users from AppsFlyer Analytics. This method complies with the latest privacy requirements and complies with Facebook data and privacy policies.

  • Tracking - Default is checked, meaning tracking is enabled by default.


  • Set Tracking - In some extreme cases you might want to shut down all SDK tracking due to legal and privacy compliance. If "False", the SDK will no longer communicate with the servers and stop functioning.

  • Tracking - Default is checked, meaning the SDK is enabled and functional.


  • Get AppsFlyer UID - Get AppsFlyer’s proprietary Device ID. The AppsFlyer Device ID is the main ID used by AppsFlyer in Reports and APIs.

  • Get SDK Version - Get the current SDK version.

​​

Cross Promotion

  • Track Cross Promotion - Call to track an impression. Make sure to use the promoted App ID as it appears within the AppsFlyer dashboard. For more details about Cross-Promotion tracking, kindly click here.

  • App ID - The promoted application id. For example: "com.myandroid.app".

  • Campaign - The promoted campaign.


  • Add Open Store Parameter - Add an additional parameter to the next "Track and Open Store" action.

  • Parameter Name - The name of the parameter.

  • Parameter Value - The value of the parameter.


  • Track and Open Store - Call to track the click and launch the app store's app page. Use this call to track the click and launch the app store's app page (via the Mobile Browser).

  • App ID - The promoted application id. For example: "com.myandroid.app".

  • Campaign - The promoted campaign.


  • Track and Open Store (JS) - Call to track the click and launch the app store's app page. Use this call to track the click and launch the app store's app page (via the Mobile Browser). This is similar to the Track and Open Store action, but with Construct 3's JS Scripting support. You can declare here the cross-promotion parameters using JavaScript or JSON.

  • App ID - The promoted application id. For example: "com.myandroid.app".

  • Campaign - The promoted campaign.

  • Parameter JS - The parameters in JSON string. [For the Scripting Feature.]​​

Conditions

The following condition groups:

  • General

  • Tools

press to zoom

press to zoom
1/1

General

  • On Initialize Success - Trigger fires if the initialization of the Mobile AppsFlyer SDK succeeded.

  • On Initialize Failure - Trigger fires if the initialization of the Mobile AppsFlyer SDK failed.


  • Is Initialized - Checks if the Mobile AppsFlyer SDK is fully initialized.

  • Is SDK Ready - Checks if the Mobile AppsFlyer SDK is ready to initialize.


Tools

  • On Get AppsFlyer UID - Trigger fires if the retrieval of the AppsFlyer UID is completed.

  • On Get SDK Version - Trigger fires if the retrieval of the SDK version is completed.

Expressions

press to zoom

press to zoom
1/1

The following expression groups:

  • General

  • Tools

General

  • Response - The response of any trigger, in JSON string.



Tools

  • GetAppsFlyerUID - Retrieve the AppsFlyer UID after the completion of the "Get AppsFlyer UID" action.

  • GetSDKVersion - Retrieve the AppsFlyer SDK version after the completion of the "Get SDK Version" action.

Object   Properties

Plugin Properties

press to zoom

press to zoom
1/1

The following property groups:

  • Configuration

Configuration - The object configuration section of the addon.

  • Debug Mode - Check to enable debug logs in the console.

 
 

Showcase