Confirm Unsubscribe using API?


I've not looked up the specifics of the API (so my code below is Pseudo-Code to explain the flow), but is it possible to generate a dynamic link in my email that runs a page on my own site that can then communicate with the API to unsubscribe a user eg something like..

TEMPLATE: To unsubscribe please visit<campaignid>/<userid>

=> EMAIL: please visit...

=> PHP: $campaignid=39583; $userid=3905

Enter Your Email Address: [_______________] => $email

$CM_API_email = $CM_API.getEmailAddress($campaignid,$userid);
if($CM_API_email == $_POST["email"])



jmp909, 7 years ago

or could i put my own [recipientid] field in my database and use that to look them up in the subscriber list with the API?

Mathew Mathew, 7 years ago

Hey J,

Is there a reason you can't just use the existing API methods to get back a list of people who have unsubscribed from your email?

You could also just pass through the email address to your page on the unsubscribe confirmation URL as described here:

Get in touch with us on Twitter:
We're also on Facebook:

Join 200,000 companies around the world that use Campaign Monitor to run email marketing campaigns that deliver results for their business.

Get started for free