Duplicates not being Matched

Walkthrough on how MoveData performs Contact and Account record matching.

Occasionally, we are asked why didn't this notification match on this contact. This is quite complex and open to many reasons. This document will work through how to diagnose why a match happens and why there may have been a miss.

Background

When a notification is received, it executes a number of stages. In the case of a Donation & Fundraising notification, it processes each phase in the follow order: Account, Contact, Campaign, Recurring Donation, Donation. Within the account and contact phases, there is a specific execution sequence that is followed to maximise the likelihood that record is correctly matched.

Sequence Walkthrough

This example uses the out-of-the-box MoveData NPSP Extensions and, while likely relevant, may not be 100% fit with your implementation.

Some of the extended logging such as Salesforce Duplicate Matching entries require MoveData version 1.167 or greater.

The execution for a contact or account executes the following checks:

  • Detect using Platform Key

  • Detect using Salesforce Duplicate Detection Rules

  • If no matches, create record; otherwise, update record

We will execute using a fictitious scenario for Jane Smith who is a fundraiser. She signs up as a fundraiser via the fictional MoveData.org fundraising site. A notification is dispatched from the fundraising platform containing Jane' sign up information.

The notification for Jane has been transformed by MoveData and contains the following information for her contact record:

"primaryContact": {
  "key": "ac92f340-cdc0-11ed-943f-cb69108336f6",
  "partyType": "person",
  "firstName": "Jane",
  "lastName": "Smith",
  "email": "jkent+janesmith@movedata.io",
  "custom": {
    "accessToken": "860b4a335f84939014ea7627b900d5d8"
  },
  "createdAt": "2023-03-28T23:31:33.108Z",
  "modifiedAt": "2023-03-28T23:31:33.108Z"
}
Full Notification
{
  "schema": "donation",
  "schemaVersion": {
    "major": 1,
    "minor": 14,
    "build": 20220915
  },
  "platform": "raisely",
  "platformLabel": "Raisely",
  "platformVersion": {
    "major": 1,
    "minor": 3,
    "build": 20221108
  },
  "action": "metadata",
  "campaign": [
    {
      "key": "aa88bd90-562c-11eb-bf24-6bd493dd10e5",
      "type": "campaign",
      "name": "MoveData Campaign",
      "description": "",
      "pageUrl": "https://movedata-campaign.raisely.com/",
      "status": "live",
      "targetAmount": 100000,
      "amount": 34342.84,
      "currency": "AUD",
      "custom": {
        "type": "GROUP",
        "path": "movedata-campaign",
        "grandTotal": 34342.84,
        "campaignTotal": 34342.84,
        "feeTotal": 1902.61
      },
      "marketing": {},
      "createdAt": "2021-01-14T05:52:20.458Z",
      "modifiedAt": "2021-01-14T05:52:20.458Z"
    },
    {
      "key": "accbb680-cdc0-11ed-943f-cb69108336f6",
      "type": "fundraiser",
      "name": "Jane Smith",
      "pageUrl": "https://movedata-campaign.raisely.com/jane-smith",
      "status": "live",
      "targetAmount": 350,
      "amount": 0,
      "currency": "AUD",
      "primaryContact": {
        "key": "ac92f340-cdc0-11ed-943f-cb69108336f6",
        "partyType": "person",
        "firstName": "Jane",
        "lastName": "Smith",
        "email": "jkent+janesmith@movedata.io",
        "custom": {
          "accessToken": "860b4a335f84939014ea7627b900d5d8"
        },
        "createdAt": "2023-03-28T23:31:33.108Z",
        "modifiedAt": "2023-03-28T23:31:33.108Z"
      },
      "custom": {
        "type": "INDIVIDUAL",
        "path": "jane-smith"
      },
      "questions": [
        {
          "key": "coverPhoto",
          "text": "coverPhoto"
        }
      ],
      "marketing": {},
      "createdAt": "2023-03-28T23:31:33.480Z",
      "modifiedAt": "2023-03-28T23:31:33.480Z"
    }
  ],
  "custom": {
    "apiSource": "profile.created",
    "transactionId": "accbb680-cdc0-11ed-943f-cb69108336f6"
  },
  "createdAt": "2023-03-28T23:31:33.480Z",
  "modifiedAt": "2023-03-28T23:31:33.480Z"
}

At this point, we will track what is happening via the notification's Execution Log. This can be viewed by opening a notification and clicking the tab labelled "Execution #1". If there have been failures, there may be multiple execution logs as MoveData is designed to try and process a failed notification multiple times.

Platform Key Check

MoveData always tries to use a platform key as its primary matching rule. A platform key is a unique identifier provided by the platform responsible for creating the original notification to MoveData. In the Jane Smith example, we could see a key value in the MoveData notification for Jane' details ("key": "ac92f340-cdc0-11ed-943f-cb69108336f6"). A good reason for using a key over email matching or similar is that we can be certain the notifying platform is say this person is and has always been known to us via this key. This is useful when a contact changes their maiden name and email as it will continue to successfully match and update their details appropriately.

MoveData will use this key to construct a unique MoveData platform key to check to see if Jane already exists.

Using lightning flows, the system has constructed a unique MoveData platform key (raisely:ac92f340-cdc0-11ed-943f-cb69108336f6) and attempted a duplicate match.

Salesforce Duplicate Matching

If a MoveData platform key has not been able to create a match, MoveData will execute a Salesforce Duplicate Match. This will be performed using the built-in Salesforce Duplicate Rules which can be found at Salesforce Setup -> Data -> Duplicate Management -> Duplicate Rules / Matching Rules.

For Jane Smith's notification, we can see in the execution log that MoveData has executed the Salesforce Duplicate Matching Rules.

We can see that Salesforce executed the Lead & Contact Match Rules with zero duplicates detected. At this point, all duplicate detections are complete and the notification would result in a new record being created.

Practical Examples

No Match Example

This example extends on the previous Sequence Walkthrough. Using Jane Smith's notification, we have performed a Platform Key and a Salesforce Duplicate Matching Rules check with no matches.

The next action would be to map the notification to a record then create this as a new record in Salesforce. The Platform Key would be persisted so if there are any updates to the Jane' detail in the upstream platform, we would cleanly and easily be able to match using the Platform Key.

Platform Key Match Example

If Jane' record in the fundraising platform had previously been processed by MoveData, we would have the contact stored with the Platform Key.

We can see that the Platform Key has been constructed and that the subsequent step after the Platform Key duplicate match has resulted in an Existing Record entry, noting the current data including the record's ID.

This record will be used and updated with the data contained within the notification.

Salesforce Duplicate Match Example

If Jane existed in Salesforce but we had never received a notification about her via MoveData, we would have to rely on the Salesforce Duplicate Rules to successfully perform a duplicate match.

The system will construct a Platform Key and fail to perform a match. Subsequently, the system will execute the Salesforce Duplicate Rules.

In the above excerpt, we can see when the Salesforce Duplicate Rules were executed there was a 100% confidence match on a contact record named Jane Smith with the record ID of 0035g00000ttrD5AAI. The Salesforce Duplicate Rule match has resulted in an Existing Record entry, noting the current data including the record's ID.

This record will be used and updated with the data contained within the notification.

Failure to Match

The most likely scenario for a failure to match a notification with an existing record is that the Salesforce Duplicate Rules aren't configured correctly. Using the Sequence Walkthrough as a guide, you should be able to confirm this via your execution logs.

If you are certain the contact was created via the same platform and there is a missing key, there may a logic issue with your customised Duplicate Matching lightning flows.

If you are unable to resolve this problem using this guide, you may need to engage your Salesforce partner or MoveData Support as a paid engagement to resolve the issue.

Last updated