4

I was wondering if someones knows if just by using the API v3 it is possible to resend the confirmation email to users if they choose to resubscribe. So far I can't find a way other then using mailchimps own forms.

Cheers, Max

doom4
  • 633
  • 5
  • 19

2 Answers2

1

I don't believe it is possible from the Mailchimp end, as it does technically break a lot of their rules.

Mailchimp Resubscribe

scoopzilla
  • 887
  • 5
  • 15
  • 1
    Thanks for your reply. I found an ugly workaround until I have the time to implement their webforms. I basically use their subscription link but programmatically and post the email and name if the user is unsubscribed or pending. This way they get a new activation email. – doom4 Feb 21 '17 at 20:25
  • @doom4 Oooo share your work! I would love to know how. – scoopzilla Feb 21 '17 at 20:56
  • Go to your list and then signup forms. Next choose Embedded forms and look for the form action. This ULR contains your user ID and the list ID. You can POST to this form action with the input fields from the form. In my case: EMAIL, FNAME and LNAME. Not sure if this is a violation of their rules. I already head my signup form and just didn't have the time yet to use their embed code. – doom4 Feb 21 '17 at 22:27
  • OH gotcha! You are using their form action. Nice – scoopzilla Feb 21 '17 at 22:36
  • 1
    Nice typos from my part but happy you understood regardless :) – doom4 Feb 22 '17 at 04:47
0

If the status is currently pending, you can resend the confirmation email by setting the member's status to "unsubscribed", and then setting it to "pending" again.

Given that $audienceId contains the Id of your audience, and $email the email of the member you want to resend the confirmation:

$response = $client->lists->setListMember($audienceId, $email, [
    "email_address" => $email,
    "status" => "unsubscribed"
]);
                
            
$memberHash = $response->id;
$response = $client->lists->updateListMember($audienceId, $memberHash, [
    "status" => "pending"
]);