Salesforce connector

  Written by The Jahia Team
   Estimated reading time:

Salesforce connector in one sentence 

Salesforce is the most famous CRM, widely used by sales people in many businesses. The Jahia Marketing Factory / Salesforce connector provides bi-directionnal integration between Marketing Factory profiles and Salesforce leads. Such integration give marketers the ability to push any data collected on a visitor by Marketing Factory to Salesforce, and enhance Marketing Factory personalization capabilities using Salesforce data. 


To install the Salesforce connector, Marketing Factory 1.7.1 (and therefore Apache Unomi 1.1.3) must be deployed on your DX platform. 


To install the salesforce connector, please follow the steps below :

  1. From the extranet download the .kar file of the salesforce integration and copy it to the the folder <your apache unomi folder>/deploy
  2. The installation is done !


1. In Salesforce :

  • Create a new Connected App, by going into Setup -> App Manager and click “Create Connected App”
  • In the settings, make sure you do the following:
  • Enable OAuth settings -> Activated
  • Enable for device flow -> Activated (no need for a callback URL)
  • Add all the selected OAuth scopes you want (or put all of them)
  • Make sure Require Secret for Web Server flow is activated
  • Make sure you retrieve the following information once you have created the app in the API (Enable OAuth Settings):
    • Consumer key
    • Consumer secret 
    • User’s security token. To do this simply click on your user at the top right, select “Settings”, the click on “Reset my security token”. You will receive an email with the security token.

2. In Apache Unomi

Edit the file <your apache unomi folder>/etc/org.apache.unomi.sfdc.cfg

Basic parameters



To define how Salesforce attributes will be mapped to Marketing Factory profile properties, edit the following entry using the pattern below : 

  • sfdc.fields.mappings=myMarketingFactoryProperty1=mySFDCAttribute1,myMarketingFactoryProperty2=mySFDCAttribute2
Please note that Salesforce needs the company and the last name to be set, otherwise the lead won't be created. 

An identifier needs to be set as well. The identifier will be used to map the Marketing Factory profile to the Salesforce lead. By default, the email is set as the identifier, meaning that if a lead in Salesforce and a profile in Marketing Factory have the same email, they'll be considered as the same person. 

  • sfdc.fields.mappings.identifier=email=Email 

3. Rules

When the Salesforce connector is setup, 2 new actions will be available from the Marketing Factory Rules User Interface : 

  • "Create/Update Salesforce lead from visitor profile" : When triggered, this action will create or update a lead in Salesforce. The data is pushed from Marketing Factory to Salesforce. To know if a lead should be created from scratch or updated, the action uses the configured identifier.
  • "Update visitor profile from Salesforce lead" : When triggered, this action will update the Marketing Factory profile with data that is in Salesforce for this lead. 



Use case 1 : Create a lead in Salesforce on goal reached

One way to use the Salesforce connector is to leverage the visitor behavior on your website and create a lead in Salesforce when he fulfills a goal

  1. Create a Form in Form Factory with the following fields : last name, email, company. 
  2. Use the marketing Factory - Form Factory bridge to map the form to the Marketing Factory profile
  3. Create a goal to track visitors who fill the form
  4. Create a Rule : 
    1. When "a goal is fulfilled", select the goal you created
    2. What "Create/Update Salesforce lead from visitor profile" 
    3. Save

Use case 2 : Update Marketing Factory profile from Salesforce when a visitor starts a new session

Another way to use the Salesforce connector is to update the Unomi profile when a visitor starts a new session, in order to personalize his experience with Salesforce data

  1. Create a Rule :
    1. When "Visitor session starts"
    2. What "Update visitor profile from Salesforce lead"
    3. Save
  2. Add a personalization on any content you'd like, the visitor profile will be up to date with the latest data from Salesforce !