1. Make sure you are using Buildbox 2.3.3 or higher.
2. Go to appsflyer.com and click "Get Started"
3. Enter your account information and click "Continue"
4. They will send you an email so you can verify your account.
5. Go into your email inbox, open up the email from AppsFlyer, and then click "Confirm My Email"
6. This will take you back to the AppsFlyer website. Click "Add App"
7. You'll get a pop up to Add Your App. Enter in the correct information under "Select the app status", "Add your relevant store details", and "Set the Time Zone and Currency". Then click "Save".
8. Click the little blue arrow to reveal a dropdown menu. Then select Integrated Partners.
9. Type "Game Analytics" into the search bar and then click GameAnalytics highlighted in blue or click the blue Edit button. They do the same thing.
10. The GameAnalytics Configuration window will pop up. Don't worry about putting a campaign name and you can set the Click Attribution Lookback Window to however long you want (7 days is recommended) and enable it if you want by checking the Enable box. Next, you need to copy your game key from gameanalytics.com and paste it into the game_key text box. Look at the photos below to see where you can find your game key. If you have not set up a Game Analytics account then you can find information on setting that up in this document.
Once logged into your account, this is your Game Analytics Home screen. After adding your game, you can select the little gray gear to access the Game Settings.
Now you can copy your game key and paste it into the game_key text box on AppsFlyer.
After pasting in the game key, click on the next tab at the top labeled In App Events.
11. Click on Off to open up a drop down menu. Select "All in-app events (To enable: Re-targeting, optimization, PPE). Then paste in your game key into the gamekey text box.
This will allow you to add an SDK Event. Select "+ Click to add in app event mapping". Then choose to "Map all SDK events" and then check the box to "Send Value". Then click Save & Close.
12. Next we need to go to the AppsFlyer SDK Integration page.
Scroll down to 2. Quick Start. Select the "Static Framework" tab and click Download highlighted in blue. Or, you can download it here. Save this web page. You'll need it later.
13. Now it's time to export your game from Buildbox. Select iOS when exporting.
14. Open up your exported game folder and click BBPlayer.xcodeproj to open up your Xcode project.
15. Open the AppsFlyerLib.framework.zip file and drop it into your Xcode project above the BBPlayer folder.
16. Click on the AppDelegate.mm file. This should open up the file in the window on the right. Add this line of code near the top:
17. Next add in these lines of code inside the function "didFinishLaunchingWithOptions: (NSDictionary *)launchOptions"
[AppsFlyerTracker sharedTracker].appsFlyerDevKey = @"YOUR DEV KEY";
[AppsFlyerTracker sharedTracker].appleAppID = @"YOUR APP ID";
[AppsFlyerTracker sharedTracker].delegate = self;
[AppsFlyerTracker sharedTracker].isDebug = true;
This should give you an error. I will help you fix that error in the next step. Let's fix the error first and then I will tell you where you can find your Dev Key and your App ID in step 19.
18. Click on your AppDelegate.h file and add this line of code near the top:
Then add a comma after UIApplicationDelegate and type in AppsFlyerTrackerDelegate as shown below.
19. Now go back to your AppDelegate.mm and we will put in your Dev Key and your App ID. You can find your Dev Key and App ID by going back to your AppsFlyer My Apps Page, opening up the drop down menu again, and selecting App Settings.
20. Copy your Dev Key from the top of the page and paste it into your AppDelegate.mm file where it says "YOUR DEV KEY".
Then scroll down to the bottom of the App Settings page and copy your App ID and paste it into your AppDelegate.mm file where it says "YOUR APP ID".
21. Now add this line of code inside the "applicationDidBecomeActive" function:
// Track Installs, updates & sessions(app opens) (You must include this API to enable tracking)
[[AppsFlyerTracker sharedTracker] trackAppLaunch];
// your other code here.... }