Helpshift offers push notifications directly from Helpshift through APNS (For iOS) and FCM/GCM (for Android). If you have your own push servers and would prefer to use those to send push notifications, you can configure routing for those custom push notifications by completing the steps in this guide.

1. Configure custom push notifications in the Dashboard
2. Create a web service to handle custom push notifications
3. Create a push notification to APNS or FCM
4. Configuring a client for push notifications

1. Configure custom push notifications in the Dashboard

You can configure Helpshift to send the push notification message to a custom URL instead of through APNS (For iOS) and FCM/GCM (for Android). The first step to do so is for an Admin to set up a custom push notification.

To do so, navigate to the Settings > App Settings page, select the app you’d like to set up custom push notifications for, then scroll down to the push notifications section.

Change the option under ‘Select push notification server’ to ‘Custom push notifications’.

Click on the ‘[platform] push notifications’ toggle to enable it.

You’ll be prompted to select the following:

  • Authentication method: Select the method required by the web services that will receive the Webhook (Non, basic auth, or custom auth)
  • Target URL: This is the URL of the service that will process the custom push notification
  • Notification delivery email: This is where notifications will be sent in the event that the push notification fails to be delivered

Remember that this is the same process you use for creating HTTP Webhooks, so the settings should be similar.

Once this is configured, any time a push notification is sent, a Webhook will be generated and sent to the URL.

2. Create a web service to handle custom push notifications

You will need to have a web service that can capture the Webhook sent from Helpshift and that can create a custom push notification to APNS (for IOS) or FCM/GCM (for Android).

Helpshift will send a standard HTTP request to the Target URL provided when you enabled custom push notifications. This request will include the following properties as a JSON object that can be used to generate the client notification.

  • Platforms: (Indicates Android or IOS)
  • Payload:
    • description: (Message from Agent)
    • message: (Name of app)
    • data
      • origin: Helpshift
      • issue_id: (GUID of issue)
  • Audience:
    • userid: (User token used for push notifications)
  • endTime: (Time of event)

The service should take these properties and generate a unique push notification.

3. Create a push notification to APNS or FCM

Once the custom push Webhook has been captured by the web service, it will need to create a push notification to either APNS (for IOS) or FCM/GCM (for Android). Please refer to the following documentation by Apple and Google on how to create push notifications:

Targeting specific devices for push notices:

As part of the push notification, the service will need to be able to identify what device to send the notification to. This is done via the user token that is provided through the (userid) property in the custom push notification from Helpshift.

When a client loads Helpshift onto a mobile device and configures the Helpshift push notification, the client will share their token with Helpshift. This token is then provided in each custom push notification, so that the notification can be sent to the correct device.

Using the Helpshift schema for push notifications:

If you use the following schema when creating the push notification, then Helpshift can also process push notifications as they are passed to each device. To process push notifications, clients must be using the handlePush API in the SDK along with the following schema.


{
"origin" : "helpshift",
"issue_id" : ,
"alert" :
}

Note: and is provided in the custom push notification.

4. Configuring a client for push notifications

In order for a client to receive push notifications, the application that is running Helpshift must initialize the push notification by registering the user token with Helpshift, then configure how to handle the push notifications in the service. This process is outlined in our developer documentation: