I'm trying to update my CC signup form to allow for contacts to NOT be added until they have received a confirmation email via the "Confirmed Opt-In" toggle that is now set to ON in my account.
I have the following code in place:
$strList = 'http://api.constantcontact.com/ws/customers/xxx/lists/1111';$contactObj = new Contact();$myContacts = $ConstantContact->getContacts();
$contactObj->lists = array($strList);$contactObj->emailAddress = $strEmail;$contactObj->optInSource = 'ACTION_BY_CONTACT';$Contact = $ConstantContact->addContact($contactObj);
This does not send the confirmation email when the contact is added, and the contact appears to be automatically added to the list in question, before recieving confirmation opt in from them.
I have also tried the value of "ACTION_BY_VISITOR" in the "optInSource" field, with the same results.
View API documentation, code samples, get your API key.