4

The current deletion framework that was added last year does deletes entire contacts. A contact deleted this way is deleted from:

  • All Contacts
  • All Subscribers
  • Mobile Connect

I have a problem where the cleanest solution would be to remove a problematic contact from Mobile Connect only (leaving the contact in All Subscribers and All Contacts).

Is there a way of doing this currently?

I can't seem to find anything like that in the Rest API and both Platform and Core functions.


Update after using the endpoints pointed out by Rain.

I used the /contacts/v1/contacts/actions/delete?type=keys endpoint with the following payload:

{  
   "ContactTypeId":0,
   "values":[  
      "ContactDeletionTest"
   ],
   "DeleteOperationType":"AttributesOnly",
   "optionValues":[  
      {  
         "adapterID":7014,
         "adapterKey":"ContactDeleteProcessor.MobileConnect",
         "values":[  
            {  
               "iD":"2f2e5b49-b2d3-4dad-8781-876bc9cd1525", 
               "value":"True"
            },
            {  
               "iD":"b0580712-a1fe-4bc0-9857-6dcfcd110439",
               "value":"True"
            }
         ]
      }
   ]
}

The two values in options.values represent MobileConnectAddresses and MobileConnectSubscriptions respectively.

With "DeleteOperationType":"AttributesOnly" and the email channel not mentioned anywhere, I posted this and my test contact got removed entirely (I've added a All Subscriber instance as well and it was deleted too).

2

Can't say if this will work, but when looking at getDeleteOptions there are two parameters called ListType and ApplicationContext. On the latter, there is the ApplicationID that can be provided.

Looking at the response there is the adapterKey with value ContactDeleteProcessor.MobileConnect that you'll probably need to target.

Eliot has posted an example calling both ContactDeleteProcessor.ContactBuilder.Roots and ContactDeleteProcessor.MobileConnect adapters together in the API call, so I would give a try (on some test Contact) by only targeting the adapter for MobileConnect through the adapterID attribute and see if that works.

  • 1
    Hi, thanks for the response. For some reason I thought this old endpoint was no longer active. I tried it out though and it also deleted my All Subscriber contact instance. I updated the case description to show the payload that should only remove the MobileConnect instance. – Rafał Wolsztyniak Sep 11 at 11:34
0

After presenting this problem to SF Support, an agent confirmed it's currently only possible to remove the entire contact:

From consulting with our internal resources they clarified that unfortunately the only valid/supported DeleteOperationType is the current 'ContactAndAttributes', which is also the default one. Therefore currently even when submitting a request with DeleteOperationType as "AttributesOnly", the contact will be processed as standard contact deletion, which is the full deletion of the contact, including also Email Channel.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.