There are two key factors to having push notifications work:

  1. Configure notifications for the desired platform(s)
    Push notifications are configured on the Design | Notifications | Settings screen of the portal.  It is of course important that you enable notifications, and upload the proper certificates for your platform.  Click through to the tutorials for setting up the configuration for iOS and Android.

  2. Ensure that your app is registering device tokens
    The certificates that you configure in step 1 give brainCloud the permissions necessary to send notifications. But we still need the addresses of devices to send to – that’s where the device tokens come in.

    Each time your app starts, it should request the device token from the device it’s running on, and pass that to brainCloud using the RegisterPushNotificationDeviceToken() call.  brainCloud doesn’t automatically retrieve the device token – so your app will have to make the appropriate call.  In Unity, you can use the NotificationServices class.

    Tip: You can quickly check to see if you’re sending the device tokens to brainCloud by going to Reporting | API Usage and seeing if RegisterPushNotificationDeviceToken is there.

To test notifications:

  1. Run the app on a device (necessary for the token registration to occur)

  2. Look up the appropriate user in Monitoring | User Monitoring

  3. Verify that you can see a token in the Device Tokens section of the User Monitoring | User Summary Screen.  It’s at the bottom of the page. If you don’t see the section, the user doesn’t have any device tokens (and go back to configuration step 2, above)

  4. Click [Send Notification] in the bottom right-hand corner of the page – type in a message – and then click [Send].

  5. Verify that the device receives the notification!

Your feedback is important to us. Please rate this response below. Thanks! 

Did this answer your question?