Overview
When ngrow.ai sends a push notification, it might send a server-side event (a callback) back to your analytics system. Ask your manager to set up callbacks if needed.
For instance, if your analytics system is Firebase, ngrow.ai can send events using Measurement Protocol, so you can see which users received what, right in Firebase.
Callbacks are sent for every push notification sent. The structure of the callback event is following:
{
"name": "ngrow_push_sent", # is fixed and unchangeable
"params": {
"holdout": holdout, # true if the user is in a control group (received silent push notification), false otherwise
"push_id": push_id, # id of the segment of the push notification
"hypo_id": hypo_id, # id of the message of the push notification
"title": title, # title of the push notification
"body": body, # body of the push notification
"locale": locale # locale of the push notification
}
}
Setup
To set up the audience building based on ngrow’s callback events in Firebase, you need to complete the following steps:
Ask your ngrow manager to start sending push notification callbacks.
Go to the Firebase Console, and choose a project you want to work with. In the left menu, than choose Analytics → Custom Definitions, and press the Create custom dimension button
In the appearing window, fill all the fields:
Dimension name: any descriptive name of the dimension (same as event parameter is recommended)
Scope: Event
Description: (optional) description of the dimension
Event parameter: holdout
Repeat the previous step for the following Event parameters: holdout, push_id, hypo_id. Optionally, you might also do that for the title, body, and locale.
🚨 Custom dimensions calculation works on a daily basis and does not apply retrospectively in Firebase. So, to build audiences, you need to wait at least a day for changes to take place.
Building an audience
Once you’ve set up Custom dimensions and waited a day for changes to take place, we might go to the audience-building step.
Here is an example of how to build an audience that received non-silent push notifications from ngrow at least once in the last 30 days:
Go to the Analytics → Audiences and hit the New audience button:
In the appeared window, hit the Create a custom audience button
Name your audience and press Add new condition drop-down button:
In the appeared window, press Events and find the ngrow_push_sent event:
After that, press the Add parameter button
And choose Custom → holdout
in the appeared window, choose Condition as exactly matches, and Value as false:
This is it!