HomeAppVirality DocsTesting GuideTest your Referral

Test your Referral

It is expected that you have setup the Test Environment before proceeding to this step, and have taken into account all the recommendations cited in the documentation for test environment setup.

For the sake of clarity & context, below call-out is being repeated.

Referrer & Friend Devices

Here on, for the sake of better comprehension, let us treat/call the devices as:
device A = Referrer
device B = Friend

 

Let us now run a cycle to emulate the Referral Workflow for your ideal user.


STEP 1 Share the App from Referrer’s device

  • In Device A, i.e. Referrer’s device, open the App
  • Ensure you’ve logged in with a valid email ID (or whichever login credential prompted by the app).
    Remember that this Login ID is the primary index for all your user relevant searches on the Influencers tab under Analytics section.
  • Navigate to the Referral Screen, and share the app through any of the listed social channels (email, text, whatsapp, messenger, etc.) to Device B i.e. Friend’s device
Analytics Lookup

You shall see an increment in the Invites count for Device A, under the Influencer section in Analytics.
Navigate: Dashboard >> Analytics >> Influencer tab

Below steps will help you get there.

Referral Screen
Referral Screen
Analytics Lookup: Steps (Click to Expand)

 

 Step 2 Click on the Invitation Link

On Device B, click or act upon the Invitation Link sent from Device A.

This action should redirect you ultimately to the Play or App Store, prompting you to download the app.

 

Once you reach the app installation activity at the Store, please avoid installing/downloading the app from that page

Analytics Lookup

You shall see an increment in the Clicks count for Device A, under the Influencer section in Analytics. You should also see the Link Clicks getting attributed under the Device Info
Navigate: Dashboard >> Analytics >> Influencer tab

Below steps will help you get there.

App Referral Click
App Referral Click
Analytics Lookup: Steps (Click to Expand)

 

Step 3 Install Test App

Now install the Test App on Device B.

This new install is not attributed to the referrer yet. To do so, there are two possible ways depending upon the type of attribution setting configured for your app, which are either by using the Install Referrer Broadcast for Link based attribution or by submitting referral code for Referral Code based attribution. You can also use both of them if your app is configured for Link + Code attribution, so that referral code could be used for attribution in case the Link based attribution gets failed for some reason. Following is the detail for each type of attribution setting.

When the app is installed after clicking on the referral link, the Google Play Store would fire the Install Referrer broadcast for the app, sending the referrer data as part of the Intent extras’ with the broadcast, which will be received by the Broadcast Receiver inside AppVirality SDK and the referrer data would be sent to the server post SDK initialization.

To make AppVirality’s Broadcast Receiver receive the Install Referrer broadcast, you must declare it inside your app’s Android.Manifest.xml as shown here.

Now, in normal case when you will install the app from Google Play Store, it will fire Install Referrer broadcast but while testing your app you can simulate the same using the following ADB command for sending the broadcast.

Run the following in your Android Studio Terminal or Windows Command Prompt:

    
- adb shell am broadcast -a com.android.vending.INSTALL_REFERRER -n <your-package-name>/.<com.appvirality.AppViralityInstallReferrerReceiver> --es "referrer" "avclk=9480n-bigb175"

here:

avclk = 9480n-bigb175” is the parameter, where 9480n is the Click ID and bigb175 is the Referral Code.

Run the Referral Link, for example: http://r.appvirality.com/type117-1k1/14, in the browser.

You would be redirected to the app’s webpage, since you have accessed via the browser. Obviously, you’d now have a new URL in your browser. The tail at the end of the new URL would have the avclk parameter, which basically is the click ID.

Obtaining Avclk
Obtaining Avclk

Ideally, if you had configured the Welcome Screen – it should appear right here.
It is a good way to prod the user towards making the signing up activity.

This would look something like as shown in the image here.

 

If you have setup a referral campaign to be driven via a Referral Code, you would need to add the referrer’s Referral Code i.e. Device A‘s referral code right here.

Analytics Lookup

You shall see an increment in the Installs count for Device A, under the Influencer section in Analytics. There would also be additional insights under Friends’ List, Rewards, Events, etc.
Navigate: Dashboard >> Analytics >> Influencer tab

Below steps will help you get there.

Welcome Screen
Welcome Screen
Analytics Lookup: Steps (Click to Expand)

 

Step 4 Verify Sign-Up

The most common implementation process ensures that the Welcome Screen Call to Action initiates the Sign-up of the user. Nevertheless, since it is the very next in order & importance – Sign-up event verification is important now.

It is expected that you have setup the callbacks for the Sign-Up activity while integrating the app.

If your Campaign rules are designed to reward users (Referrer and/or Friend), then sending across the Conversion Event for a Sign-up is imperative. If you have missed it, then you shall not see rewards flowing to any of the users.

Analytics Lookup: Steps (Click to Expand)

 

Verify Transaction

To avoid being repetitive, there is no separate section for verifying Transaction event. It is best advised that all the steps undertaken in Step 4 above, be applied directly to Transaction event too.
Run a Transaction in the app, and check for all the same fields as done in Step 4 , while only changing the context from Sign-up to Transaction

 

Step 5 Uninstall, Reset & Rerun

Now, moving forward would imply running the same scenario against a wide range of variants, which implies the above referral flow must be validated across multiple devices – changing the stakeholders every time.

You should ideally come up with as many test runs as possible. Before you run the new cycle, here is what you must do:

  • Uninstall the app from the Friend device i.e. Device B, if you want to run the same device as Friend again.
  • Reset the device, as was shown earlier while setting up Test environment
    (navigate to Testing from Dashboard, Click on Reset against the Device you want)

    Reset a Test Device
    Reset a Test Device
  • Rerun the entire cycle for Referral Activity, beginning from Step 1 above

 

This completes one whole cycle of a Referral Activity


Now you may come up with multiple queries, doubts & questions – while doing the above activity…

Go ahead & check out the Basic Troubleshooting Guidelines (or Testing FAQs, as we term it)

Go To >> Testing FAQs

Was this article helpful to you? Yes No