If you’d like, you can enable profile deletions in Identity Cloud to sync with Salesforce Marketing Cloud (SFMC). This means when a user record is deleted from the Identity Cloud database, the same subscriber will also be immediately deleted from SFMC. This is an optional, additional configuration.
Similar to the SFMC Data Sync, this is a one-way sync from Identity Cloud to Marketing Cloud. Syncing deletes from Marketing Cloud back to Identity Cloud is not supported.
Important Note! In order to sync deletes, you MUST map the Identity Cloud uuid
to the SubscriberKey
in Marketing Cloud. (This refers to the subscriberMapping
in the expression file.) If you can not use the uuid
as subscriber key for any reason, then the SFMCDeleteSync pipeline will not work for you.
In order to enable the delete sync, you’ll need to complete the following tasks:
You may have already copied the SFMCDeleteSync and SFMCDeleteSync_DataExtensions pipelines to your project folder in the Copy pattern step. If these pipelines are already in your project folder, skip to the next step.
If not, let’s copy the pipelines over:
In the SnapLogic Manager tab:
In the left navigation under SFMC Data Sync, click on your project folder to open it
In the main panel, click on the Tasks tab
In the upper right corner, click the Create icon ()
Fill out the necessary settings:
Setting Name | Setting Value Instructions |
---|---|
Name | | Give the task an appropriate name you’ll recognize later | |
Pipeline | | Select SFMCDeleteSync | |
Snaplex | | Select Cloud-AkamaiProd | |
Run policy | | Select Triggered | |
Timeout | | Please leave this blank; Adding a value here can cause timeout errors when the pipeline runs | |
Notifications | | You can put one or more email addresses here if you want to receive additional communications about the status of each delete sync More Info: You may not want to receive emails every time the pipeline starts, completes, and stops, but it could be useful to receive an email when the pipeline fails. Note that the integration pattern is already designed to send an error notification if there is a failure along the pipeline (e.g. configuration issue, cannot connect to SFMC account, etc). If you select "Failed" here, you'll also receive an email if there's a failure outside of the pipeline (e.g. an issue with the node the pipeline is running on). |
Debug | | Optional settings | |
Bearer Token | | Leave this as-is; you’ll use this token later | |
Click Create
When you create a triggered task, this generates a unique URL and bearer token that can be used to trigger the pipeline. We’ll use this information in next steps. To see these details:
To trigger the deletion in Marketing Cloud, you must set up an entityDeleted subscription with Webhooks v3. To do this, you’ll need to make two API calls to Identity Cloud.
If you’re not sure what your region is, you can confirm it in the Identity Cloud Console:
oidc_url
setting under Global Settings in the Custom Settings section
oidc_url
.
us
.janrain.com/my-customer-id/loginWhat if I don’t have an oidc_url setting? You may not have this setting if your original implementation of Identity Cloud predates Hosted Login. If you do not know your region and do not know how to find it, please reach out to your Akamai Identity Cloud representative and we’ll be happy to help.
Similar to your region (above), your Customer ID can be found within the oidc_url
.
* Example: https://v1.api.us.janrain.com/my-customer-id
/login
It can also be found in the customer_id
setting in the Identity Cloud Console:
customer_id
setting under Global Settings in the Custom Settings section
What if I don’t have a customer_id setting? You may not have this setting if your original implementation of Identity Cloud predates Hosted Login. If you do not know your customer ID and do not know how to find it, please reach out to your Akamai Identity Cloud representative and we’ll be happy to help.
First, make a call to the /login/token endpoint to obtain an access token to authorize your webhook configuration.
configuration_client_id
and configuration_client_secret
must be combined with a colon in between (id:secret) and then base64 encoded.
You can find the Configuration Client ID and Secret in the Identity Cloud Console:
configuration_client_id
and configuration_client_secret
settings under Global Settings in the Custom Settings section
What if I don’t have these settings? You may not have these settings if your original implementation of Identity Cloud predates Hosted Login. If you do not know your configuration client ID and secret, and do not know how to find them, please reach out to your Akamai Identity Cloud representative and we’ll be happy to help.
Postman will create the authorization code for you. All you need to do is:
configuration_client_id
as the Username and your configuration_client_secret
as the Password
When you Send the call, Postman will generate the Authorization header for you, and this will override the Authorization template from the imported call.
curl -X POST \
https://v1.api.us.janrain.com/my-customer-id/login/token \
-H 'Authorization: Basic AUTHORIZATION CODE' \
-H 'Content-Type: application/x-www-form-urlencoded' \
-d 'grant_type=client_credentials' \
-d 'scope=*:webhooks/**'
Then, make a call to the /webhooks/subscriptions endpoint using the POST method to create and enable your webhook subscription.
access_token
you received from the previous call.curl -X POST \
https://v1.api.us.janrain.com/my-customer-id/webhooks/subscriptions \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"enabled": true,
"endpoint":"my-SnapLogic-Cloud-URL?bearer_token=my-SnapLogic-Bearer-Token",
"events": ["entityDeleted"],
"title": "SFMC Delete Sync Subscription"
}'
Note that the endpoint
value consists of the Cloud URL for your triggered task plus a URL parameter called bearer_token
. The value of this parameter is the Bearer Token from your triggered task. This token can be found in one of two places:
Example endpoint
:
https://elastic.snaplogic.com:443/api/1/rest/slsched/feed/AkamaiProd/SFMC%20Data%20Sync/My%20SFMC%20Sync/My%20SFMC%20Delete%20Task?bearer_token=AbCDefGhI1jkl2MnopqRst3uV4wxYZaB
Now that you’ve copied the pipeline to your project folder and created the triggered task and webhook subscription, the delete sync is enabled.
To test the delete sync:
SubscriberKey
matches an existing uuid
in Identity Cloud. Since a successful test will result in the deletion of both, which is irreversible, make sure this is a throw-away account!Your project folder should now contain: