Facebook Analytics SDK for iOS app: how to disable value tracking for non-valuable events like App Install or Start Trial? - ios

I'm running Facebook Ads campaigns for my iOS app and quite naturally I have Facebook Analytics SDK integrated inside my app to track App Installs and Start Trial events to measure the "quality" of the traffic my campaigns bring.
At the Analytics settings page inside Facebook developer dashboard.
https://developers.facebook.com/apps/XXX_APP_ID_XXX/analytics/settings/?business_id=XXX_BUSINESS_ID_XXX
I have the option Log In-App Events Automatically (Recommended) set to "Yes", which I presume enables the tracking of App Install and Start Trial events. There's also a Shared App Secret field filled in with the value from iTunesConnect.
Indeed, the App Install and Start Trial events have started to appear inside Analytics dashboard
https://www.facebook.com/analytics/XXX_APP_ID_XXX/AppEvents?__aref_src=landing_page&__aref_id=entity_name&force_desktop=1&user_id=XXX_USER_ID_XXX
However I noticed when viewing the stats for just App Installs there's a quite considerable value in USD attributed to these events. I decided to take a closer look into these events using Event Debugging
https://www.facebook.com/analytics/XXX_APP_ID_XXX/most_recent?since=1577923200000&until=1580256000000&__aref_src=landing_page&__aref_id=entity_name&force_desktop=1&user_id=XXX_USER_ID_XXX
and selecting "App Install" in the events filter.
There I saw that some (only some and as if randomly) App Installs have a value associated with them. To me this is an unexpected behavior since I can't imagine revenue being made by just receiving an install.
Same goes for Start Trial event, which always has the value associated to it (equal to the sale price of a subscription period) and once again this makes no sense to me because started trials themselves bring no value to me. They may be canceled or may end up in Billing Retry when the user has no money on the bank card attached to their iTunes account, etc. I track the conversions from Start Trial to Purchase on my backend separately with great precision and only these conversions as well as subsequent renewals would bring real value to my business.
I can and will track these Purchases manually and post them to Facebook (server-to-server style) and I will supply the corresponding value to these events myself, which will help to understand the overall performance and ROI but I need to clean my stats from these "false" automatically and erroneously attributed values to App Install and Start Trial events first.
I've already reported this issue to Facebook few days ago, however they seem to be slow in handling such requests so I've decided to ask here if anybody ran into similar issue.

Add this to your plist file to disable Auto Event Logging
<key>FacebookAutoLogAppEventsEnabled</key>
<false/>

Thanks to Lena Bru for giving enough food to find a solution.
The Facebook documentation is scarce on the raised questions and the support answer literally headed me towards the documentation. To recap things, there were 2 main issues (the second one I've mentioned in the comments to Lena's reply):
Facebook was tracking value for the events, which brought no value to my business
Some of the events I've sent from backend didn't appear in the campaign reports
To solve both of these problems, I:
Turned off the value tracking option in the Facebook app settings
On the client side I've started setting up User ID (which the client receives from backend) according to Facebook documentation
I've started to send all of the events, which I wanted to view inside Facebook business cabinet, under custom names from backend. I've supplemented them with app_user_id parameter (see Advanced Matching for App Events in Facebook documentation) so that they could match the App Installs reported from client.
There's still a smaller issue left (it feels like Facebook reports include 20% less installs than actually happening) but the current setup is already something to begin with.

Related

What are the default Apple URL schemes for the default apple apps?

I am trying to track down these URLs because I would like to integrate them with the Shortcuts (previously workflow) app. My end game is to make queries that will perform certain functions that I can call from a google home device. In simpler terms, I want to make google home more "Apple friendly."
I have not found anything that is too current out there on the URL schemes. I saw that sending a SMS message was triggered with sms://<PhoneNumber> , but I am not sure how up to date that information is.
I plan on adding features to search Apple Music (by triggering a workflow). I am also planning on adding text message features.
I am also looking into making an app for google home, but I still am in the learning stage with that. Any advice on making google home more Apple friendly would be greatly appreciated.
This is a constantly changing list given the number of features being added or third-party apps. Here's a list that does a good job of staying up-to-date: https://ios.gadgethacks.com/news/always-updated-list-ios-app-url-scheme-names-0184033/

Facebook pixel event PURCHASE not registering iOS-sales

We have an Woocommerce site and run ads on Facebook and Instagram. When potential customers click on these ads our website is loaded in the in-app browser that Facebook and Instagram uses. What we've discovered is that the Facebook pixel is not sending any purchase data back to Facebook regarding users on iOS. This again means that it's registered as 0 conversions in iPhone and iPad, skewing the audience and algorithms for optimised ad delivery. (The data comes back correctly on Android and computers.)
We've tried several plugins to see if it's plugin related issue, among them Facebook for Woocommerce, Pixel Caffeine and PixelYourSite. No change there.
What is also interesting, is that the metrics for iOS dropped to zero at the same time I switched from another theme to the Divi-theme (which is a page-builder theme for Wordpress). So it may seem like the error is directly related to the theme, but then again there must be something iOS-specific since it works on all other devices, and the theme change though suspicious may be irrelevant.
TLDR: The pixel tracking works exactly like they should on all devices except on iOS in-app browser where the website is displayed as it should be, but where the pixel is not registering purchases.
Edit: We receive other pixel data from iOS as well, it seems that the order confirmation page is the one that is "blocked".
Example of landing page we use for our ads: https://www.friskforlag.no/frisk-graviditet/
Received help from Elegant Themes, developers of the Divi theme. There is a bug in the current version of Divi that will be fixed in the next 2-3 versions. The solution was to comment out a line of code in the core > functions.php file, and after that we were able to track purchases on iOS again.

Tracking affiliate generated app installs in iOS greater than 24 hours

I'm trying to run an affiliate project for my app and Apple's 24 hour cutoff makes it a bit difficult. I'm wondering whether there is a way to implement one's own tracking?
I first was thinking a landing page with a phone number input form. Upon submission we'd use something like Twillio to send the user the app store link via SMS and also store the phone number together with the affiliates code from the landing page URL. I then saw that Google somehow let's you track adwords in relation to app installs and thought that perhaps there might be a way that doesn't involve this phone number indirection... Anyone know how they do it?
To be or not to be
The main question here is nature of your intention.
It reasons necessary accuracy / limitations you have on iOS. I see two variants.
100% Accuracy
If you need 100% accuracy, you can use SFSafariViewController - it's view is rendered by another process and it has shareable cookies between your app and Safari. It's iOS 9+ only 100% way to attribute installs. Also you can go with explicit attribution (email, phone number etc.) requested from user after app install. It might be needed if business model relies on this process (like each install is paid out to user account etc.)
You can get an idea and do implementation following this link
<100% Accuracy
If you want to provide greatest UX possible (but it's not critical) or gather analytics (but it allows some kind of deviation) you can go with some approximation techniques, like gathering IP addresses, location etc from requests to your affilate link. The flow can be following:
Your landing page contains dynamically generated link
Upon clicking on link, user metadata is stored (ip, location, device info - whatever can be grabbed from User-Agent or another info available to your web service)
User is redirected to App Store
Upon install and run, app queries your service with device info and ip.
Your web service now decides on attribution. Matching algorithm can include any necessary amount of variables / conditions. Like "Same IP + Device Type + No more than 5 minutes since clicking the link".
This way you don't request any user info (email, phone number) but you're already able to track attribution. Correctness percent is subject to tuning.
Edit #1
This approach might be helpful to you, it's used to attribute login, however you can use modified for analytics.
Edit #2
If you're really wondering, how AdWords does this, you might be interested in install tracking step-by-step guide. It's explicitly stated (section "Instructions for tracking iOS app installs (first open)", p.14) that you should either use AdWords tracking code (this tutorial describes how) or setup server-server integration. So, going back to original questions:
..there might be a way that doesn't involve this phone number indirection?
Yes
Anyone know how they do it?
There are lots of techniques (as well as measurement pixel built on top of mentioned above SFSafariViewController), described in these docs:
Google SDK,
3d-party SDKs

Apple review team has rejected app because it can't connect to ASP.NET API

I run my own VPS in Amsterdam where I have a MySQL database that is being populated and maintained using ASP.NET. It's a Windows Server.
I use this API for four of my existing Android apps (published and working) with a few thousand users who never had any issues connecting to the API through those apps. Recently I finished one of the apps on the iOS platform and it got rejected because Apple couldn't get it to load any content, or it would get stuck on loading without ever returning anything (after we implemented a loading progress animation). After a lot of messaging between me and Apple's review team, they ended up accepting my app to be passed through review even though they never got it to work (or so I believe, they just said they would re-review it and it suddenly got approved after 7 rejects). None of my friends, family or users ever experienced any issues like this on either Android or iOS.
A good friend of mine who did most of the work on the API is also from the USA, which makes me doubt it's a location problem.
I must note that pretty much 99.99% of my users are Dutch and all my projects are build for Dutch users.
Does anyone have experience or ideas in this field? I'm about to publish an update for the already published app and I'm afraid they will reject it because of the same issue.
The exact message I got at first was:
Specifically, upon launch we found that the app failed to load any content.
Changing the API calls to be over HTTPS seems to have fixed the issue, Apple now has access to my API through all my apps.

Google Analytics for iOS 1-time (per user) event tracking

I am using Google Analytics iOS SDK (version 2 but will upgrade if it solves problem). How can I track what percentage of my app users have pressed a certain button at least once? I set up a lot of event tracking, thinking this would do it, but the reports are in terms of sessions not users. E.g., it will show what percentage of sessions included an event, so a single user may be counted multiple times. I defined a custom dimension variable that is unique for each app install, but I don't see how to use that as aggregation unit.
All I can think of is to define my own "one time events" by keeping my own database on the device and only pass to Google Analytics the first time it occurs. Is there no better way?
Google Analytics now offers User segment. You could create a user segment, and use the particular event you're interested in as a condition.
In the context of app measurement, a User is defined as a unique Client ID, which is the random ID generated by the GA SDK when the application first runs. It remains stable for as long as an app is installed.
More details here: http://analytics.blogspot.com/2013/07/re-imagining-segmentation-in-analytics.html

Resources