▪️Push configurations
Follow the instruction to get details for the Push notifications from Firebase console
Log in and navigate to the console
Create a new project

4. In the new project navigate to “Project settings”

5. In the General tab, create a new Web App and copy the content of the "Config" section


6. Navigate to “Service accounts” and generate a new private key

7. Download the file with the private key
8. Provide the Config file content from step 5 and the private key from step 7 to Smartico support personnel. You can also place them yourself in the Label settings in Smartico BackOffice; there are 2 settings to place (in JSON format):
a) Firebase web app config for push notifications - configuration from step 5
b) Firebase / Huawei server keys for push notifications - configuration from step 7.

The "server configuration" has the following form:
There are additional keys that you can place in the configuration to control parameters of the push messages; an example of the structure:
apns_default_sound
true
Plays the system default alert sound when the notification is received on iOS. When set to false, the notification appears without sound.
ttl
86400
When a web push notification is sent, it remains in the user's notification tray for a certain period. If a TTL of 86400 seconds is configured (one day), the notification would automatically expire and disappear after a day.
Huawei phones (HMS Push Kit)
Huawei phones without Google services cannot receive Firebase pushes. Smartico sends pushes to them through Huawei Push Kit (HMS), from the same campaigns and Push assets.
In Huawei AppGallery Connect, open your project and turn on Push Kit for your app.
Open Project settings → General information. In the App information area, copy the Client ID and the Client secret of your app.
Add a Huawei entry to the Firebase / Huawei server keys for push notifications setting in Label settings (or send the Client ID and Client secret to Smartico support personnel).
Ask your Success Manager to turn on the Show Huawei fields in Push assets setting. While it is off, Smartico does not send pushes to Huawei phones.
Make your app register its Huawei push tokens with platform
12, as described in Registering tokens for push notifications over API.
If your label sends pushes only to Huawei apps, the whole setting can be the Huawei entry:
If your label also sends Firebase pushes, give each entry its own key, and put the Firebase private key JSON from step 7 under default:
The app must send this key as app_package_id when it registers a Huawei token. The key does not have to be the real package name of the app; it only has to match. If no key matches, Smartico uses the default entry, and a push to a Huawei token fails when that entry is a Firebase key. One key cannot hold both a Firebase and a Huawei entry.
gateway-type
harmony_v1
Required. Marks the entry as Huawei Push Kit. gateway_type also works. Without it, pushes to Huawei phones fail.
client_id
your_client_id
Required. The Client ID from AppGallery Connect.
client_secret
your_client_secret
Required. The Client secret from AppGallery Connect. Keep it secret.
ttl
86400
Optional. How long, in seconds, Huawei keeps the push while the phone is offline. The maximum is 15 days (1296000); a bigger value is ignored.
default_sound
true
Optional. true plays the phone's default notification sound.
Huawei pushes show the title, the message and the attached image of the Push asset (the image link must start with https://). Buttons, the icon and the badge image are not used. What happens when the player taps the push is set by the Huawei action type and Huawei deep link or URL fields of the Push asset; see Push notifications.
Last updated
Was this helpful?