Downstream Events on Android

Tracking on Android

Similarly to deep link tracking, a call to our servers must be made to track a downstream event. In order for a downstream event to be valid, it needs a short URL of the SuperLink that was clicked, and the app key associated with the app.

Prerequisite: Whether you have an Android, iOS, Windows, or any other device, if you want to track downstream events and have them available for viewing on the Yozio Dashboard, you must first register the event on the Yozio Console. Go the the Yozio Console > Settings > Downstream Events > Register Downstream Events. Enter the Name and Description and hit Register Downstream Event. Note that the length of the name can be no longer than 32 characters, cannot contain special characters, and will automatically be converted to lowercase. When tracking a custom event inside your app, the event name must match exactly with how it appears on the Downstream Event List (in the same screen where you register downstream events).

Additionally, you have the option of adding a numerical value to each downstream event (for example, the event payment can have a numerical value 22.99 attached).

On various Yozio Dashboards, we provide the stats of your downstream events. That is, we provide numbers for how many times your downstream event is fired when the user has opened the app through a Yozio SuperLink. You can also see a breakdown of these numbers using the Yozio Batch File export or get called anytime an event is tracked using the Yozio Real-Time Server Callback. You can also view how many of these events are associated with a New Install or a Deep Link via Yozio Deep Link Drill Down.

By default, we provide two pre-registered downstream events, signup and payment. We provide convenient function calls in the Yozio SDK that will track these events.

App Setup

For Android, call trackCustomEvent(Context context, String eventName, double value) any time the downstream event is fired. If your downstream event has no value, you can have any number be the value.

We’ve provided trackSignup(Context context) and trackPayment(Context context, double value) to track signups and payments respectively.

Note: We recommend placing this function after you know that the event has been fired, and somewhere where you know it will be fired. For example, do not place a signup event tracking call in the beginning of the “Signup” Activity onCreate. This will make it possible for anyone who enters that Activity to fire a signup event however many times they like. Do place it after the user has completed the signup and the Activity has sent data to your backend.

Hint: Knowing the exact steps in the user flow needed to trigger your downstream event tracking call makes it infinitely easier for you to find out if your downstream event tracking is working properly.