Updating an email address for a contact via the API

I found an article on updating contact info in the docs
Update a contact (activecampaign.com)

But how can we update (change) the users email address via the API from the old email address to the new? Is there an API process explained in the docs for this?

Many thanks

Hi @nationalffaorganiza1 Thanks for reaching out! This isn’t called out directly in the documentation - you’ve already found the correct call to use to make this change! Just make sure that you use the ContactID in your URL - this will allow you to target the correct contact to change the email address for the existing contact! For example, if I wanted to target a contact by ContactID to make an update, it might look like “https://youraccountname.api-us1.com/api/3/contacts/1” versus “https://youraccountname.api-us1.com/api/3/contacts”.

1 Like

If you don’t know the ID of the contact, you may have to make this GET call in the API first: /api/3/contacts?filters[email]=person@example.com that will return you a json object, this will return you a list called contacts and it will most likely be the first item on the list, ie: contacts[0] then you get grab it here: contacts[0].id, that is the id you need to make the call to update https://youraccountname.api-us1.com/api/3/contacts/{ID HERE}

Hope this helps! Reach out any time with questions.

1 Like