Software AG Products 10.7 | Integrating On-Premises and Cloud Applications | Integration Cloud | Recipes | SAP C4C Contact to Marketo Lead Data Sync
 
SAP C4C Contact to Marketo Lead Data Sync
This section describes the recipe for the data sync between SAP Cloud for Customer Contact business object and Marketo Lead business object.
SAP Cloud for Customer (C4C) is a cloud solution to manage customer sales, customer service, and marketing activities efficiently and is one of the key SAP solutions to manage customer relationships.
Marketo provides software platforms and technologies designed for marketing departments such as account-based marketing, which includes email, mobile, social, digital ads, web management, and analytics.
Business Use Case
The business purpose of this integration is to extract SAP Cloud for Customer Contact records and upsert them to Marketo as Person records.
Custom Fields
Contact can be linked to some owner or Employee and Account, hence it is always recommended to sync Employee and Account objects before syncing the Contacts to Marketo.
This recipe syncs Contact object in Marketo with the below mentioned custom fields.
On SAP C4C
Comments
MKTOContactID
Custom field in SAP C4C for Contact records to hold the Marketo Contact records id.
ZLeadScore
Custom field having the lead score for a Contact.
ZAcquisitionProgram
Custom field having the acquisition program id for a Contact.
ZAcquisitionDate
Custom field having the acquisition date for a Contact.
ZSource
Custom field having the source of a Contact.
On Marketo
Comments
contactHouseNumber
Custom field in Marketo to hold the house number for SAP C4C Contact.
o c4CContactID
Custom field in Marketo for Contact records to hold the SAP C4C Contact records id.
c4CContactObjectID
Custom field in Marketo for Contact records to hold the SAP C4C Contact object id.
isDeleted
Custom field in Marketo to indicate that record has been obsoleted in SAP C4C.
Required recipes to run before Opportunity
SAP C4C
Marketo
Required Fields
Comments
Employee
SalesPerson
externalSalesPersonID
If employee is synched in Marketo, then only the Opportunity owner will be updated at Marketo from SAP C4C.
Account
Company
externalCompanyID (SAP ProspectPartyID)
If account is synced in Marketo, then only the Opportunity company will be updated at Marketo from SAP C4C.
Contact
Lead
c4CContactID (SAP PrimaryContactPartyID)
If contact is synced in Marketo, then only the Opportunity will be upserted at Marketo from SAP C4C.
Product Compatibility
The recipe is tested for SAP Cloud for Customer product version 1908.04.0006. Hence the recipe is compatible to run for the tested and older versions of the product.
Contact Sync Flow
This integration "SAPC4CContactToMarketoLeadDataSync" is designed to run for initial as well as ongoing sync. As part of the initial sync, all the active and obsolete Contact records present in SAP C4C will be synced to Marketo. On the other hand, as part of the ongoing sync, the updated and newly created and obsolete Contact records will be synced to Marketo for the provided date range. Once the record is successfully created in Marketo, it syncs back the Marketo Contact ID in the corresponding SAP C4C Contact record. (Custom Field: MKTOContactID).
Input Parameters
Sl.No
Parameter
Description
1
isInitialSync
Set to true in case of initial sync and to false in case of ongoing sync(true/false).
2
syncInterval
The sync interval can be entered either in hours/minutes/seconds or all of them and corresponding pattern and time zone if required.
3
logRecordStatusFlag
The log status of each record processed. It can either be true or false.
Operations Used
This recipe has a sub flow to handle the obsolete contact record in SAP C4C, that is, updateDeletedSAPC4CContactsToMkto.
Sl.No
Operations Used
Application
Description
1
querySAPC4CContact
SAP C4C
Queries SAP C4C Contacts.
2
upsertMarketoLeads
Marketo
Upserts Contact in Marketo and if Contact is obsolete in SAP C4C, it updates isDeleted flag to Contact record in Marketo.
3
patchSAPC4CMultipleContact
SAP C4C
Once record is successfully created in Marketo, it updates the Marketo Contact ID in the corresponding SAP C4C Contact record in the MKTOContactID custom field.
4
readMultipleEmployees
SAP C4C
Retrieves the Employee/Owner id for the provided UUID.
1. querySAPC4CContact
Input Filter parameter
Sl.No
Condition
Filter to query records from SAP
1
IsInitialSync = True
SAPC4CContact_To_MarketoLead : StatusCode ne '4'
updateDeletedSAPC4CContactsToMkto : StatusCode eq '4'
2
IsInitialSync = False
SAPC4CContact_To_MarketoLead : StatusCode ne '4' and ChangedOn ge datetimeoffset'%fromDateString%'
updateDeletedSAPC4CContactsToMkto : StatusCode eq '4' and ChangedOn ge datetimeoffset'%fromDateString%'
2. upsertMarketoLeads
Field Mapping
SAP Contact
MKTO-PERSON
StatusCode
Standard
obsoleteinC4C
CustomField
TitleCodeText
Standard
salutation
Standard
FirstName
Standard
firstName
Standard
MiddleName
Standard
middleName
Standard
LastName
Standard
lastName
Standard
Email
Standard
email
Standard
Phone
Standard
phone
Standard
Mobile
Standard
mobilePhone
Standard
Fax
Standard
fax
Standard
JobTitle
Standard
title
Standard
BirthDate
Standard
dateOfBirth
Standard
Street
Standard
address
Standard
City
Standard
city
Standard
StateCodeText
Standard
state
Standard
CountryCodeText
Standard
country
Standard
StreetPostalCode
Standard
postalCode
Standard
ConsentEmail
Standard
unsubscribed
Standard
ConsentTelephone
Standard
donotcall
Standard
ContactTextCollection - Text
Standard
mktoPersonNotes
CustomField
DepartmentCodeText
(Relation - CorporateAccountHas
ContactPerson)
Standard
department
Standard
EmployeeID (Employee)
Standard
externalSalesPersonId
Standard
HouseNumber
Standard
contactHouseNumber
CustomField
ZLeadScore
CustomField
leadScore
Standard
ZAcquisitionProgram
CustomField
acquisitionProgramId
Standard
ZAcquisitionDate
CustomField
mktoAcquisitionDate
Standard
ZSource
CustomField
leadSource
Standard
ContactID
Standard
c4CContactID
CustomField
3. patchMultipleContact
Once Contact records are successfully created in Marketo, update the Marketo ID to the corresponding SAP C4C Contact record in the MKTOContactID custom field.
MKTO - PERSON
SAP - CONTACT
LeadID
Standard
MKTOCompanyID
CustomField
4. readMultipleEmployees
If any contact has any owner/Employee, then we have to associate the same owner to the Contact record in Marketo as well. Now as we query Contact records from SAP C4C, we get the Owner UUID instead of the ID. Hence this operation gets us the Owner ID for the corresponding UUID and then maps it to the Marketo Upsert Lead call to associate it to the proper SalesPerson.
Usage Notes
*In order to add new standard or custom fields to the SAPC4CContact_To_MarketoLead integration, copy the required field and add it to contactList_NullMKTOID, contactList_WithMKTOID, contactList_WithOwner, and notSyncedcontactList_withOwner list while making the upsert API call to Marketo.
*In order to change or remove standard or custom fields from the SAPC4CContact_To_MarketoLead integration, remove the required field mapping and change or remove the field from contactList_NullMKTOID, contactList_WithMKTOID, contactList_WithOwner, and notSyncedcontactList_withOwner lists while making the upsert API call to Marketo.
*In order to add new standard or custom fields to the updateDeletedSAPC4CContactsToMkto integration, copy the required field and add it to contactList_NullMKTOID, contactList_WithMKTOID, contactList_WithOwner, and notSyncedcontactList_withOwner lists while making the upsert API call to Marketo.
*In order to change or remove standard or custom fields from the updateDeletedSAPC4CContactsToMkto integration, remove the required field mapping and change or remove the field from contactList_NullMKTOID, contactList_WithMKTOID, contactList_WithOwner, and notSyncedcontactList_withOwner lists while making the upsert API call to Marketo.