CRM and CX Blogs by Members
Find insights on SAP customer relationship management and customer experience products in blog posts from community members. Post your own perspective today!
Showing results for 
Search instead for 
Did you mean: 
As a business requirement, we needed to ensure the synchronization of marketing permission data(opt-in/out) between C4C and Emarsys. When a contact gets opted out via the unsubscribe link in an email campaign generated from Emarsys, the opt-in field in Emarsys is changed to false which means the contact has opted out.

For existing contacts, this information is held on C4C as a requirement for SAP Emarsys Account Engagement. And we need to ensure that when the contact unsubscribed on Emarsys, the contact should also be opt-out on C4C too. So that there are no inconsistencies between the systems.

Emarsys does not provide this auto-synchronization in the standard Account Engagement Integration service, which is why we will have a custom solution including the combination of An Integration Suite iflow and An Automation Program in Emarsys.

What Emarsys offers as an out-of-the-box tactic is to create an activity for your sales responsible employee to update the contact manually. And, this wasn't feasible for us. So, here is our custom solution that comes from this requirement.


Figma Schemas For the Whole Process:

Figma 1


Figma 2

Figma Link:


We are going to use standard C4C Odata Collections.


Required Collections:

For the current requirements following Odata collections will be used:

  • MarketingPermissionCollection

  • ChannelPermissionCollection

Endpoint for Marketing Permission Collection:

Endpoint for Channel Permission Collection:


Steps to go:

1. An Automation program created on Emarsys:

Basically, the program below checks if there is any data change in the standard opt-in field in Emarsys, if there is any change, the contact enters the program. Then, with a quick filter, we check if the contact is an existing contact in C4C. If the contact doesn’t exist in C4C, no need for synchronization, right?

After that, we use a filter switch to see if the opt-in is false. If that is the case, email opt-in was updated to opt-out in C4C. If on the contrary,  the opt-in field was changed from false to true, the contact follows the exclude path, and the contact was opted-in automatically in C4C. We are using webhooks after the filter switch to make the necessary connections.


Auto Opt-In/Out Sync Automation Program


2. Webhook configuration:

Webhooks basically are HTTP POST call triggers that you can use in your automation programs. It is very useful as Emarsys has not many development options. It helps you to connect different solutions to Emarsys and triggers API calls in your automation programs and interactions.


For auto sync, basically, we are sending C4C Contact ID and the opt-in field value in the payload to an Integration Suite endpoint in order to start the iflow process.



You will also need to provide the Integration Suite runtime endpoint and User Credentials for the deployed iflow so that Emarsys can trigger the endpoint.

Iflow Endpoint



3. SAP Integration Suite Iflow Design:

As part of our design parameter, on the integration flow, we basically first check if the contact has a marketing permission on C4C or not.  And we should get the ObjectID from ChannelPermissionCollection node if the contact has a marketing permission.$filter=Ch... eq 'INT' and MarketingPermission/BusinessPartner_ID eq 'contactID'&$expand=MarketingPermission


If the contact has the marketing permission already, we basically update the marketing permission with new data that comes from Emarsys with a PATCH ODATA Call.'ObjectID')
"Channel": "INT",
"Consent": "2"


If somewhat the contact doesn’t have the marketing permission, we will create it with a deep insert to ChannelPermission.

ODATA POST method:
"BusinessPartner_ID": "10312926",
"ChannelPermission": [
"Channel": "INT",
"Consent": "1"


Iflow Design:



With this custom solution, we will not have to worry about any synchronization problem between Emarsys and C4C regarding marketing permissions. As our opt-in field is very important in Emarsys for email campaigns, we can not rely on manual intervention to do a sync. So, we are automating our process here. This will definitely make the maintenance of the data very easy.



Special thanks to Onur Yurt and Selçuk Eren for helping to develop the iflow.