cancel
Showing results for 
Search instead for 
Did you mean: 

How to upload marketing permission linking to the campaign?

Hi experts!

We want to upload manually marketing permission opt-out linking to the campaign. So we took InteractionSourceObject from EMAIL_OUTBOUND IA Type of the contact to whom the email was sent and use it as PermissionSourceObject into PUT MarketingPermissions method.

A part from request:

{
"PermissionGranted" : "N", 
"PermissionUTCDateTime" : "2021-01-20T12:43:00",
"PermissionSourceObjectType" : "CUAN_CAMPAIGN_OUTBOUND",
"PermissionSourceObject" : "E02EEC8DE58D61D0CDC50FE9015BA28CC28BCC34"
}

But we are facing with problem. Marketing Permission Opt-out was created but without linking to the campaign. How to upload marketing permission linking to the campaign?

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member226
Employee
Employee

Hello,

I never tried with the new public API but it is certainly possible with older API cuan_import_srv.

You can simply make a POST call to https://<MktHost>/sap/opu/odata/sap/cuan_import_srv/ImportHeaders with the following payload. Here InitiativeId represents campaign ID to be associated with the opt-out interaction.

{
   "Timestamp":"2021-01-21T12:01:00",
   "SourceSystemType":"EXT",
   "SourceSystemId":"ANY",
   "Interactions":[ 
      { 
         "CommunicationMedium":"WEB",
         "ContactId":"sap.sk@123.com",
         "ContactIdOrigin":"EMAIL",
         "InteractionType":"MKT_PERM_OPTOUT",
         "MarketingPermissionCommunicationMedium":"EMAIL",
         "Timestamp":"2021-01-21T12:02:00",
         "InitiativeId":"0000001044"
      }
   ]
}