Last modified November 12, 2018 by Shelly Wolfe

Swrve Salesforce Journey Builder App

Build sophisticated mobile interactions inside Salesforce journeys with the Swrve Salesforce Journey Builder app for Salesforce Marketing Cloud.

Swrve Journey Builder App


Supported actions

Swrve delivers a powerful out-of-the-box API-to-API integration with Marketing Cloud.

From the Marketing Cloud journey, you can invoke Swrve-supported mobile engagement actions, including:

  • Trigger in-app message and Conversation campaigns.
  • Send push notifications with custom properties and custom deeplinks.
  • Send events from Marketing Cloud to Swrve.
  • Update user properties of mobile users in Swrve.
  • Trigger any of the business logic you’ve preconfigured in Swrve Amplify.

From your mobile app, you can instantly:

  • Initiate a Marketing Cloud interaction for a user based on their real-time actions in the mobile app.
  • Update Marketing Cloud contact information with data coming from the Swrve-powered mobile app.
  • Update location information when a user triggers a geofence.

Prerequisites

To use Marketing Cloud with your Swrve-powered app, you must activate the Salesforce Adaptor in Swrve Amplify. For information on how to configure the adaptor, see Salesforce Marketing Cloud.


Setup

Journey Builder

To get started with Swrve for Marketing Cloud, see the Swrve app page on the Salesforce AppExchange and follow the instructions to install the app.

After you install the app, enter your credentials on the login screen to connect to Swrve and get the mobile app access credentials.

Journey Builder setup

Create a special API-only user in your organization, solely for integration purposes. That way, even if an actual user leaves your organization, you’ll always have a user with the correct permissions available.

Swrve Amplify

To complete your integration, you must set up two Swrve Amplify rules that control how information flows between Swrve and Marketing Cloud. While you can select the field values from pre-populated lists, we recommend contacting your CSM at support@swrve.com for a detailed walk-through.

To configure the Marketing Cloud Adaptor and create the required rules, you need to provide the following credentials for the associated actions:

  • FTP location, file path, user name and password – Required for bulk data upload of Swrve data into Marketing Cloud.
  • Client API ID and Secret key – Required for real-time updates from Swrve to Marketing Cloud and Swrve event-triggered journeys.

marketing cloud adaptor
For information on how to get your Client API ID and Secret key, see the Marketing Cloud getting started guide.


Creating interactions in Journey Builder

After you install the Swrve for Marketing Cloud app, all of the supported mobile engagement actions are available in the Journey Builder canvas, on the Activities panel, under the Custom section. There are five independent actions available to use in the journey:

  • Swrve Conversation
  • Swrve In-App Message
  • Update Swrve User Profile
  • Swrve Push Notification
  • Send Swrve Event

Journey Builder Custom Actions

If you want to use the Swrve Conversation and In-App Message actions in Journey Builder, your CSM needs to enable your Swrve dashboard to use external audiences for campaign targeting. For more information, see the Advanced actions section below and contact your  CSM at support@swrve.com.

There are also three corresponding real-time actions that Swrve can take to change how a user lifecycle evolves. These are controlled by Swrve Amplify rules and can be as simple or powerful as your business rules require.

  • Update Marketing Cloud contact.
  • Update Marketing Cloud Data Extension; for example, with geofence data.
  • Initiate a specific journey for a user, based on a trigger in Swrve.

Send push notification

Swrve push notifications sent from Journey Builder are highly customizable. They can contain any of the information you have available in Marketing Cloud about a contact and you can inject that information into the notification in the same way you would inject custom properties into an email. You can also now include rich media options such as images, GIFs, video, and audio files in your notification content. For more information on the rich media options available with Swrve push notifications, see About rich push notifications.

It is also possible to fully customize any of the deeplinks or payloads associated with your push notification. This is often used to send a user to a custom location within the app or personalize the app behavior as soon as the user opens the push notification.

To add a Swrve push notification to your journey:

Step 1: In the journey side bar, under Custom actions, select and move Swrve Push to the desired point in the journey.

Step 2: To display the configuration options, select the Swrve Push action.

Step 3: In the Configure Activity dialog, complete the following sections as required:

Swrve Campaign

  • App Name – Displays a list of your Swrve apps that are linked with your Salesforce account and that have active push notification campaigns (including sandbox and production apps). Select the app you want to use for the campaign.
  • Push Campaign – Journey Builder push uses the Swrve Push API to take advantage of all of Swrve’s built-in tracking and analytics. Swrve recommends creating a Push API campaign for each individual push you want to include in your journeys. Any push API campaigns you’ve created in Swrve are displayed in this list. For more information, see Push API campaigns.
  • Swrve User ID – The key you use to link Swrve and Marketing Cloud. This is the ID Swrve uses to uniquely identify a mobile app user. In some cases it may be the Marketing Cloud master user table primary key, while in other cases it will be a separate key. In all cases there is a 1:1 mapping from Swrve User ID to app user.

Notification Content

If the selected Swrve Push API campaign contains default content, any content or rich media you add here will overwrite those defaults if specified.

  • Body Text – The push notification content. This can be text that you enter directly or that is completely extracted from the Salesforce user attributes or one of the app’s data extensions, or a mixture of the two. To insert data from your contact record, select the property name from the Insert Property list.
  • Title – (Requires Swrve SDK 4.11+) The notification title. To include a custom property in the title, select Insert Property and then select the desired property from the available list.
  • Subtitle – (Requires Swrve SDK 4.11+) For iOS10+ devices, text that is displayed as the subtitle in push notifications. For Android devices, text that is displayed after the title. To include a custom property in the subtitle, select Insert Property and then select the desired property from the available list.
  • Alert Sound – To set a sound for your push notification, select the Alert Sound list and select the desired sound. For information about configuring custom sounds so that they are available in the Alert Sound list, see Intro to push notifications.
  • iOS Category – If your push notification is targeted at Apple users, the iOS Category field enables you to make the notification appear as an interactive push notification on devices running iOS 8 or later. Select a custom action category (for example, Yes/No, Ignore/Respond) from the list. For information about configuring custom action categories for this list, see Intro to push notifications.
  • Engagement Action Deeplink/URL – (Requires SDK version 4.3+) If you want to direct the user to a particular custom location when they engage with the notification, enter the deeplink or URL address.
  • Advanced – Custom Payload – If you want instructional parameters to be sent to your app when you send the push notification, define custom key/value groups or pairs. For example, you might want to direct the user straight to the store (instead of the default start screen) when they open your app from the push notification. Alternatively, you might want tracking parameters to be passed from the push notification for use by your internal or external tracking systems. To add custom key/value pairs:
    1. Select Advanced – Custom Payload.
    2. In the Custom key/value pairs section, select Add key with sub pairs or Add key/value pair, as required.
    3. Enter a key/value pair in the Key and Value fields. For example, go_to/store, trial/30days or discount/10percent. The Payload Preview displays the actual code sent with your push notification.

    The Add key with sub pairs option enables you to nest multiple key/values under the group name in the JSON payload. Consult with your development team about the appropriate key/value pairs to use to trigger the outcome you require.

  • Advanced – Rich Media – As of Swrve SDK 4.11, it is possible to include rich media options in your push notification content that is displayed on supported devices. For more information on Swrve rich push notifications, see About rich push notifications. To include rich media options, select the Advanced – Rich Media link and complete the following fields:
    • Media Type – the type of media you want to include in your notification content. The available options are:
      • Image – displays the URL as an image in the locked, banner, or extended view of the push notification.
      • Audio – (iOS only) include an audio file in your notification that a user can play directly in the extended view of the push notification.
      • Video – links to a hosted video and provides options for watching the video in a related player (for example, YouTube, Vimeo) from the extended view of a push notification.
      • GIF – (iOS only) displays a GIF in the extended view of the push notification.
    • Media URL – the URL of the file you want to use for your rich media content. The URL must be a valid and HTTPS URL and include a file extension. If required, you can customize the media that’s include in the notification (for example, reference a customer’s profile picture or the destination of a flight they searched for). To include a custom property in the URL, select Insert Property and then select the desired property from the available list.
    • Video Thumbnail URL –  for notifications that include a video, the URL of the thumbnail image that will be displayed on the notification in locked or banner view. To include a custom property in the URL, select Insert Property and then select the desired property from the available list.
    • Buttons – lets you include up to three buttons to give your users custom options for interacting with the notification in extended view. Select the Add Button link and complete the following for each button:
      • Button Text – the text for the button label.
      • Action Type – the button action. The options are Open App, URL / Deeplink (directs the user to a custom location) or Dismiss.
      • URL / Deeplink – if you select URL / Deeplink, enter the deeplink or URL address for the button action.

Step 4: After you’ve selected the Swrve Campaign details and added your Notification Content, to return to the journey, select Done.

Tracking uninstalls

iOS and Android do not provide trackable feedback for app uninstalls. However, a good indication a user has uninstalled your app is when push notifications that were previously sent to them successfully now fail. This may not be true in every instance, for example, your user might be traveling overseas or their phone battery has died, but in general it’s a good indicator.

Every time you send a push notification via Marketing Cloud, Swrve tracks the response and if the push fails, records a Swrve.possible_uninstall event for that user. You can then choose to treat this user as an uninstall or wait until a number of pushes fail before you switch to email or other channels as your best way to update the user.


Real-time data transfer from Marketing Cloud to Swrve

In many cases you’ll want to send information from Marketing Cloud to Swrve. This information is per user and is transferred instantly as users hit the corresponding activity in a journey.

Swrve divides information into two logical groups:

  • Events you want to count and track over time. For example, visited_website.
  • Facts about a user that hold a set value at any given moment in time. For example, qualifies_for_free_shipping = true.

The following sections address both of these scenarios.

Send Event

The Swrve app enables Salesforce to send custom events to the Swrve system. You can then use those events in Swrve to trigger other mobile campaigns such as in-app messages or Swrve Amplify actions when the custom events are received.

To send a Swrve event as part of your journey, move the Send Event action to the desired point in the journey and then select it to display the configuration options.

Journey Builder send event

To configure the Send Event action, complete the following fields:

    • App Name – Displays a list of your Swrve apps, including sandbox and production versions. Select the app you want to use for the campaign.
    • Swrve User ID – The key you use to link Swrve and Marketing Cloud. This is the ID Swrve uses to uniquely identify a mobile app user. In some cases it may be the Marketing Cloud master user table primary key, while in other cases it will be a separate key. In all cases there is a 1:1 mapping from Swrve User ID to app user.
    • Event Name – The name of the action or behavior Swrve records for this user. Event names must be unique, alphanumeric, contain only special characters underscore (_) and periods (.) and no spaces. Swrve counts the number of times it see this information for each user and notes the time the event arrives. For example, you might have an event called visited_website that is triggered every time a user visits the website. In your mobile dashboard you can use this information to change the app behavior based on information coming from all of your systems. If the mobile app knows that this user has really recently used your website and done so X number of times, it can behave differently than it would for a user who has not visited the website in six months.
    • Event Content – When sending events, at times you may want to include additional information to help target behavior. That extra information is often described with a label (or key) and a value. In the above example, you might be interested in the section of the website a user visited and store that information in Marketing Cloud in a field called web_page. In that case, select Add to add a new key-value pair. The values of the key-value pair can be dynamically inserted from any Marketing Cloud contact attributes or Marketing Cloud data extensions.
      Journey builder event content

Update User

Use the Update User action to send data you have in Marketing Cloud about non-mobile user activities to Swrve. After the Swrve user profile is updated with this information, Swrve can immediately change how it engages with the user based on this new context.

To send a user update as part of your journey, move the Update User action to the desired point in the journey and then select it to display the configuration options.

Journey Builder update user

To configure the Update User action, complete the following fields:

  • App Name – Displays a list of your Swrve apps, including sandbox and production versions. Select the app you want to use for the campaign.
  • Swrve User ID – The key you use to link Swrve and Marketing Cloud. This is the ID Swrve uses to uniquely identify a mobile app user. In some cases it may be the Marketing Cloud master user table primary key, while in other cases it will be a separate key. In all cases there is a 1:1 mapping from Swrve User ID to app user.
  • User Properties – User properties are described with a label (or key) and a value. You must include at least one. The above example illustrates how to update the user’s profile to show they now qualify for Free_Shipping and the tier of rewards they are at. First, select Add, enter a Key called Free_Shipping and set the value to TRUE. The information about tier is stored in this instance of Marketing Cloud in a field called Rewards.tier. To update the rewards tier, add a new key-value pair called Tier and use the Insert Property list to find the corresponding value in your data extensions.

To check the existing custom properties for your app, download the Custom User Properties CSV file from the User DB Downloads screen, or in the audience builder, on the Property tab, check the list of available properties in the filter list. For more information, see Intro to User Databases or Segment and audience filters.


Advanced actions

The Swrve app now enables you to trigger in-app messages or Conversations as part of your journey.

To make an in-app message or Conversation available in your journey, you must first create the campaign in Swrve. We recommend following a standard naming convention for your Journey Builder campaigns so they’re easy to find in the campaign list. For more information on the main steps involved, see Creating in-app messages or Creating Conversations.

To make the campaign available in Journey Builder, on the Define Target Audience step of the campaign workflow, select External Audience, and then select Marketing Cloud.

external audience marketing cloud

To add a Swrve in-app message or Conversation to your journey, move the related action to the desired point in the journey and then select it to display the configuration options.

Journey builder conversation

To configure the in-app message or Conversation action, complete the following fields:

  • App Name – Displays a list of your Swrve apps, including sandbox and production versions. Select the app you want to use for the campaign.
  • Conversations or In-App Messages Campaign – Select the campaign you created in Swrve. Ensure the campaign you select has been set to use Marketing Cloud as the external audience source.
  • Swrve User ID – The key you use to link Swrve and Marketing Cloud. This is the ID Swrve uses to uniquely identify a mobile app user. In some cases it may be the Marketing Cloud master user table primary key, while in other cases it will be a separate key. In all cases there is a 1:1 mapping from Swrve User ID to app user.

Use cases

  • Track your users non-mobile behavior in Marketing Cloud and then trigger push notifications based on a user’s non-mobile actions/activities or an external real-time event. For example, send a push notification about an upcoming event of special interest to a specific user.
  • Use non-mobile behavioral data to target and run engagement campaigns in Swrve. For example, use web purchase data received from Marketing Cloud to segment users for an in-app messaging campaign in Swrve.
  • Synchronize Swrve and Marketing Cloud user records so you can run coherent mobile and non-mobile campaigns from Swrve and Marketing Cloud respectively.
  • Send a personalized web notification to a website or browser from Salesforce, based on a user’s interests.