Track Referrals

Reward your players for referrals and grow your business

Introduction

One of the most effective ways to get new users is through user referrals. You can use Gameball referrals capabilities to encourage your users to invite their friends by offering rewards for successful referrals to both the referrer and the recipient.

Gameball referrals uses Firebase Dynamic Links in the background to generate players referral links and track referrals. Dynamic Links are smart URLs (deep links) that survive the app install process, so new referred users via referral links will be easily tracked when they open the app for the first time.

Gameball and its SDK provides hassle free integration to track referrals where you will only need to

  1. Provide your firebase info through Gameball dashboard to generate referral links to your players

  2. Invoke referral method with every new account creation through your app.

Your players will be able to get and share their referral link from Gameball Player Widget

Tracking referral requires Firebase and Firebase Dynamic Links SDKs installed into your app.

Integration Steps

To integrate and track referrals you need to perform two main steps

  1. Configure your Firebase dynamic links settings from your firebase console

  2. Configure Firebase on your App and Gameball account dashboard

  3. Invoke SDK Referral method within your App user registration flow

Integration Details

For dynamic links you can use react-native firebase package and follow the steps of dynamic links initialization. To get the initial link that is used to start the app, use:

 let initialLink = await firebase.links().getInitialLink();

If there is a link, extract the referrer code from the link and send it with the params of register player function:

GameballSDK.registerPlayer({
      playerUniqueId: playerUniqueId,
      deviceToken: pushToken,
      referrerCode: referrerCode,
      playerAttributes: {
        displayName: displayName,
        firstName: firstName,
        lastName: lastName,
        //other attributes
      },
    })

Last updated