Push notifications API

[ BETA FEATURE ]

Send highly personalized push notifications to your app users based on usage, behavior, and user experience.

  • Engage with your most active or loyal users and reward them.
  • Enhance your support by sending personalized notifications to users that reported or experienced issues or bugs.
  • Connect with beta testers directly based on their interaction and behavior.
  • Improve retention by targeting slipping away users to re-engage them.
  • Give your users the guidance they need exactly when they need it.

📘

Please note that these notifications are different from in-app notifications, while the in-app notifications are seen within the app ecosystem (only when the app is open), UXCam push notifications are seen outside and when the app is in the background.


Dashboard Implementation

Based on the type of platform you wish to use, you need to configure the following:

Android - Firebase Cloud Message (FCM) server key

You can create the FCM key inside the cloud messaging in the Firebase project settings. For more information on how to get the FCM key, please visit the Firebase documentation.



Your FCM server key is inside your project settings in FirebaseYour FCM server key is inside your project settings in Firebase

Your FCM server key is inside your project settings in Firebase



Once you have created the key, simply copy and paste the server key token inside the “Push notification config”.

iOS - Apple Push Notification (APN) certificate

You can create the APN certificate inside the “Certificates, Identifier and Profiles” inside the apple developer center (developer.apple.com). You can either create Sandbox or a Production certificate based on what type of application you are using. Once you have created the certificate, download it first from the developer center and then upload it inside the “Push notification config”.

🚧

Important

At the moment .cer files are not acceptable based on Apple's requirements so you would need to generate a .p12 file in order to upload the certificate.

To review on how to create a certificate allowed by UXCam, please check the following link


API Implementation:

📘

Note: Make sure that your application is set up to receive remote push notifications.

Once you've configured the key/certificate in your dashboard, you must then use our push notification API, which is a single line of code that will get the device's token and send it to UXCam, allowing you to send notifications to specific users:

UXCam.setPushNotificationToken(_ pushToken: String?)

//Example - Add this to didRegisterForRemoteNotificationsWithDeviceToken
let token = deviceToken.map { String(format: "%02.2hhx", $0) }.joined()
UXCam.setPushNotificationToken(token)
UXCam.setPushNotificationToken(String pushToken);
UXCam.setPushNotificationToken: (pushToken: string) => void
UXCam.setPushNotificationToken: (pushToken: string) => void
void setPushNotificationToken(String pushToken)

📘

Device Token:

The API parameters are:
pushToken: Push notification device token.

The token you must send as a parameter in this method is the device's token, which you must fetch through your code and then send to the UXCam API.

🚧

iOS Information

Testing UXCam Push Notification API on iOS must be done outside a simulator, through a physical device, otherwise you won't be able to get the necessary token for the notification to work.

👍

You are all set!

Once you have done the configuration you are ready to send the push notification to your users. You can see how to do it here