Skip to main content
Question

'enableAdServicesAttributionTokenCollection' but for Meta?

  • August 12, 2025
  • 9 replies
  • 124 views

harald-nordgren
Forum|alt.badge.img+1

Hi!

We have integrated Revenuecat with AppsFlyer for running ads on Apple Search Ads and Meta. The Apple Search Ads integrated is working, but we have some issue with getting attribution to work for Meta.

We are doing these calls:

    await Purchases.collectDeviceIdentifiers()
await Purchases.enableAdServicesAttributionTokenCollection()

...


if (appsFlyerConversionData) {
await Purchases.setMediaSource(
appsFlyerConversionData.data.media_source,
)
}

However, it seems that ‘enableAdServicesAttributionTokenCollection’ is only relevant for Apple. How do you collect similar data for Meta?

This post has been closed for comments

9 replies

chris_perriam
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • August 14, 2025

Hi ​@harald-nordgren, looking at your app, it appears that you have configured the integration between RevenueCat and AppsFlyer correctly. I can see the AppsFlyer ID, IDFV and IDFA being provided where available.

Could you please share some more detail what you’re expecting to see and how attribution isn’t working the way you expect? I’d be happy to take a closer look.


harald-nordgren
Forum|alt.badge.img+1

Hi ​@chris_perriam!

We recently set up an integration between AppsFlyer and Meta, and I’m expecting some users to get the media source set to Meta/Facebook Ads.

But despite Meta traffic, both on our iOS and Android apps, we can’t see a singlue user tagged with Meta/Facebook in our Revenue Cat charts. Here is a screenshot when segmenting by “Attribution source”:

 

 


chris_perriam
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • August 15, 2025

@harald-nordgren The attribution source won’t be automatically set here, but you can send this data back to RevenueCat as attributes. The “Attribution Source” attribute is keyed as $mediaSource.

Here’s the relevant passage from our AppsFlyer integration docs:

RevenueCat itself is not an attribution network, and can't determine which specific ad drove an install/conversion. However, if you're able to collect this information from another source, such as Appsflyer, it's possible to attach it to a Customer in RevenueCat using Attributes as well. The below reserved key names can be used to optionally attach campaign data to a user. This data will then be sent through to other downstream analytics integrations and accessible via APIs and webhooks.

Key
$mediaSource
$campaign
$adGroup
$ad
$keyword
$creative

harald-nordgren
Forum|alt.badge.img+1

@chris_perriam

We are setting the media source like this and it is working for Apple Search Ads. But for some reason nothing is being set for Meta ads:

  useEffect(() => {
const setAppsFlyerCampaignData = async () => {
if (appsFlyerConversionData) {
await Purchases.setMediaSource(
appsFlyerConversionData.data.media_source,
)
await Purchases.setCampaign(appsFlyerConversionData.data.campaign)
}
}

setAppsFlyerCampaignData().catch(logError)
}, [appsFlyerConversionData])

 


chris_perriam
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • August 15, 2025

@harald-nordgren I’d recommend trying the following:


harald-nordgren
Forum|alt.badge.img+1

@chris_perriam Is it possible on your side to check if there are any ‘appsFlyer.onInstallConversionData’ events for our accounts where media source is Meta?


chris_perriam
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • August 21, 2025

@harald-nordgren happy to look into this, but I’m not sure that appsFlyer.onInstallConversionData necessarily involves RevenueCat. That might be related to the AppsFlyer SDK itself. Could you please clarify what you mean there?

 

In case it’s helpful, here’s how you can configure a Customer List in RevenueCat to include only customers who have a $mediaSource attribute which is not “Apple Search Ads”. You can then export the full CSV of the customers in the list (and view additional attribute values).

 


harald-nordgren
Forum|alt.badge.img+1

I’m not sure that appsFlyer.onInstallConversionData necessarily involves RevenueCat. That might be related to the AppsFlyer SDK itself. Could you please clarify what you mean there?

 

@chris_perriam That’s a good point. But I’m staying in contract with AppsFlyer as well and trying to get a hold of Meta, but I keep bouncing around between providers without solving this.

 

In case it’s helpful, here’s how you can configure a Customer List in RevenueCat to include only customers who have a $mediaSource attribute which is not “Apple Search Ads”. You can then export the full CSV of the customers in the list (and view additional attribute values).

 

Thanks for this, this is illuminating and I didn’t realize that indeed we have 5 customers who have registered with media source “Facebook Ads”. Interestingly enough these 5 customers are all on iOS with ATT authorized. None of them paid or started a trial, so maybe that explains why the transaction charts segmented by “Attribution source” shows nothing for Facebook.

So it seems that enableAdServicesAttributionTokenCollection only handles attributions for ATT + iOS? Then the question becomes, how can I successfully set the “Attribution source” in other cases?


chris_perriam
RevenueCat Staff
Forum|alt.badge.img+6
  • RevenueCat Staff
  • August 27, 2025

@harald-nordgren enableAdServicesAttributionTokenCollection is only relevant for Apple Ads. Specifically, it fetches the AAAttribution.attributionToken() which is then shared to RevenueCat to process and update customer attributes with.

RevenueCat doesn’t automatically populate customer attributes with attribution sources for other networks, but this may be possible using one of our supported Attribution Providers