Using FBEvents activateApp on iOS, and phone markup is not published to Facebook Insights

I want to integrate FaceBook SDK into my application in order to track the installation of mobile applications using the "activateApp" method. ( integration referencePage ). I managed to get this working on Android, but only after discovering that you need to have the Facebook app installed and logged in to use it, try so that I canโ€™t get IOS to make the same call and register it on my page Facebook developer apps as the "latest mobile install." Here is the code I'm using: (The application identifier specified in the sample code is intentionally incorrect, the one I have in my running application is copy / paste the application identifier on the facebook application page)

- (void)applicationDidBecomeActive:(UIApplication *)application{ [FBSettings setDefaultAppID:@"123456789123456"]; [FBSettings setLoggingBehavior:[NSSet setWithObjects:FBLoggingBehaviorAppEvents, nil]]; [FBAppEvents activateApp];} 

After calling activeApp, I see this log statement in the console

 2013-08-19 08:50:45.776 MyApp[258:907] FBSDKLog: FBAppEvents: Recording event @ 1376920246: { "_eventName" = "fb_mobile_activate_app"; "_logTime" = 1376920246;} 

After I started the application again and opened it again, I see this in the console. I believe the SDK is querying the FB Developer App page.

 2013-08-19 11:16:57.667 MyApp[286:907] FBSDKLog: FBAppEvents Persist: Writing 1 events 2013-08-19 11:16:59.453 MyApp[286:907] FBSDKLog: FBAppEvents: Recording event @ 1376929019: { "_eventName" = "fb_mobile_activate_app"; "_logTime" = 1376929019; } 2013-08-19 11:16:59.455 MyApp[286:907] FBSDKLog: FBAppEvents Persist: Read 1 events 2013-08-19 11:16:59.457 MyApp[286:907] FBSDKLog: FBAppEvents Persist: Clearing 2013-08-19 11:16:59.651 MyApp[286:907] FBSDKLog: FBAppEvents: Flushed @ 1376929019, 2 events due to 'PersistedEvents' - { "advertiser_id" = "9534FA44-DDE9-40E6-B10F-DDBD174860B4"; "advertiser_tracking_enabled" = 1; "application_tracking_enabled" = 1; attribution = "2770A653-BE20-4679-B955-CDBF621D5B5C"; event = "CUSTOM_APP_EVENTS"; } Events: [ { "_eventName" : "fb_mobile_activate_app", "_logTime" : 1376929009 }, { "_eventName" : "fb_mobile_activate_app", "_logTime" : 1376929019 } ] Flush Result : Success 

I am sure that the SDK was imported correctly, and I also tried this script - it is the simplest standalone iOS application, and I still do not see any reaction on our Facebook page.

Let me know if any further information is helpful, and I can add it here.

Thanks in advance for your help!

+4
source share

Source: https://habr.com/ru/post/1497858/


All Articles