, “You have permission to send”, Acorel
Gratis demo

A year ago, on May 25, 2018, the General Data Protection Regulation (GDPR) was implemented. This law embodies data protection and the provision of marketing materials. It is the responsibility of each organisation to comply with this legislation, and one way of doing this is to use marketing permissions. With marketing permissions you can control the information and advertisements that are offered directly to your customers using e-mail, fax or phone calls. In this blog I will explain how to maintain marketing permissions in SAP Sales Cloud via your web page.

If you want to perform any kind of marketing activity, you need to make sure that your customers gave permission to be contacted. In SAP Sales Cloud personal data is stored on the contact object including the marketing permissions. You can allow contacts to modify their personal data on your web page. For example, subscribe for a newsletter, change preferences or opt-out. But wouldn’t it be ideal if these permissions are automatically stored in SAP Sales Cloud?!

The interface we need, sends messages to SAP, returns data from SAP, shows the information on your web page, and then stores the new/changed data back in SAP. Prerequisites are that communication systems and arrangements are installed. It is possible to use OData services, but in this blog I will solely focus on the standard SOAP web services used for SAP Sales Cloud.

Subscription of a customer

The subscription of contacts requires some basic personal information. To create contacts in SAP Sales Cloud we need, at least, a last name and e-mail address that we use to identify the contact. Your company can decide which information is further needed to subscribe and show those fields on the web page. In this example, known customers are stored on the contact object in SAP and new subscribers as individual customers, but you can also decide to create leads instead.

There are two scenarios possible: a new subscription and the change of an existing subscription. In figure 1 you can see how a subscription process can look like.

, “You have permission to send”, Acorel
Figure 1 Subscription Process

New subscription

Step 1: Check if the e-mail address already exists in SAP Sales Cloud
The web service Query Business Partner (FindBusinessPartnerByEmailURI_Sync) is used to find business partner data using the e-mail address the subscriber used on the web page.

Step 2: Return e-mail address existence
If the e-mail address is found in SAP, the web service Query Business Partner will return 1 or multiple <CallingBusinessPartner> tags. Contacts and individual customers are identified with category code 1 and only contacts and customers will be checked. Later in this blog I will explain what happens when you change an existing subscription.

If an e-mail address is not found, the return message shows the following:

, “You have permission to send”, Acorel

Step 3: Show new subscription page
If no e-mail address was found: show the new subscription page where the subscriber can fill in the necessary fields. You can also, for example, let customers select their areas of interest with help of marketing attributes. Furthermore, make sure that customers agree on the terms and conditions for subscription. Then, submit the subscription.

Step 4: Send confirmation e-mail
Your company can decide to use a double opt-in procedure in which the system sends a confirmation e-mail to the subscriber. This e-mail contains a temporary link which is needed to finalise the subscription process. In this case, you need to add extra validation steps.

Step 5: Receive confirmation email
After submitting, the subscriber receives a confirmation e-mail. This e-mail could contain an URL to unsubscribe.

Step 6: Send subscription to SAP
The web page will now send the stored data to SAP. To store personal data use web service Manage Accounts. The web service Manage Marketing Permissions is used to send channel information to SAP. Use <UUID> from response Manage Accounts to use as value for <BusinessParnterUUID>. For channel permissions <MarketingPermissionCode> use 1 for OPT-IN and 2 for OPT-OUT.

When you want to use marketing attributes to let customers subscribe to different areas of interests, you can use the web service Manage Attribute Assignment. To add new values the UUID from the attribute and attribute set are needed. For this, you can use Query Attribute Set and Query Attribute.

Step 7: Save new subscription
The data of the new subscription has been saved in SAP.

Step 8: Show confirmation and send confirmation e-mail
The system shows a confirmation message and sends a confirmation e-mail to the contact.

Change subscription

Step 1: Check if e-mail address already exists in SAP
The web service Query Business Partner (FindBusinessPartnerByEmailURI_Sync) is used to find business partner data using the e-mail address the subscriber used on the web page.

Step 2: Return e-mail address existence
If the e-mail address is found in SAP, the web service Query Business Partner will return 1 or multiple <CallingBusinessPartner> tags.

Step 3: Determine SAP record
The system checks if the address belongs to an individual customer or contact (use Query Contact). In this case, only the current business characteristics: ContactPersonIndicator and CustomerIndicator should be considered as valid e-mail address. The tag <CurrentBusinessCharacters> determines if the result belongs to <ContactPersonIndicator>true</ContactPersonIndiciator> or an Individual Customer <CustomerIndiciator>true</CustomerIndicator>.

Step 4: Send e-mail with link to change the subscription
Send an e-mail with a link to the web page to change marketing permissions or other personal data.

Step 5: Receive e-mail to change subscription
The contact receives an e-mail with the URL to change his or her subscription.

Step 6: Click on link and open web page
When the contact clicks on the URL the web page opens.

Step 7: Get subscription information
To get all relevant data from SAP, we use the web service Query Marketing Permission Channel Permission. The selection is made by the UUID given via the URL. Based on the <BusinessPartnerRoleCode>, thus contact or individual customers, the web service Query Contact or Query Account should be used. Additionally, we need to query the values for <BusinessPartnerUUID> to get all relevant information.

Step 8: Post subscription information
SAP then returns all data to the calling program. For channel permissions use the tag <CommunicationChannelCode> for values INT (e-mail), LET (Letter) and SMS (texting). Tag <MarketingPermissionsCode> stands for the permission itself (1 is OPT-IN, 2 is OPT-OUT, 3 is Undefined).

Step 9: Show subscription information
The information that was collected by SAP will be shown on the web page. The contact can see all relevant information.

Step 10: Change subscription information and submit
The contact changes the subscription information (or unsubscribe).

Step 11: Send subscription information to SAP
The web page sends the changed data back to SAP. When an individual customer changed data, we use Query Manage Account. When a contact changes data, use Query Manage Contacts. Use the values for tags <UUID> and <ChangeStateID> from Query Accounts result.
The web service Manage Marketing Permissions sends Channel and Type info to SAP. You can use the values for tag <ChangeStateID> and <UUID> from Query Marketing Permissions and use <UUID> from Query Accounts or Query Contacts to use as value for <BusinessPartnerUUID>. Again, to update the channel permissions use <MarketingPermissionCode> 1 for OPT-IN and 2 for OPT-OUT.

Step 12: Show confirmation and send e-mail
Confirm the customer about the changes that have been made.

Want to know more?

As mentioned in the introduction, it is the responsibility of the companies to comply with the regulations regarding data and privacy management. In this blog I explained only one way of how to maintain marketing permissions in SAP Sales Cloud. But of course, it depends on your organisation how your process will look like. At Acorel, we have the knowledge and expertise to help you in this journey, so feel free to contact us!

, “You have permission to send”, Acorel

Joelle Small