ResubscribeContactToAddressBook

Resubscribes a previously unsubscribed contact to a given address book

This method resubscribes an unsubscribed contact to a specified address book and returns their resubscribe status. Any contact that returns a resubscribe status of 'ContactChallenged' will be sent an automated email asking them to confirm that they want to resubscribe.

Please note that you can include, and thus update, contact data fields when resubscribing a contact to an address book using this method.

The 'preferredLocale' parameter can be included if you want to send the resubscribe request email to the contact in a language different to the language your account was created in. The language codes stand for the following languages:

  • cs-CS = Czech
  • da-DA = Danish
  • de-DE = German
  • el-EL = Greek
  • en-EN = English
  • es-ES = Spanish
  • es = Latin American Spanish
  • fi-FI = Finnish
  • fr-FR = French
  • hu-HU = Hungarian
  • it-IT = Italian
  • nl-NL = Dutch
  • nb-NO = Norwegian
  • pl-PL = Polish
  • pt-PT = Portuguese
  • ru-RU = Russian
  • se-SE = Swedish
  • sk-SK = Slovak
  • tr-TR = Turkish
  • zh-CN = Chinese (simplified)

The 'returnUrlToUseIfChallenged' parameter can be included if you wish to redirect challenged contacts to a specific URL after they have finished confirming their resubscription via the automated resubscribe email.

Resubscribe status types can be:

  • 'ContactAdded' - The contact has been successfully resubscribed to the address book
  • 'ContactChallenged' - The contact has been sent an automated resubscribe email, asking them to confirm their resubscription
  • 'ContactCannotBeUnsuppressed' - The contact can't be resubscribed. This may be because the contact is on the Global Suppression List (GSL), or their domain has been suppressed from receiving your campaigns, or the contact was removed because of a complaint from their ISP. You may want to contact support.
  • 'NotAvailableInThisVersion' - This feature is not available in the version of the API you're using

SOAP action: http://apiconnector.com/v2/ApiService/ResubscribeContactToAddressBook

πŸ“˜

Input and output parameters

Input parameters

  • UnsubscribedContact
    • AddressBook ID - required; integer
    • Email - required; string
    • DataFields - optional; array of ContactData
      • ContactData
        • Key - string
        • Value - anyType
  • PreferredLocale - optional; string ('cs-CS', 'da-DA', 'de-DE', 'el-EL', 'en-EN', 'es-ES', 'es', 'fi-FI', 'fr-FR', 'hu-HU', 'it-IT', 'nl-NL', 'nb-NO', 'pl-PL', 'pt-PT', 'ru-RU', 'se-SE', 'sk-SK', 'tr-TR', 'zh-CN')
  • ReturnUrlToUseIfChallenged - optional; string

Output parameters

  • ResubscribeContactToAddressBookResult
    • Contact
      • SuppressedContact
        • Id - integer
        • Email - string
        • OptInType - string ('Unknown', 'Single', 'Double', 'VerifiedDouble')
        • EmailType - string ('PlainText', 'Html')
        • DataFields - optional; array of ContactData
          • ContactData
            • Key - string
            • Value - anyType
        • Status - string ('Subscribed', 'Unsubscribed', 'SoftBounced', 'HardBounced', 'IspComplained', 'MailBlocked', 'PendingOptIn', 'DirectComplaint', 'Deleted', 'SharedSuppression', 'Suppressed', 'NotAllowed', 'DomainSuppression', 'NoMxRecord')
    • Status - string ('ContactAdded', 'ContactChallenged', 'ContactCannotBeUnsuppressed')

Example

using (var client = new ApiServiceClient())
{
	client.ClientCredentials.UserName.UserName = "username";
	client.ClientCredentials.UserName.Password = "password";

	var unsubscribedContact = new ApiContact { Email = "[email protected]" };
	var addressBookId = 1;
	
	var resubscription = new ApiContactResubscription
	{
	    UnsubscribedContact = unsubscribedContact
	};
	
	var resubscribeResult = client.ResubscribeContactToAddressBook(addressBookId, resubscription);
}