Testing Legacy Acquisition

Instructions to help you roundtrip an legacy acquisition campaign link on an Android device.

Note: If the mobile app is not yet in Google Play, you can choose any mobile app as a destination when creating the campaign link. This will affect only which app the acquisition server redirects you to after clicking the acquisition link, but not the ability to test the acquisition link.

Query string parameters are passed to the Google Play store, which are then passed to the app upon install as part of a campaign broadcast. Roundtrip mobile app acquisition testing requires simulation of such a broadcast.

The app needs to be freshly installed (or data cleared in Settings) each time a test is run. This ensures that initial lifecycle metrics associated with the campaign query string parameters are sent when the app is first launched.

  1. Navigate to the Use Legacy Acquisition Links in Adobe Mobile Services and generate a legacy acquisition campaign URL.
  2. Connect the device to a computer, launch ADB Shell, then launch the application on the device.
  3. Send a broadcast using the following format:
    am broadcast -a com.android.vending.INSTALL_REFERRER -n com.example.adobetesttapp/com.
    google.analytics.tracking.android.CampaignTrackingReceiver --es "referrer" "utm_source=

    Replace com.example.adobetesttapp.com with your application's reverse DNS entry, update the receiver reference with that of the location of the campaign tracking receiver in your app, and replace values associated with utm_source, utm_medium, utm_term, utm_content, utm_campaign, etc. with appropriate values.

If the broadcast is successful, you can expect a response similar to the one below.

Broadcasting: Intent { act=com.android.vending.INSTALL_REFERRER cmp=com.example.analyticsecommtest/com.google.analytics.tracking.android.AnalyticsReceiver has extras) } Broadcast completed: result=0

You will also see an image request sent to Adobe's data collection servers. If the SDK waits for the full duration of the referrer timeout (as set in Step 1) with an image request that does not include campaign parameters, the broadcast failed.

Parent topic: Acquisition