title: Mailchimp - how can I tell if a user has unsubscribed themselves?
body: <p>So they've clicked the unsubscribe link in a newsletter. In their profile it says, for example: </p>
  
  <p>This person unsubscribed on Mar 24, 2017 2:40 pm</p>
  
  <p>After receiving "Newsletter Test#6"</p>
  
  <p>Great, but how can I tell programmatically, via the API, if someone has unsubscribed themselves? Is it even possible? The reason I'm asking is because you can't delete someone who has unsubscribed themselves. If you try, their data will be scrubbed but the email address will stay in your list. Furthermore, if you try to subscribe someone who has unsubscribed by clicking on an unsubscribe link, you'll get "john@example.com is in a compliance state due to unsubscribe, bounce, or compliance review and cannot be subscribed." So in this situation we should check if they've unsubscribed themselves, and if so we can set their status to pending which will send the confirmation opt-in email. Otherwise, we can subscribe them via API without setting their status to pending and sending them an email and requiring them to click the link in the email.</p>