The Community is hosting an End of Summer sweepstakes! Participants must complete tasks to earn tickets that will enter them with a chance to win a free year of Constant Contact and other great prizes!*
*No Purchase Necessary. For Official Rules, visit here. Constant Contact’s End of Summer 2020 Sweepstakes ends on October, 20, 2020 at 11:50 PM EST.

Updating contact info

Highlighted
Occasional Contributor

Updating contact info

When I try to update contact info,  it gives me 201 error code but

1. I don't see any details my lists. why?

2. When update happnes it's not triggering emails but when creating it is. I'm missing setting or so?

3. How can I differenciate whether it's registered(there in active list) and registered but not there in active list.

Ex: test@example.com is registered and showing in list then I don't want to update but

     registered and not showing in list then want to update the deatils. I don't know how this work. how to differenciate code wise?

4.Can we remove particular contact(ex:test@exmple.com) from CC not by using code but by taking CC help or so(Because just 5 or 6 needs to be removed so that they can registered again).

 

Thanks!

3 REPLIES 3
Highlighted
Employee

Re: Updating contact info

Hi,

 

1.  The API was designed not to have any content in the response when an update to a contact is successful.

 

2.  Make sure you have your opt in source as "ACTION_BY_CONTACT" when updating contacts.  If a contact's list subscription is updated, they will then receive a confirmation email letting them know of the change.  Existing contacts that are updated, not newly added, will not receive a welcome email.

 

3.  You could save yourself the logic code work if you simply add all contacts to the list you want them to be on, regardless of whether they were on the list or not.  Otherwise, you could retrieve the contact by ID after you do the search by email address, check to see which list nodes are there, and then make an update if they're not on the list.  If you don't know how to do that, the only downside to adding them to a list they were already on is that you're making an unnecessary call to our servers.

 

4.  There is no way for anyone, internally, externally, or through the API, to remove a contact entirely from an account for testing purposes.  I suspect you want to receive welcome emails for an email address that was already entered into the account, but there isn't a way to do that.

 

Best Regards,

Shannon W.

API Support Specialist

Highlighted
Occasional Contributor

Re: Updating contact info

#1 I'm talking about contact list in CC(Contacts which is top right corner on CC interface), so here I don't see my updated contact.
#2. I have used 'ACTION_BY_CONTACT' and I do get response saying updated successfully (201) code but it's not triggering any emails.
#3. I don't think you understood my question.
Ok, so one person registered and that contact is there in 'contact list' but again with in some minutes he/she wants to use same email address again then I don't want to override but I do want to update when contact is not there in one of the contact lists and registered.

 

Highlighted
Employee

Re: Updating contact info

Hi Hemalatha,

 

1.  When you go to the Contacts tab after logging into your account, sometimes it takes a couple of minutes for contacts to show up in the lists they have been added to through the API.  I think that might be what you're seeing.

 

2.  If a contact's list subscriptions ARE changing when they are updated through the API, they should get a confirmation email.  If not, your server might be blocking the mail, or the contact may have already been in the list they were added to.

 

3.  You would need to write code to check if the contact's status is ACTIVE in your account, which would indicate that they are in a list already.  Then you could write an if-else statement that adds the contact to lists if they are not active, and echoes a statement that they are already active in the account if they aren't active.  You could do this right after the code that searches for the email address.

 

Best Regards,

Shannon W.

API Support Specialist

Developer Portal

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

Visit Page

Constant Contact 2020 End of Summer Community Sweepstakes!

The Constant Contact User Community is hosting a sweepstakes. The more you participate, the more chances you have to win! Read on to learn more...

Read More
Featured