Prevent readding unsubscribed users

104 views Asked by At

According to this post, Mailchimp prevents resubscription automatically.

But this is not true, and if you run a gb.lists.subscribe(...) on a Gibbon instance, it will resubscribe the user even if it was unsubscribed.

So my question: is this a Gibbon bug? A Mailchimp bug? Is this blog post wrong? Or I am wrong?

1

There are 1 answers

1
TooMuchPete On BEST ANSWER

The KB article you reference is talking about functionality of the web app, not of the API. Within the API, you are perfectly capable of re-subscribing unsubscribed users and that's what Gibbon is telling MailChimp to do.

The easiest way to accomplish this is to check to see if a user is subscribed before you attempt to add them. You might be able to set the update_existing parameter to 'false' to have it return an error if the user already exists on the list.