The Mobile SDK allows you to push notifications to your customers with an iOS or Android application.
- Subscription – Have access to the marketing package and enable the App Push feature.
- Mobile SDK – Properly configure your Mobile SDK settings by navigating to Account Settings > Integrations > Mobile Apps.
Collect app push subscribers
Communicate with customers with app push notifications by collecting opt-in events. Similar to email opt-ins, a customer's consent determines your reachable audience through the channel. Notice how the opt-in consent varies by platform:
- iOS – Opt-in model. iOS devices only allow apps to send notifications to their users who have agreed to receive them.
- Android – Opt-out model. Android devices inform users that an app's permissions automatically allow push notifications. Users can opt-out if they do not want to receive them, but it is a manual process, reducing the number of people who will choose to do so.
Opting in to push notifications on iOS (left) and opting out of push notification on Android (right).
Confirm opt-in events
Customer opt-ins send an event to Optimizely Data Platform (ODP), confirming the customer's app push subscription and providing analytics and app push values. To see an example event, refer to the event inspector within your Optimizely Account. Look for the following values in the event inspector:
- Event Type = push
- Action = add_push_token
- User Agent Information (UA)
A token for iOS and/or Android appears on the customer profile once a customer opts-in as an icon next to the app's name. Click on the iOS or Android icons to see the token value for that customer.
Additionally, you can view the app push event in the activity feed of the customer profile.
Include in a campaign
After customers have opted-in to app push notifications, you can include app push touchpoints in your campaigns and send messages to customers.
Review app push audience
After creating or adding a segment to a campaign, review the reachable app push audience next to the Mobile icon.
You can reach a customer if you know their app push token value. When a customer opts out of the app push channel, the system removes the token from their customer profile and captures a Remove Token event. This behavior means you can segment based on push token attributes to specifically target app push customers or create a campaign that only uses app push messages.
Create app push touchpoint
After you have determined your campaign audience, you can create an app push touchpoint.
- Navigate to Campaigns.
- Select or create a One-Time or Behavioral campaign.
- Click on the Edit icon of a campaign touchpoint.
- If this is a new campaign or touchpoint, select the app push channel from the prompt. If this is an omnichannel campaign, check out this resource to add additional channels to an existing touchpoint.
- Go to Push Delivery > Deliver Push to and select the display name of your app. The platforms associated with the app will auto-populate with iOS Sandbox, iOS, or Android, depending on your integration. However, you can also manually disable individuals platforms.
- Review the following options:
- Add Variation – Allows the push notification to be A/B tested.
- Load Template – Use a previously created message as the basis for this touchpoint.
- Name – Determine how you will be able to identify your content within ODP.
- Variables – Add liquid or custom HTML to customize the push notification further. Please reach out to your Customer Success Manager (CSM) if you need assistance.
- Input the message you would like customers to receive in the text area. The message should be no longer than 40 characters.
- Review additional options if necessary by clicking iOS Options or Android Options.
- Alert Title – The headline used to display the alert. This is the minimum recommended option, and we also recommend a dictionary. If you specify a string, the alert displays your string as the body text—for example, title, subtitle, launch image, and so on.
- Key/Value Pairs – Specific values called in your application if you have a dictionary. Please reach out to your developer to understand your options.
- Custom Sound – The name of a sound file in your app’s main bundle or the library/sounds folder of your app’s container directory. Specify the string "default" to play the system sound. Use this key for regular notifications.
- Badge Number – The number to display in a badge on your app’s icon. If there are any badges currently, specify 0 to remove them.
- Mutable Content – A notification to your notification service app extension before delivery.
- Launch Image – The name of the launch image file you would like to display when the user launches your app.
- Action Loc-key – The key to a localized action. Please reach out to your developer to understand your options.
- Loc-key – The key for a localized message string. Use this key, instead of the body key, to retrieve the message text from your app's Localizable.strings file. The value must contain the name of a key in your strings file.
- Loc-args – An array of strings containing replacement values for variables in your message text.
- Title Loc-key – The key for a localized title string.
- Title Loc-args – An array of strings containing replacement values for variables in your title string.
For more information on these options and iOS app development, check out this article.
- Key/Value Pairs – Call specific values in your application if you have a dictionary. We recommend a title and associated title value with the body of your message. Please reach out to your developer to understand your options.
For more information on these options and Android app development, check out this article.
- Preview and test your touchpoint. Preview allows you to review the touchpoint on-screen, while Test allows you to send a test through the touchpoint channel instead. Both options are available when viewing a touchpoint within the editor.
- Select the campaign's name from the breadcrumb menu, then click Save.
- Click Go Live when the campaign is customer-ready.
Review the performance metrics associated with an app push touchpoint.
- Navigate to Campaigns.
- Click the campaign containing the desired touchpoint.
- Click the Eye icon to expand the performance metrics view for the touchpoint with the app push. Review each metric in more detail here.