Marketo Integration
Use Marketo data for the maximum user engagement
Last updated
Use Marketo data for the maximum user engagement
Last updated
This guide explains how to integrate Marketo with Pushwoosh. You would be able to use Web Push Notifications communication channel as a part of your marketing campaigns with Marketo.
As an example, imagine a user visited your Marketo landing page but did not take an action there. You would be able to reach this user with web push notification as a reminder. This web push notification can also be personalized with Marketo data recorded for this user for the maximum engagement!
While it is possible to run web push notifications with HTTP unsecured websites we strongly advise to use HTTPS secured web pages. Beginning in October 2017 with the release of Chrome 62, Google Chrome marks all unsecured web pages containing forms with the “Not secure” warning.
Read more here: https://nation.marketo.com/docs/DOC-3891-faq-ssl-landing-pages-and-tracking-links https://nation.marketo.com/docs/DOC-4742-ssl-certificates-and-marketo-faq
If you still want to go with HTTP unsecured website, follow the Chrome/Firefox Web Push for HTTP websites guide.
You can get FREE SSL certificate here: https://letsencrypt.org/
Follow this guide and do the prerequisite steps and steps 1 - 2.2.
After completing the steps above you should have manifest.json and pushwoosh-service-worker.js files ready at hand.
Switch to Marketo Design Studio. Marketo can only upload files to the resource folder, the folder called "Images and Files". Upload manifest.json and pushwoosh-service-worker.js to these folder.
As it was mentioned above Marketo can only upload files to the resource folder which is different from the scope of the landing pages. For example if you click on any file uploaded above and check its URL you'll see something like "https://your-host-name.com/rs/765-IWA-819/images/pushwoosh-service-worker.js". However if you click on the landing page and check its URL it will be something like: "https://your-host-name.com/lp/765-IWA-819/pushwoosh-landing.html". Note "lp" part in the landing pages URL's and "rs" in the script URL's.
That means we need to register our Service Worker script in a scope different from the landing pages.
To achieve that we'll upload special push subscription page to Marketo resources folder and then open it from the landing page. Let's create this subscription page.
Get the push-subscription.html file from the following gist: https://gist.github.com/shaders/2b518e3acaf9b4712d5260205243343d#file-push-subscription-html
Open the file and change the following lines:
Line 8 - change the link to the URL of manifest.json file uploaded in the previous step.
Line 24 - change the scope parameter value to the URL of your resources folder (this is the folder where manifest.json is).
Line 20 - change the applicationCode parameter value to your Pushwoosh App Id.
Note the script also maps Pushwoosh user-centric push notifications with Lead Identifier of the Marketo: userId:leadId (line 26)
Upload resulting file to the "Images and Files" folder. Now you should have these files in the folder:
Get the pushwoosh-template.html file from the following gist: https://gist.github.com/shaders/2b518e3acaf9b4712d5260205243343d#file-pushwoosh-template-html
Open the file and change the following lines:
Line 47 - change the scope parameter value to the URL of your resources folder.
Line 65 - change the link to the URL of push-subscription.html file uploaded in the previous step.
Line 43 - change the applicationCode parameter value to your Pushwoosh App Id.
This script as a previous one also maps Pushwoosh user-centric push notifications with Lead Identifier of the Marketo: userId:leadId (line 49)
Now go to the "Templates" section of your Marketo landing pages, create the template (called "pushwoosh-template" in the screenshot below) and copy-paste the contents of the resulting file there.
Now let's create a new landing page based on this template.
In our example to show capabilities of Pushwoosh integration with Marketo campaign automation for the sake of simplicity we'll add a simple link to the landing page. We are going to create a campaign that will trigger personal push notification when the user clicks on this link.
We are going to use the same URL as the landing page.
Go to the "Admin" section of Marketo and create a new Webhook with the following parameters:
Request Type: POST
Paste the following code as a template.
Note that we use Marketo Lead ID to refer user in Pushwoosh. See more about user-centric push notifications here.
In our very simple example we use static push message. However you can use all the functionality of /
createMessage
To personalize push notification you can use Preset from Pushwoosh and pass the values from Marketo in "dynamic_content_placeholders" parameters of the /createMessage
call for push personalization.
Go to the "Marketing Activities" section of Marketo and create a Campaign.
For our example we'll trigger the campaign when the user clicks on a link (the one we have created just two steps above) on our landing page.
b. Select "send_push" Webhook in the "Flow" section
Now open the landing page URL
Click on the "Yes, I Want" button to open push subscription dialogue
Subscribe to the push notifications
Click on the "Send me an Offer!" link
You've got your Marketo automated push notification!