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.

How to synchronize Contacts and Contact Lists

Highlighted
Occasional Contributor

How to synchronize Contacts and Contact Lists

Hi,

 

I need to synchronize both contacts and the lists that they're on with an external system.  Currently, I am using the API for searching contacts by Last Date Updated (Searching for Contacts by Last Updated Date (Synchronizing Contacts)) to determine what contacts changes since the last time I queried the system; then I can obtain the modified contacts' information and the lists they're on with the https://api.constantcontact.com/ws/customers/{username}/contacts/{contact-id} api call.  This is fine when the contacts themselves are updated, but I found out that if the contact list subscription changes, such as through contact list maintenance operations like Remove, Do Not Mail, etc., then my method doesn't work because the contacts themselves are not getting updated, so my searches for contacts by Last Date Updated do not yield any results.  Can you recommend alternative methods of keeping both contacts and their list subscriptions synchronized at all times, regardless of how each is managed?

 

Thanks,

Daniel

1 REPLY 1
Highlighted
Employee

Re: How to synchronize Contacts and Contact Lists

Hi Daniel,

 

Unfortunately we don't record the changes that happen on a list membership basis.  We only store the current list members.  You could make a call to each list to see the list members (contacts) within each list.  You would do a GET to a URL like:

 

https://api.constantcontact.com/ws/customers/joesflowers/lists/32/members

 

If there are more than 50 members in the list, you will receive a next link with the subsequent page of members.  You could also use our bulk activities API to retrieve a file with all of the list members and update your database accordingly.  Sorry there isn't a more streamlined way to do this--I am going to pass along the feedback that it would be good for us to record  changes in list subscriptions to make this less data-intensive.

 

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