Choose how often you'd like to hear from us — or unsubscribe completely below.
How often would you like emails?
You'll be removed from all Dia-Co marketing emails. You may still receive transactional emails related to your account.
You're all set. We'll be in touch accordingly.
1. In your Mailchimp email footer, replace the unsubscribe link with:
https://yoursite.com/email-preferences?email=*|EMAIL|*
2. First, create a merge field called EMAIL_FREQUENCY in Mailchimp:
Audience → Settings → Audience fields and *|MERGE|* tags → Add A Field → Text → label it EMAIL_FREQUENCY
3. This page calls a small backend proxy (e.g. a Netlify Function or simple server) because Mailchimp's API requires server-side calls. See the fetch call in the script below — set up a proxy at /api/update-preference that forwards to Mailchimp.
4. Mailchimp API endpoint your proxy should call:
PATCH https://us13.api.mailchimp.com/3.0/lists/LIST_ID/members/{subscriber_hash}
Body: { "merge_fields": { "EMAIL_FREQUENCY": "weekly" } }
-- OR for unsubscribe --
Body: { "status": "unsubscribed" }
Auth: Basic base64("anystring:YOUR_API_KEY")
5. In Mailchimp, use Segments filtered by EMAIL_FREQUENCY = weekly or monthly to control send frequency.