Gets a contact by ID with their consent information
This method retrieves a contact with their consent information in your account by ID. Unsubscribed or suppressed contacts will not be retrieved.
SOAP action: http://apiconnector.com/v2/ApiService/GetContactByIdWithConsent
Input and output parameters
The input and output parameters for this method are:
Input parameters
- Contact ID - required; integer
Output parameters
- GetContactByIdWithConsentResult
- 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')
- ConsentFields - optional; array of ConsentData
- ConsentData
- Key - string ('Text', 'DateTimeConsented', 'URL', 'IPAddress', 'UserAgent', 'DateTimeCreated')
- Value - anyType
Example
using (var client = new ApiServiceClient())
{
client.ClientCredentials.UserName.UserName = "username";
client.ClientCredentials.UserName.Password = "password";
var contactId = 1;
var contact = client.GetContactByIdWithConsent(contactId);
}