iOS:如何跟踪 firebase 动态 link

iOS: How to track firebase dynamic link

我已经使用 FIRDynamicLinkGoogleAnalyticsParameters 添加了 UTM 参数

FIRDynamicLinkGoogleAnalyticsParameters *analyticsParams =
  [FIRDynamicLinkGoogleAnalyticsParameters parametersWithSource:Source
                                                         medium:Medium
                                                       campaign:Campaign];
  analyticsParams.term = Term;
  analyticsParams.content = Content;
  components.analyticsParameters = analyticsParams;

现在我想像这样跟踪动态link,

如果我在 Facebook 上分享过,任何人点击它 link 然后它将转到应用程序,否则它将转到 App Store。

在我需要根据消息来源显示消息后,即来自 Facebook 的欢迎消息。

那么我们可以跟踪动态 link 并检查 link 被点击的位置,并根据我的来源显示相关消息。

谁能解释一下如何实现这个: https://firebase.google.com/docs/dynamic-links/analytics

By adding these tracking parameters to your Dynamic Links, Google Analytics and iTunes Connect can treat them like any other campaign it's measuring attribution reporting for, and you can view conversion events not just by the ad campaigns responsible for bringing in those users, but also by which Dynamic Links might have brought them in.

The following parameters are passed to Google Analytics: utm_source, utm_medium, utm_campaign, utm_term, utm_content, gclid

The following parameters are passed to the App Store: at, ct, mt, pt

此线程中提出了相同的问题:

App link tracking with Firebase

我也在 Firebase GitHub 上发布了这个问题并得到了回复:

https://github.com/firebase/firebase-ios-sdk/issues/4775

You can't track where the link was tapped from unless you create a custom link (or add custom parameters) for each source, but even then this will result in mismatches if a user ever copies a link and shares it to a different source.