• Home
  • Pardot Tips & Tricks: Integrating Salesforce Custom Objects With Pardot

Pardot Tips & Tricks: Integrating Salesforce Custom Objects With Pardot

Automated Selective Syncing from Salesforce to Pardot

This solution will work with ALL levels of Pardot using Salesforce Enterprise Edition or greater.

THE REQUEST/USER STORY:

Sales & Marketing Users would like to specify which Salesforce object updates trigger an update to Pardot, including ‘add to list’, ‘send auto-responder’, or add to an engagement program.

Example #1: ‘We are using a custom object to track when a distributor order is made and associated with a contact. We need to use the creation of this record to trigger the contact being added to an Engagement Program in pardot’

Example #2: ‘We are using Orders in Salesforce. Anytime an Order record is fulfilled, we need to use Pardot to send an email update, add them to an Engagement program and add the prospect to a suppression list for irrelevant engagement programs’

Currently, the Salesforce/Pardot admins need to get ‘creative’ and add additional fields or flows to create updates to a Lead or contact record. However, with WebhooksByCypress we can send a record to Pardot Instantly and use the completion actions available on form handlers to accomplish our business objectives.

THE SOLUTION:

WebhooksByCypress is an Apex Class that allows an HTTP POST from a flow in Salesforce. This class uses an @invocablemethod, which means it can be used with Process Builder or Flows in Salesforce.


We’ve created a Managed Package for this Application. Purchase the Package HERE:


SETTING UP THIS SOLUTION

Install the Managed Package

Install the Managed Package above and confirm it’s been installed by searching your Installed Packages in Salesforce. The Name of this Managed Package is WebhooksByCypress.

Setup Remote Site Settings

In order for our HTTP POST to work from SalesForce, we need to make sure our Remote Site settings include https://go.pardot.com.

This assures Salesforce TRUSTS the endpoint URL for Pardot. Optionally, a tracker domain can be used. We have found using go.pardot.com is a clean solution, but remember the form handler will need to use the domain included in the remote site setting!

  1. From Setup, Quickfind Remote Site Settings
  2. Create a new remote site
  3. Name: PardotFormHandler
  4. Site/url: https://go.pardot.com

Using WebHooksbyCypress

Webhooks by Cypress are designed to work with Process Builder or Flows in Salesforce. In this example, we’ll be using Pardot form handlers. However, we’ve tested this with many other tools that accept HTTP POST and it works just fine! (For example, Webhooks by Zapier!)

The Apex class has been built to allow a url variable to be added in Process Builder or flow (see below). This is where we’ll add a URL with some variables from Salesforce. Depending on whether you’re using Process Builder, Flow to create a formula for your URL, or using a formula field created on the record itsself is up to you. This method will execute the HTTP POST method in salesforce to whatever is passed through to the url variable.

WebHooksbyCypress with Process Builder: In Process Builder, you add an Apex Action. Name your action whatever you’d like, we recommend Send to Pardot. Find the WebHooksbyCypress Apex Class and add the url variable from the Set Apex Variable. Create a formula that includes your Pardot Form handler and whichever values you’d like to send to your form handler by appending the query string to your form handler

Salesforce Webhooks with Process Builder

WebHooksbyCypress with Flows: In Flow, you will likely create a New Resource to generate your webhook URL. Here’s an example of a Resource we created:

Creating a Formula Resource Salesforce Flow

This has been designed to be a flexible way to make HTTP callouts from Salesforce flow or process builder. There are many use cases I have not yet explored, including using this with custom objects, let us know what you come up with!

Neet More Helpt? Visit our TROUBLESHOOTING GUIDE

Leave a Reply

Your email address will not be published. Required fields are marked *