• Resolved twotae

    (@nori2tae)


    I’ve been testing MailPoet3 for a while and developing my newsletter form mostly by using API.

    There is one thing I cannot figure out the situation like as following.

    • A user singed up and get a news letter.
    • He/She change their status to unsubscribed from the link in news letter.
    • Sometimes later he/she sign up for the same news letter again.

    I thought subscriber’s status was going to be ‘subscribed’ again at this point but it remained ‘unsubscribed’.

    If subscriber delete (or lost) the news letter, it seems like there is no way he/she can subscribe the same newsletter again unless the admin manually change his/her status in the admin panel.

    I might misunderstand and wrongly use the API in the first place.
    I use API like this by the way.
    $mailpoet_api->subscribeToLists($subscribersEmail, [$listID]);

    Any thought or answer appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter twotae

    (@nori2tae)

    I’ve tested with normal sign up form and it does work that MP sends new confirmation email to the subscriber and changed his/her status from unsubscribed to unconfirmed.

    I hope API acts same as normal form.
    So there’s no chance I can achieve the same with this API so far.

    Thread Starter twotae

    (@nori2tae)

    Ok I did some research and found a nice plugin called “Add-on Contact Form 7 MailPoet 3”. I took a looked at some code inside and this class did kind of what I want to do.

    • MailPoet\Models\Subscriber;

    Subscriber class can handle subscriber’s status with its static method createOrUpdate, i was able to change his/her status programatically.

    Thanks Tikweb ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Changing subscriber’s status via API’ is closed to new replies.