Setting Up the Messaging Service

From RAD Studio
Jump to: navigation, search

Go Up to Push Notifications

You can send Remote Notifications to your Android or iOS devices from one of the cloud service providers available (Kinvey or Parse) or from the backend service RAD Server.

To allow your applications to receive Remote Notifications, you need:

  • For Android apps, a new project on Google Developer Console.
  • For iOS apps, a new App-ID on Apple Developer Program.

Use the following steps to set up the messaging service for Android and iOS apps.

Registering with Google

  1. Go to Google Developer Console
  2. Click the drop-down list labeled as Select a project, choose Create a project and define a name for your project:

    Once you create a project, you can access the settings information of this project. To this end, click the drop-down list next to Google APIs logo and select IAM & Admin. Choose a project from the combobox and click Settings to find the Project name, the Project ID and the Project number.
    You will need the Project number to configure the TEMSProvider (see step 3 on section Design and Set Up the User Interface from page Multi-Device Application to Receive Push Notifications).
  3. Click Google APIs, search the Google Cloud Messaging API and click the Enable button.
  4. Once it is enabled, click the Go to Credentials button. Choose Android from the combo box and click What Credentials do I need?.
  5. Name your API Key and click Create API Key.
    Now, you have created the API Key. You will need the API Key for configuring the RAD Server Google Cloud Messaging settings on the EMSServer.ini file.

Registering with Apple

Note: You need to be a team agent or admin to perform the following tasks on Apple Developer Program.

Creating iOS App ID on Apple Developer Program

  1. Go to iOS Developer Program > Certificates, Identifiers & Profile > Identifiers > APP ID page.

  2. Press the + button at top right to define a new App ID. Fill App Name, App ID Prefix, App ID Suffix. Also, select Push Notifications in the App Services section:

  3. Click Continue, and then press Submit to confirm your App ID:
    Now your app is registered.

Creating a Certificate for your App

  1. On Certificates, Identifiers & Profile Apple page select your app and click Edit:
  2. Select Create Certificate in the Development SSL Certificate section:

  3. In the About Creating a Certificate Signing Request (CSR) page, select Continue.
  4. On the Mac, select Keychain Access > Certificate Assistant > Request a Certificate from a Certificate Authority…
  5. On the Certificate Assistant page:
    • Enter your e-mail address and your name.
    • Select the Save to disk option.
    • Press Continue:
  6. Specify a file name and save. Now you have a CSR saved as a file.
  7. On the Apple Developer Program web page, specify a CSR:
  8. Press Generate, and you will get a Certificate. Download the certificate, and install it on your system.
  9. Now you have a certificate installed on your system:

Creating a Provisioning Profile

  1. On the iOS Provisioning Profiles page, select + at the top right:

  2. On the Add iOS Provisioning Profile page:
    • Select iOS App Development as type of the profile. Press Continue:

    • Select the App ID that you created in the previous step:

  3. Select the list of people who can use this profile, and click Continue.
  4. Select the list of devices for this profile, and click Continue.
  5. Specify a name for the profile, and click Generate:

  6. Download your profile:

  7. Double-click the profile, and you should now see it as a new profile in Xcode on your Mac:

Exporting the .p12 Certificate

  1. In Keychain Access on the Mac, select the certificate, right-click it and choose Export.

  2. Define a name and click Save.

    Note: You can only choose a password if you use Kinvey or RAD Server as the service provider.

See Also