How I can add existing email id(contact) with other contact list via API

Regular Participant

How I can add existing email id(contact) with other contact list via API



I have one contact (email id ) which is already added in some contact list. Now I need to add same email id in another contact list. How we can do with API?


Hello Nishant,


We  used a unified contact object model (see here), which means that once created in a given account, contacts are then always associated with the account, even if their status and list membership changes. In this model, lists are attributes of the contact. Based on HTTP standards, creating resources (like contacts) is done with POST requests, while updating their attributes is done with a PUT request.  That is how our API works.  So, once a contact is created in an account, you would need to make a PUT request to add additional lists.


Please note that because a PUT request will REPLACE current field contents with the new data you're providing, the best approach for a signup form integration that will allow updates of contacts to add additional lists is the following:


1) GET request to search for contact by email address (see here).


2) If the contact already exists in the account, which can be determined by the status code of the response, make a GET request for the details of that contact (see here).


3) Change any information in the XML returned from number 2 above, and use that to make a PUT request to add the contact to a new list (update the contact, essentially - see here).


4) If the contact is not already in the account, do a POST request to create the contact and add them to whatever lists you desire (or they have selected, if your form includes this option).


Let us know if you have more questions.

Mark Coleman
Support Engineer
Developer Portal

View API documentation, code samples, get your API key.

Visit Page