Maximize Value of In-App Ad Impressions

App advertisers that monetize via in-app ads now have an easier way to find users that generate the highest value by engaging with ads in their apps, without any restriction on what mediation partner they use.

More details can be found here.

To be eligible to use this product, you will need to send your ad revenue data to Meta's AdImpression event using either the Facebook SDK, Conversions API for App Events, or your mobile measurement partner (MMP).

Note: To ensure optimal performance, please do not aggregate or filter the ad revenue impression data before sharing.

Option 1: Data Sharing Through the Facebook SDK

Follow steps 1, 2, and 3 outlined here to set up the Facebook SDK. See the Get Started with App Events (Android) documentation for further guidance.

  • Step 1: Configure your Facebook app (Requires Facebook developer account)
  • Step 2: Link your Facebook ad account with your app from the App Dashboard or your Business Manager
  • Step 3: Integrate the Facebook SDK in your Android app

Log in-app ad revenue as an AD_IMPRESSION event, as shown in the code sample here:

AppEventsLogger logger = AppEventsLogger.newLogger(this);
Bundle params = new Bundle();
params.putString(AppEventsConstants.EVENT_PARAM_CURRENCY, "USD");
logger.logEvent(AppEventsConstants.EVENT_NAME_AD_IMPRESSION,{Ad_Impression_Value},params);
  • Note: if you are using the Unity plug-in for the Facebook SDK, please use AdImpression as shown in the code sample below. This is based on the Unity Get Started guide.
var params = new Dictionary<string, object>();
params[AppEventParameterName.Currency] = "USD";
FB.LogAppEvent('AdImpression',{Ad_Impression_Value},params);

Option 2: Data Sharing Through the Conversions API

The Conversions API is part of Meta’s Marketing API, allowing advertisers to share event-level data with Meta for purposes including measurement, ads optimization, and targeting. The Conversions API is the primary server-side channel for sharing events that happen on websites, apps, physical stores, and other surfaces.

Initial Configuration

In order to call the Conversions API, you need the following: (1) a business account, (2) a dataset ID, and (3) an access token with sufficient permissions.

Please see the following resource for setting up a business account, which provides access to Business Manager and other tools like Events Manager. You likely already have done this in the past.

Please follow this guide to link your app to a dataset ID in Events Manager, configure parameters (which should mirror parameters on the App Events API), and send events. Please note that at least one customer information parameter needs to be provided -- anon_id or madid should be sent in most cases.

You can use the Payload Helper and Test Events to make sure your setup is working correctly.

Example:

curl -X POST \
  -F 'data=[
       {
         "event_name": "AdImpression",
         "event_time": 1692918768, // the time the IAA revenue is generated
         "user_data": {
      <any available match keys, including advertiser tracking ids>
         },
         "app_data": {
           "advertiser_tracking_enabled": "True",
           "application_tracking_enabled": "True",
           "extinfo": [
                    "a2",
                    "com.some.app",
                    "771",
                    "Version 7.7.1",
                    "10.1.1",
                    "OnePlus6",
                    "en_US",
                    "GMT-1",
                    "TMobile",
                    "1920",
                    "1080",
                    "2.00",
                    "2",
                    "128",
                    "8",
                    "USA/New York"
         "custom_data": {
           "value": 12345.67,
           "currency": USD,
         },
          "action_source": "app"
       }
     ]' \
  -F 'access_token=<ACCESS_TOKEN>' \
  https://graph.facebook.com/v17.0/<DATASET_ID>/events

Option 3: Data Sharing Through an MMP

Please follow guidance from AppsFlyer and Adjust, and Singular or reach out to your MMP’s point of contact, if you want to use their ad revenue forwarding options. For other mobile measurement partners, please reach out to them directly for support.