How can we help?

About Salesforce Duplication Rules And Allbound Integration Best Practices

Jenna
Jenna
  • Updated

Purpose:

Salesforce is a powerful CRM that has many capabilities, one of which is the ability to reject the creation of duplicate records based on specified criteria. These Salesforce duplication rules, although beneficial for data integrity, can cause disruptions with the Allbound Integration. This article goes over the Allbound integration best practices, and how to streamline your integration with Salesforce to avoid deduplication disruption.

 

About Salesforce Duplicate Rules:

By default, Salesforce comes equipped with three standard duplication rules: Standard Account Duplicate Rule, Standard Contact Duplicate Rule, and Standard Lead Duplicate Rule. Tied into these duplicate rules are matching rules that determine whether or not a record is a duplicate of another.

  • Matching Rules: Will identify what field and how to match. For example, “Email Field, Exact Match” or “Account Name, Fuzzy Match”. Matching rules, alone, don’t do anything. Compare this to a recipe without a chef.
  • Duplicate Rules: Will use those matching rules to control when and where to find duplicates. For example, “Use Account Name, Fuzzy Match” to find duplicates on the Account object upon creation or “Use Email, Exact Match” to find duplicates on Leads and Contacts, upon create and edit. Compare this to a chef with the recipe (i.e. the matching rule).

When these rules are in place without conditions/exceptions for records being updated or created by an integration (not specific to Allbound - duplicate rules can interfere with a number of Salesforce integrations) Salesforce is likely to reject certain sync actions from an integration. 

 

Common Scenarios Impacted by Duplicate Rules:

Allbound is submitting a new record when a deal is registered (in Allbound) and synced as a lead (in Salesforce). The integration cannot "match" existing leads and add an Allbound ID to the existing records, although Salesforce itself can do so. If a deal is registered and Allbound and contains the same email address as an existing lead and/or contact in Salesforce, SFDC will reject the record from syncing and will throw and integration error back to Allbound. 

There should be very limited incidents where a true duplicate is registered in Allbound by a partner sales rep when the same lead from the same source exists already in Salesforce. A real-world example of a non-duplicate/duplicate lead would be if someone from the vendor’s team created a Lead in Salesforce for a prospect that was unrelated to any of the partners. Then, one of the partners was able to capture the interest of the same prospect company (perhaps even the same contact) and registers a new deal for them in Allbound, completely unaware that a lead for this prospect already exists in Salesforce, thus a "duplicate" lead is synced with the integration. 

Here's an example scenario:

  1. In Salesforce, Jane Doe - email address j.doe@gmail.com exists as a contact record. Her contact was created a few years ago from an old campaign, previous dealings, etc. 
  2. In Allbound, a partner registers a new deal today with prospect first name, last name, and email as Jane Doe - j.doe@gmail.com.
  3. Salesforce's dedupe rules reject this lead from being created. 
  4. A Salesforce admin configures a dedupe exclusion for lead: Allbound ID NOT = empty. 
  5. The Allbound integration is able to sync the new lead with the same email address as the existing contact record. 
  6. In Salesforce, the existing contact record has nothing to do with the new lead that was just synced over. They exist on two separate objects. The contact for Jane Doe - email address j.doe@gmail.com was created in 2017. The new lead has a created date of 1/26/23. 
  7. In Salesforce, I accept the lead and convert it to an opportunity. During the conversion, I see that there is an existing contact record match. I choose to use the existing Jane Doe contact from 2017, because this is a new 2023 deal for her and that is why she is going to get associated with the new opportunity that I am currently converting from a new lead that synced from Allbound. 
  8. Only one Jane Doe - email address j.doe@gmail.com exists as a contact in my Salesforce. No duplicate gets created, because in the conversion, I used the existing contact record. 

In conclusion, Allbound is not creating duplicates. In many scenarios, one contact can have or be associated with multiple deals. 

Another example:

A vendor user in Salesforce create a lead and associates it with a partner account. The Channel Partner Manager informs the partner of the lead and wants to track it in Allbound as well, and so they create a deal in Allbound for a partner rep/Allbound user to have visibility on the prospect. The deal is disconnected from the lead record in Salesforce as they are two separate records created individually of each other on each platform, and therefore a duplicate record is created (or rejected from the sync due to deduplication rules in SFDC on the lead object). 

 

Allbound Integration Best Practice To Avoid Salesforce Duplication Rule Rejection Errors:

It is highly Recommended to allow Allbound leads to bypass deduplication rules to avoid unwanted errors with the integration. 

How To Configure Exceptions For Allbound To Bypass SFDC Duplicate Rules:

  • Have your Salesforce administrator go into the Duplicate Management section of Salesforce Settings. 
  • Locate "Duplicate Rules.

Note: Since the source of truth for Allbound companies come from the Salesforce account object, there's no need to set duplication rules for accounts in Salesforce. This helps you avoid duplicate account records in Salesforce that could potentially cause duplicate partner companies in Allbound. Allbound only needs to bypass the contact duplicate rules and the lead duplicate rules, because Allbound is the source of truth for partner contact records, and partner registered leads. 

The reason Allbound is able to match existing contact records in Salesforce and integrate with them (tag them with an Allbound ID and pull the CRM ID into the record in Allbound) is because Salesforce has an automatic deduping function that is specific and exclusive to contacts. It allows for matching without needing the actual record ID of the contact to match. Since Allbound obtains the Account ID of the partner company before a contact ever registers, we are able to map the user's Account ID within the contact sync. If a matching record exists in Salesforce, as long as the email address and Account ID are the same, no duplicate will be created. Instead, Allbound tags the matching record with an Allbound ID, and Salesforce patches back the record ID of the contact to the user profile.

When duplication rules are enabled to alert and block for contacts, the API sync fails due to the error/validation before it can actually sync with the matching record. That is why we recommend the duplication bypass filter for Allbound's API integration.

  • Next, click into the Standard Contact Duplicate Rule. 
    • Click Edit. 
    • Scroll down to "Conditions".
      • Observe the verbiage in place for duplicate rule conditions. The conditions state that you can specific the conditions a record must meet in order for the rule to run. 
        • To avoid integration errors, you want to make sure that the rules do not run on contact records that contain an Allbound ID, which is the key identifier for any record coming from the Allbound integration. 
        • The condition to add is "Contact: Allbound ID equals an empty value". See screenshot below. 

  • Save once this is in place.
  • Next, go into the Standard Lead Duplicate Rule, and add the same condition, but for the lead object. See screenshot below. 

  • Save when done. 
  • If you have additional custom duplicate rules in your Salesforce for leads and contacts specifically, you will need to add the same condition to all contact and lead duplicate rules in place in your Salesforce. 

What does a Duplicate Rule Error look like?

Below is an example of a common Salesforce duplication error. Errors such as these are caused by Salesforce Duplication Rules. This cannot be fixed on the Allbound side. This must be worked out with the client on the Salesforce side. 

"[{\"duplicateResut\":{\"allowSave\":true,\"duplicateRule\":\"Standard_Lead_Duplicate_Rule\",\"duplicateRuleEntityType\":\"Lead\",\"errorMessage\":\"You're creating a duplicate record. We recommend you use an existing record instead.\",\"matchResults\":[{\"entityType\":\"Lead\",\"errors\":[],\"matchEngine\":\"FuzzyMatchEngine\",\"matchRecords\":[{\"additionalInformation\":[],\"fieldDiffs\":[],\"matchConfidence\":100.0,\"record\":{\"attributes\":{\"type\":\"Lead\",\"url\":\"\/services\/data\/v53.0\/sobjects\/Lead\/00Q4K000006zgmTUAQ\"},\"Id\":\"00Q4K000006zgmTUAQ\"}}],\"rule\":\"Standard_Lead_Match_Rule_v1_0\",\"size\":1,\"success\":true}]},\"errorCode\":\"DUPLICATES_DETECTED\",\"message\":\"You're creating a duplicate record. We recommend you use an existing record instead.\"}]"

This error message is generated by Salesforce and it indicates that there is an issue with creating a new record because it is identified as a duplicate. Here's a breakdown of the message:

Error Code: DUPLICATES_DETECTED
This code indicates that duplicate records have been detected.

Message: You're creating a duplicate record. We recommend you use an existing record instead.
This message informs you that the system has identified the record you're trying to create as a duplicate. It suggests using an existing record instead of creating a duplicate.

Duplicate Result:
- allowSave: true
This property indicates whether the system allows you to save the duplicate record. In this case, it's set to true, meaning you can save the record if needed.

- duplicateRule: Standard_Lead_Duplicate_Rule
This specifies the name of the duplicate rule that flagged the record as a duplicate. The rule used in this case is called "Standard_Lead_Duplicate_Rule."

- duplicateRuleEntityType: Lead
It specifies the type of entity (object) for which the duplicate rule is applied. In this case, the rule is applied to the "Lead" object.
- entityType: Lead
This specifies the type of entity (object) involved in the matching process. In this case, it's the "Lead" object.

- errors: 
If any errors occurred during the matching process, they would be listed here. In this case, the array is empty, indicating no errors.

- matchEngine: FuzzyMatchEngine
It specifies the matching engine used to identify the duplicate record. In this case, the "FuzzyMatchEngine" was employed.

- matchConfidence: 100%
This value represents the confidence level of the match. A confidence level of 100.0 indicates a high certainty that the records are duplicates.

- record: It contains details about the matched record.
- attributes: It contains attributes related to the record.
- type: Lead
It specifies the type of the matched record, which is "Lead."

- url: /services/data/v53.0/sobjects/Lead/00Q4K000006zgmTUAQ
This URL provides a link to the matched record within Salesforce.

- Id: 00Q4K000006zgmTUAQ
It represents the unique identifier of the matched record.

- rule: Standard_Lead_Match_Rule_v1_0
This specifies the name of the matching rule that identified the duplicate record. The rule used in this case is called "Standard_Lead_Match_Rule_v1_0."

In summary, the duplicate rules and matching rules on the Salesforce side will not allow this record to be synced over. 

To troubleshoot this, we need the help of their Salesforce admin. As a best practice we recommend adding exclusions for all records containing an Allbound ID to the duplicate rule mentioned, and the matching rule mention. The exclusion condition should function as, "Only run these rules if Allbound ID field is empty."

 

How can you tell that the error originated in Salesforce and isn't stemming from a problem with the Allbound side of the integration?

If you were to manually create a new lead in Salesforce using the same details of the deal in Allbound that the error stemmed from, you would receive the same message in Salesforce itself. See screenshot below. 

 

If you are still unclear about the information above, or would like to schedule a meeting with an Allbound integration expert, please reach out to help@allbound.com

 

 

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request