Integrating Drupal and Salesforce

Integrando Drupal y Salesforce

There are a variety of strategies for integrating Drupal and Salesforce, from Salesforce web-to-lead forms, to using third-party form providers, to two-way synchronization through Drupal's Salesforce suite modules.

Salesforce Suite is a set of modules that help administrators and developers map content types in Drupal to any object in Salesforce (contacts, organization, opportunities, and campaigns, for example). This is the most sophisticated approach to passing data back and forth between Drupal and Salesforce, but it is only one of the possible options.

Integration Types

   Cost  Address  Complexity

 Simple Web Forms (Provided by Salesforce)

 Gratuitous  One direction, towards folesforce   Do it yourself type
 Third Party Forms Services  Low  One way (occasionally both ways)   Like, do it yourself or with the assistance of a developer
 Salesforce Drupal Suite  Moderate to high  Bidirectional   Developer assistance required

Salesforce Drupal Suite

What is it?

Drupal Commerce is a set of Drupal modules that allows you to synchronize data in one or both directions between Drupal and Salesforce. It leverages the Drupal and Salesforce APIs to connect the systems and exchange data in real time (synchronously) or with a slight delay (asynchronously). You can map Drupal entities (users, content types, and even products created in Drupal Commerce) to standard or custom Salesforce objects (contacts, organizations, opportunities, campaigns, and more). The mapping tool allows you to map specific fields in Drupal to fields in Salesforce. Advanced users can even transform data if field types don't match between the solutions (e.g. a text field vs. a multiple choice field).

Drupal

When is it useful?

To more clearly explain the value of this approach, let's take the example of purchasing and renewing a membership. Memberships are a good use case, as a member's status often drives their experience on your website, whether it's seeing renewal notices, accessing restricted members-only content, or for member discounts to apply. automatically to purchases on the site. 

Unlike third-party solutions, this integration keeps Drupal aware of a user’s status in Salesforce and allows you to more strategically target their experience on your site to guide them toward important content and calls to action or deepen their engagement at the point of each conversion.

When the integration is two-way, your user can initiate a transaction such as a membership purchase on the website. This purchase can open up access to all the member benefits your organization provides. However, if a member renews offline or pays for an event registration at the event itself, and that transaction is recorded in Salesforce, a one-way or third-party integration app does not make Drupal aware of the data. 

On the other hand, bi-directionality allows new information to make the round trip from Salesforce to the website. This is just a small example of how powerful the solution can be if planned and configured properly.

Drupal to Salesforce: Membership Purchase

Drupal

 

Salesforce to Drupal: Offline Membership Renewal

Salesforce to Drupal

In general this approach is ideal if:

  • You want to fully utilize what both solutions have to offer, so that Drupal does what it does best as a content management system and Salesforce remains the place where you manage and pull your data.

  • You want to control and personalize the visitor's experience with Drupal, and that experience includes user accounts and login.

  • It needs data to move in both directions.

  • You want to map custom objects, not just standard ones.

  • You want to reduce duplicates in Salesforce. (Drupal is good at connecting data to an existing user/contact.)

  • You don't want to pay for additional user licenses. The key benefit here is that you can have as many users log in to Drupal as you want. You do not need to purchase Salesforce licenses for Force.com or Community portals to expose Salesforce data to your authenticated users.

You can integrate Drupal and Salesforce using the Suite in one direction (Drupal to Salesforce only) or both. In some cases, you can use both methods on the same site, integrating along a single direction for some node types and moving data in both directions for others.

Integration in one direction

For one-way integrations, data entered into forms on Drupal nodes is sent to Salesforce and populated with objects that are mapped in the Suite. Because the data moves in only one direction, this approach can be set up and managed by a more advanced Drupal administrator, mapping fields and objects without the need to know the PHP programming language. It still takes care and patience, as well as an understanding of the Salesforce schema, but it is possible to do this approach on your own.

When is it useful?

  • You want to pass user data, transaction data, and specific node types, such as events.

  • You want to keep the user on your website for all transactions and activities.

  • You should use one-way sync to keep the integration simple.

  • You don't need updates in Salesforce to impact the user experience in Drupal.

What are the pros and cons?

Pros:

  • This approach limits complexity and therefore liability and errors.

  • Support and making changes over time is easier.

  • Drupal is still responsible for the activity and transactions, so you can continue to target the user and personalize the experience.

Against:

  • Advanced development and knowledge of Drupal and Salesforce schema are a must.

  • You may need the help of a developer to set it up correctly.

  • The integration will break if changes are made to the Salesforce schema without updating the mapping in the Suite.

Use cases

  • Donation forms

  • Event registration

  • Application for programs, volunteering, scholarships, etc…

auxiliary image

How to do it?

  • Define your integration points (what data should pass).

  • Install Salesforce suite.

  • Connect Drupal to your Salesforce instance.

  • Enable SF Mapping and SF Push modules.

  • Map objects and fields across both solutions.

chart

Two-way integration

For two-way sync, data entered into Drupal by the user and into Salesforce by administrators moves in both directions across applications. 

Synchronous or asynchronous updates keep information aligned in both systems. Note that this approach is very advanced and requires a well-formed schema and workflows in Salesforce as well as code in addition to the Suite to ensure your solution works well.

It is useful to use this method when:

  • Data entered directly into Salesforce should impact what a user sees, has access to, or experiences in Drupal.

  • You need to take advantage of marketing automation and personalized web experiences.

  • Your site requires user authentication.

  • Your users need sophisticated interaction, such as the ability to view offline data you entered into Salesforce in their user profile in Drupal (for example, to see donations paid on the website and donations paid by check).

What are the pros and cons?

Pros: 

  • Eliminates the need for additional Salesforce licenses.

  • The user experience can reflect the business logic driven by Salesforce.

  • Performance issues due to online queries or dropped connections are mitigated.

  • Fewer duplicate records are created in Salesforce

Cons:

  • It usually requires the help of a developer.

  • Timing can be a difficult problem to solve, so be aware of possible race conditions. A race condition is when both systems try to perform conflicting actions at the same time, such as editing the same record.

  • The approach almost always requires creating custom PHP code and, potentially, custom Drupal modules.

  • Schema mismatches between Drupal and Salesforce compound when data moves in both directions.

Use cases

  • Memberships

  • Account Management

  • Fundraising

  • Course management, continuing education unit (CEU) credit tracking

Conclusion

Drupal is a tool that has been very well thought out from the ground up to integrate into a hybrid ecosystem of solutions. Companies have various in-house or third-party solutions that all work together like a cog, and any new solution included in that ecosystem should behave in the same way. That is why Drupal is among the preferred options for large companies. Its broad integration layer allows for this gearing to be carried out without any problems.

 

Jairo_Pinzon