This article will provide you with a guide on how to configure the App Push channel and integrate your app with Agillic. If you need more general information about the benefits of using the App Push channel and some concrete use cases you can read more about it here.
After the App Push channel has been configured you are ready to set up your first Push Notification.
Please note: The app SDK has been deprecated with the release of 23.0 in January 2023. This means that there is limited support of the SDK, and the feature will be completely removed in the future. Customers that are using the SDK are strongly advised to migrate to APIs as soon as possible. New customers should not adopt the SDK. Please reach out to your Agillic contact for further information.
Contents
- Integrating Your App with Agillic
- Register an App in Settings
- How App Data is Stored
- Sending Tokens to Agillic
- Configuring a Push Notification
- Testing the App
- Setting up a Flow with a Push Notification Step
- Feedback Data
- Reporting on the App
Integrating Your App with Agillic
When it comes to integrating your app, there are two actions are required:
- Register an App in settings
- Register devices to recipients in Agillic via an API.
Register an App in Settings
In order to successfully register an app you will need an account with a Push Notification provider. Currently Firebase and APNS are the supported Push Notification providers.
The App Push channel can be configured from settings in Agillic. You will need information from your App Developer in order to set it up.
- Navigate to Settings on Staging
- Click on App Push under Integrations
- Click Add an App
- Fill out the general app definition:
App name The name of your app. Needs to be the same name as you map in the SDK, if you use the SDK.
As an example could the app for Cafe Connect, a fictive company selling coffee both in stores and subscription based, be named ‘Cafe Connect Care Club’.
App description Describe your app (optional).
For the Cafe Connect app the description could be, 'App for our Care Club Member Cards'.
General App definition for the Company Cafe Connect
5. Fill out Firebase configuration to configure the Android app or leave all fields empty to skip the Android configuration:
Use Data Messages Firebase allows you to send two types of Push Notifications: notification messages which will be handled by the Firebase SDK and data messages which you will have to manage yourself. More details can be found in the Firebase documentation.
This feature allows you to toggle between the Firebase notification format and data format. Reach out to your App Developer to understand which format suits your use cases best.
Firebase package name Enter the Firebase Package name Service Account Enter the JSON containing the required keys. This has a fixed format with 8 required keys:
{"type": "",
"project_id":"",
"private_key_id":"",
"private_key":"",
"client_email":"",
"client_id":"",
"auth_uri":"",
"token_uri":"",
"auth_provider_x509_cert_url":"",
"client_x509_cert_url":""}
6. Fill out iOS configuration to configure the iOS app or leave all fields empty to skip the iOS configuration:
Application bundle ID Enter the Application bundle ID Team ID Enter the Team ID (usually 10 characters) Key ID Enter the Key ID (usually 10 characters) API Secret Enter the key for API Secret which should begin with —--BEGIN PRIVATE KEY—-- and end with —--END PRIVATE KEY—-- 7. Click Add
8. The app will be stated as ‘Verified’ within Firebase and/or APNS if the configuration is set up correctly. If it is instead stated as ‘Not verified’ it means that there is a misconfiguration in your setup which you need to investigate with your App Developer. In order to see the specific verification error simply just click on ‘Not verified’ and forward this error to your app team. The number of ‘Tokens’ refers to the number of apps registered. When hovering over the number of ‘Tokens’ a timestamp will show when the latest app was registered.
Verified and Not verified apps
How App Data is Stored
When the App Push channel has been enabled within Settings, the system will create a technical One-to-Many table which holds all the registration details for the app per recipient. The table is called AGILLIC_REGISTRATION and you will use this One-to-Many table in order to create Target Group conditions to find all recipients who have an app installed, for example. This table should not be edited. The fields in the table are:
AGILLIC_REGISTRATION One-to-Many Description Example APP_INSTALLATION_ID STRING An identifier for the login on the device 68b344b0-55dc-4ecf-b240-7f808dba34d4 CLIENT_APP_ID STRING Unique string defined by the developer com.cafeconnect.app CLIENT_APP_VERSION STRING The version of the client app ID 1.0 COUNT_REGISTER NUMBER Number of Registrations done by the client 1 DEVICE_MODEL STRING Name of the device Android SDK built for x86_64 FIRST_REGISTER TIMESTAMP The timestamp of the first register 12.10.2021 15:11:34 LAST_REGISTER TIMESTAMP The timestamp of the last register 12.10.2021 15:11:34 MODEL_DIM_X NUMBER Width of the device screen in pixels 1794 MODEL_DIM_Y NUMBER Height of the device screen in pixels 1080 OS_NAME STRING Defines which platform is used Android OS_VERSION STRING The version of the Operating System 10.0 PUSH_NOTIFICATION_TOKEN STRING Token for Firebase Cloud Messaging (FCM) or Apple Push Notification Service (APNS) fp0C7JLITCqUBq5JQ52DPZ:APA91b … Sending Tokens to Agillic
In order to send Push Notifications some information about the target device, specifically the Push Notification token, must be registered in Agillic. Agillic provides an API to capture the required information. See the Developers Portal for more information.
Configuring a Push Notification
When you have registered an app you are ready to configure your first Push Notification. Learn how to set up your Push Notification here.
Testing the App
We recommend testing your app when you have verified it and set up your Push Notification. Read about how to test here.
Setting up a flow with a Push Notification step
In order to send out the Push Notification you need to send it through a flow to your recipients. After you have created your flow you can insert a Push Notification step.
Inserting a Push Notification Step
When the Push Notification step has been inserted you are able to select ‘Use Push Notifications from the new App Push Editor’ in order to use Push Notifications created within App Push. Here you select ‘App name’ which refers to the app set up within Settings. Hereafter you select ‘Push Notifications’ which is the specific Push Notification created in the Channels module.
Configuring an Push Notification step
Feedback Data
Agillic provides APIs that allow you to send information to Agillic when your Push Notification was received on the targeted device and whether the recipient opened the Push Notification. These APIs can be integrated directly into your app or with your own back end solution or mobile tracking provider. Read more about our APIs here.
Feedback information is captured in the form of activity data which can be exported as described here. This data can also be used to build conditions for users who have opened or received a particular push.
Reporting on the App
There are different ways to report on your app and the Push Notifications sent.
In order to get a full log of activity data for the Push Notification data for all recipients within a given period of time you can create an Activity Export. You can use this Activity Export in order to do reporting on your Push Notifications sent from Agillic - either in a BI tool or in order to troubleshoot your setup.
Investigating a Recipient
If you need to find information regarding what specific Push Notification a specific recipient has received you can investigate the recipient. The different Result Codes and the description is described below.
Result Code Description In-App Notification successfully sent to push server The message has been successfully delivered to the recipient's app notifications. Not sent because no device registered The recipient has not registered within the App.