on 2021 Jan 07 12:45 PM
Hello Community,
I'm trying to set up a new sync between our SAP Commerce (On Premise) and the SAP Marketing Cloud using the SAP Cloud Platform Integration but got some problems on the sync of B2BUnits (Commerce) to Corporate Accounts (Marketing Cloud):
Until now we used the CUAN Import Service for syncing everything. For B2BUnits we used the entry "Company" in the CUAN Import Service Definition ( <MarketingCloudInstance>/sap/opu/odata/sap/CUAN_IMPORT_SRV ). Because CUAN ist deprecated and we now have the ability to use a CPI, I built the most Integration Flows (e.g. Products, Customer,...) successfully from standard Integration Flow Package "SAP Commerce Cloud Integration with SAP Marketing Cloud". But there is no standard for B2BUnits / Accounts.
With some struggle I built a working IF for B2BUnits using the Marketing Cloud API "API_MKT_CORPORATE_ACCOUNT_SRV" as destination in Marketing Cloud (<MarketingCloudInstance>/sap/opu/odata/sap/API_MKT_CORPORATE_ACCOUNT_SRV). The data from Commerce gets mapped fine and the output looks good. But in the Marketing Cloud Import Monitor I see an error message:
"Import of interaction contacts of type 02 is not supported"
There are not more information about the error. But i know from documentation that interaction contact type 02 means company.
So I'm wondering about this error.
Am I wrong with the assumption to sync our B2BUnits into the Marketing Cloud Corporate Accounts? As far as I know the CUAN Import did exactly this.
What is the correct API to sync our B2BUnits to Marketing Cloud to get the same behaviour like in CUAN Import? We need the creation of new accounts as far as updates on existing accounts.
And maybe an additional question: what is the best way to link our b2b customer to their B2BUnits / Accounts? In CUAN Import it was very simple: the entry "Contact" had the 3 fields "CompanyId", "CompanyIdOrigin" and "CompanyMainRelation" to define the exact relation of customers to their account.
Some additional information:
I added an sample XML payload the Integration Flow Created (before OData conversion):
I tried other methods than PATCH, like POST and MERGE, but without success.
I also found the API CUAN_BUSINESS_PARTNER_IMPORT_SRV, where I was able to import company data, but there are some missing fields in the APi definition like Additional IDs, we need to ensure a correct merging of our imported data with other external data sources.
I would be grateful for any help.
Best Regards
Torsten
Request clarification before answering.
Hi Torsten,
did you also try to create a Corporate Account using Postman and the /$batch endpoint before you tried it via CPI? Same result?
I will try to create one using your payload and give you some feedback. I never had that error message.
Regarding your second question I can tell you how we are doing it:
In the "Replicate-Customer-from-SAP-Commerce-Cloud-to-SAP-Marketing-Cloud" iFlow the API_MKT_CONTACT_SRV is used. There in mapping on MC-side you have the fields CorporateAccountID and CorporateAccountOrigin for the Contact. For the Origin you set an origin according to your needs. For the ID we use the first part of the field uid of the Customer from Commerce.
In our case the B2B Unit ID in Commerce is the same as in ERP. The field uid consists of two parts: The B2BUnit-ID and the Customer-ID, divided by a Slash. So we use SAP_ERP_CUSTOMER as Origin and than the first part (before the /) as ID, so that the Customer is then assigned to the Corporate Account from ERP.
Maybe that already helps.
BR Tobias
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Tobias,
thanks for your answer and sorry for this late reply.
You gave me the right hint:
In standard Integration Flow for Customers / Contacts version 4 of the API_MKT_CONTACT_SRV is currently used. But in this version the fields CorporateAccountID and CorporateAccountOrigin are not provided. There is only a UUID field for the relation to the Corporate Account.
So I switched from version 4 to 3 (and also from version 3 to 2 of API_MKT_CORPORATE_ACCOUNT_SRV) to use the sync of data like in CUAN Import. The creation of Accounts is now done by the import of our B2B-Customers as dummy accounts with ID and Origin. In sync of B2B-Units the remaining informations will be filled up later.
For further reader: be aware of donwgrading the API version. In the Marketing Cloud it is not possible to override data that was previously transferred with a higher API version.
In my case I needed to delete all customer data on our Q-system.
Best regards
Torsten
Hi Torsten,
I am having the same problem as you, could you explain me how you have solved it?
Thank you very much.
Best Regards,
Ángela
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Angela,
I described my solution in a comment above:
I use the APIs API_MKT_CONTACT_SRV in version 3 and API_MKT_CORPORATE_ACCOUNT_SRV in version 2.
While the sync of our contacts i fill the 2 fields CorporateAccountOrigin and CorporateAccountID on our B2B customers ( see definition of API_MKT_CONTACT_SRV here). This creates a dummy account in the SAP Marketing Cloud only with this 2 properties.
In sync of our B2B units I use the same ID and Origin to sync the remaining account data.
Hope this helps.
Best Regards
Torsten
Thank you very much for the help,
As you mentioned, I have changed the Contacts API to version 3 but now I have a 500 error, I have looked at the communication agreements and in the SAP_COM_0082 agreement the Contacts API version 3 does not appear, so I have added the SAP_COM_0207 agreement, but the error continues.
Any ideas on what could be going on?
Thank you very much.
Ángela
Hi Angela,
did you use a higher API version before?
As like I wrote on a comment above it is not possible in Marketing Cloud to override data of contactes, wich was imported with a higher API version.
In my case I deleted all contact data from our Q system to solve this.
Also search for Logs in the Marketing Cloud Apps "Import Monitor" or "Application Log". If you can't find anything there the problem may in the Cloud Platform Integration / Integration Flow. Switch there on TRACE mode. Also look at the System Logs of CPI. This helped me to find some errors.
Best Regards
Torsten
Hi Torsten,
What does your payload look like after the OData conversion?
Does it look like the sample payload on https://help.sap.com/viewer/0f9408e4921e4ba3bb4a7a1f75f837a7/latest/en-US/fb8c4f4b1d454cf8a26eefd517... ?
I notice in your xml before odata conversion that there is a field "number of employees", that sounds like a custom field. Did you enable the usage of that custom field for the corporate account API?
Kr,
Joyca
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Joyca,
thanks for your answer and sorry for the late reply.
I solved my problem and described my solution in a comment above.
But a little note: the field "NumberOfEmployees" is not a custom field. It is standard in Version 2 and 3 of API_MKT_CORPORATE_ACCOUNT_SRV. Maybe you can use it on your own projects, in case you didn't know it yet 🙂
Best regards
Torsten
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.