How to create custom rules to set the primary record for HubSpot duplicates

This article explains how to configure primary duplicate rules in Koalify to determine which record is identified as the primary duplicate.

When you deduplicate records in HubSpot, you merge a secondary record into a primary contact or company record. Setting the primary duplicate rules in Koalify determines which record is identified as the primary duplicate for each set of duplicate records.

1. Navigate to the Koalify app settings page

  • In your HubSpot account, click the ⚙️ settings icon in the main navigation bar.
  • In the left sidebar menu, navigate to Integrations, Connected Apps
  • Locate "Koalify - Deduplication", Click the Actions, Go to settings
  • Click "Edit Primary Rules" in the Primary Rules section.

2. Review default Primary Rules

  • First Created : Records will be merged into the oldest record based on the Create date property.
  • Last Created: Records will be merged into the newest record based on the Create date property.
  • Owner Exists > First Created: Records will be merged into the record which has an owner or fall back to the oldest records based on the Create date property.
  • Last Activity Date: Records will be merged into the record with the most recent value for the Last activity date property. Activities that impact this property include notes, calls, tracked and logged sales emails, meetings, LinkedIn/SMS/WhatsApp messages, tasks, or chats.
  • Last Engagement Date: Records will be merged into the record with the most recent value for the Last Engagement date property. Engagements that impact this property include interactions with website pages, forms, documents, meeting links, or tracked one-to-one emails.

Review Primary Duplicate Rules-1

3. Create new Primary Rule

  • Navigate to the Contact or Companies tab
  • Click "Create Rule"
  • Add the name of the rule you want to create
  • Click "Add Filter" to add criteria for identifying the primary duplicate
    • Select a property that you would like to use in your rules
    • The following match criteria are available
      • contains exactly
        • The selected property of record A or record B contain a specific value 
      • does not contains exactly
        • The selected property of record A or record B  do not contain a specific value 
      • is (equal to) any of
        • The selected property of record A or record B are equal to specific values
      • is none of
        • The selected property of record A or record B are not equal to specific values
      • is known
        • the selected property of record A or record B is known
      • is unknown
        • the selected property of record A or record B is unkown
      • has first
        • the selected property of record A or record B has the first date value
      • has last
        • the selected property of record A or record B has the last date
      • smallest
        • the selected property of record A or record B has the lowest value
      • biggest
        • the selected property of record A or record B has the highest value
      • is greater than
        • the selected property of record A or record B is greater than a specific value
      • is smaller than
        • the selected property of record A or record B is smaller than a specific value

Create Primary Duplicate Rules

4. Primary Duplicate Rule Impact

Configuring the Primary Rules in the Koalify app settings impacts the Koalify Primary Duplicate ID, which is used in two key areas:

  1. Koalify Workflow Action: The Koalify workfow action "Merge Duplicate" merges records into the designated Koalify Primary Duplicate ID. 

    Koalify primary duplicate rule for workflow action
  2. Koalify Duplicate Cards: These cards suggest the primary duplicate to merge into, but you still have the option to manually merge into a different record if needed.

    Koalify primary duplicate rule for duplicate cards