RAD Server Push Notifications

From RAD Studio
Jump to: navigation, search

Go Up to RAD Server (EMS)


RAD Server Push Notification messages are the easiest way to reach a great number of registered devices in the RAD Server Engine (EMS Server). Each RAD Server push client application that is installed in a device, registers a single RAD Server Installation in the RAD Server Engine (EMS Server).

Send RAD Server Push Notification messages to the registered devices in your RAD Server Engine (EMS Server) to easily inform your users.

Sending RAD Server Push Notification Messages

The RAD Server Engine (EMS Server) provides functionality for sending push notifications with custom messages to the registered devices in the RAD Server Engine (EMS Server).

Use the TBackendPush component to send or broadcast push notification messages.

Target Destination for RAD Server Push Messages

You can either broadcast your push message, send it to a channel with subscribed devices or only to a specific device.

Choose the destination devices of your RAD Server Push Notification messages.

RAD Server Push Message Payload

Use the TPushData types to specify the RAD Server push message payload and send this message to your registered devices. You can also create a JSON message with the following payload:

{
  "message":"EMS Push notification message"
}

Customizing RAD Server Push Message Payload

RAD Server allows you to customize your RAD Server Push messages depending on the type of destination device.

  • aps. Custom settings for a push notification message in an iOS device.
    • aps.alert. Body text message of the notification for an iOS device.
    • aps.badge. Number of the badge number displayed in the iOS application icon.
  • gcm. Custom settings for a push notification message in an Android device.
    • gcm.title. Title of the notification for an Android device.
    • gcm.message. Body text message of the notification for an Android device.


Note: If you customize the body text message, this text will be shown as text message of the received notification.
{  
   "message":"EMS Push notification message",
   "aps":{  
      "alert":"iOS Alert message",
      "badge":"45"
   },
   "gcm":{  
      "message":"GCM message",
      "title":"GCM title"
   }
}


Note: We recommend you to follow the payload structure for iOS devices as described in Apple Push Notification Service (APN) and for Android devices as described in Google Cloud Messaging (GCM).

RAD Server Engine Requirements to Send RAD Server Push Notifications

To send RAD Server Push notification messages to the registered devices in your RAD Server Engine (EMS Server), you need to install the OpenSLL libraries in the system where the RAD Server Engine runs.

Note: You need to install the 32-bit or 64-bit OpenSSL binary, depending on the target platform of the RAD Server Engine (EMS Server).

If you do not install the OpenSSL libraries and use the RAD Server Engine (EMS Server) to send push notification messages to your registered device, the RAD Server Engine (EMS Server) shows the following error exception in the RAD Server Engine Window log:

{"Error":{"Type":"Other","Exception":"EIdOSSLCouldNotLoadSSLLibrary","Message":"Could not load SSL library.","Thread":5576}}

Topics

The following topics help you to enable sending RAD Server Push notification messages to your registered devices.

See Also