Skip to content

Payload Contract

Salesforce sends enrichment requests to n8n using the DataEnrichmentWebhook Named Credential.

Request

The request body is intentionally small. n8n should use the Salesforce record Id to load the current source record before enrichment.

{
  "data": {
    "entity": "lead",
    "id": "00Q000000000000AAA"
  }
}

Supported entity values:

  • lead
  • contact
  • account

For Lead enrichment, n8n should read at least:

  • FirstName
  • LastName
  • Company
  • CountryCode
  • Website
  • LinkedInCompanyProfile__c

For Contact enrichment, n8n should read at least:

  • FirstName
  • LastName
  • AccountId
  • Email
  • MailingCountryCode

For Account enrichment, n8n should read at least:

  • Name
  • BillingCountryCode
  • Website
  • LinkedInCompanyProfile__c

Callback

n8n writes the enrichment result back to Salesforce by creating or updating the matching enrichment object:

  • LeadEnrichment__c
  • ContactEnrichment__c
  • AccountEnrichment__c

The enrichment record should set:

  • source lookup field, for example Lead__c
  • enriched field values
  • DataEnrichment_LastEnrichment__c
  • status fields, where applicable

Salesforce trigger logic then syncs accepted values to the source record and updates the related EnrichmentRun__c.