Skip to main content
Solved

How to remove links from contacts via the Front API?

  • February 26, 2025
  • 3 replies
  • 176 views

sudhanshu
Forum|alt.badge.img+2

Hey,

 

We had previously added a few links to contacts in our Front instance. However, we wish to remove them now. 

The API explains how that can be done with lists, but doesn’t really go into contact links.

 

How can we achieve this?

Best answer by clemente_ortuzar

The 'links' for a contact are always completely overwritten when you update them. The update doesn't add to the existing links; it replaces them.

For example, if your contact had links: [“123”], then:

  • Updating with [] (empty) results in no links.
  • Updating with ["456"] results in only link ["456"].
  • To add 456 and keep 123, you must update with ["123", "456"]
View original
Did this topic help you find an answer to your question?

jason
Forum|alt.badge.img+8
  • Fronteer
  • February 26, 2025

If you’re using the Update Contact API endpoint, the value passed in the links array is what you’re setting that Contact’s Links to.

So, if you pass an empty links array - you’ll clear their list of links;

PATCH /contacts/crd_12345

{
  "links": []
}

 


sudhanshu
Forum|alt.badge.img+2
  • Conversationalist
  • February 27, 2025

But if I give it an updated list of links, it will not delete the ones not present in the new list, right?


clemente_ortuzar
Forum|alt.badge.img

The 'links' for a contact are always completely overwritten when you update them. The update doesn't add to the existing links; it replaces them.

For example, if your contact had links: [“123”], then:

  • Updating with [] (empty) results in no links.
  • Updating with ["456"] results in only link ["456"].
  • To add 456 and keep 123, you must update with ["123", "456"]

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings