Sync Salesforce contacts to Mailchimp newsletter weekly

Recipe ToolsMarketingCRM

What it does

When the schedule triggers every Sunday at 9 PM, this automation queries Salesforce using SOQL to find contacts for the newsletter. It adds each contact to the Mailchimp audience, skipping those already subscribed and logging any errors to a lookup table.

Who it's for

Marketing operations teams who need to keep a Mailchimp newsletter audience in sync with Salesforce contacts on a weekly basis.

How teams use this

Keep newsletter audience current weekly

Run the sync every Sunday so the Mailchimp newsletter audience always has the latest contacts from Salesforce. No manual work is needed to add or remove subscribers.

Expand sync to multiple audiences

Add more SOQL queries to sync different Salesforce contact segments to separate Mailchimp audiences. The same weekly schedule and error handling apply to each audience.

Alert the team on sync failures

When errors are logged to the lookup table, send a notification to Slack so the team knows the sync had issues and can investigate the details.

How it works

  1. Trigger on Sunday at 9 PM. Every Sunday at 9 PM, this automation runs to sync the latest contacts from Salesforce to Mailchimp for the newsletter audience.
  2. Query Salesforce for contacts. Search Salesforce using a SOQL query to find all contacts that match the criteria for the newsletter audience in this sync.
  3. Check if subscriber exists. For each contact from Salesforce, search Mailchimp to see if that subscriber is already on the newsletter list before adding them.
  4. Add new subscribers to Mailchimp. When a contact is not found in Mailchimp, add them as a subscriber to the newsletter audience. Log errors if the subscriber is already a list member.
  5. Record errors in lookup table. When an error occurs during the add, store the error message in the lookup table so the team can review what went wrong with each sync.