dotmailer SDK
Tools to access and manage an account in the dotMailer system
|
Address Book Factory. Provides methods to manage address books of contacts More...
Public Member Functions | |
ImportContactResult | ImportContactsIntoAddressBook (ImportContactOptions importOptions, int addressBookId, IEnumerable< IDmContact > contacts) |
Adds contacts to the address book specified by the Id | |
void | UpdateContactsResult (ImportContactResult result) |
Updates an existing ImportContactResult object. Will poll each import session from the web service, in order to update the overall status | |
DmAddressBook | CreateAddressBook (IDmAddressBook addressBook) |
Creates a new address book, if the address book already exists, the address book will be read and returned | |
DmAddressBook | CreateAddressBook (string addressBookName) |
Creates a new address book, if the address book already exists, the address book will be read and returned | |
DmAddressBookCollection | ListAddressBooks () |
Returns an DmAddressBookCollection of the address books in the dotMailer account | |
DmContactCollection | ListContactsInAddressBook (string addressbookName, ListContactOptions listOptions) |
Returns an DmContactCollection of contacts that exist in the specified address book | |
DmContactCollection | ListContactsInAddressBook (int addressBookId, ListContactOptions listOptions) |
Returns an DmContactCollection of contacts that exist in the specified address book | |
DmCampaignCollection | ListCampaignsForAddressBook (int addressBookId) |
Returns a DmCampaignCollection of campaigns that have sent emails using the specified address book | |
DmContactCollection | ListContactsInAddressBookModifiedSince (int addressBookId, DateTime sinceDate) |
Returns a DmContactCollection of the contacts that have been modified since the specified data in the specified address book. | |
DmContactCollection | ListAllContactsWithContactData () |
Lists all the contacts, with full data, in the dotMailer account, by accessing the special 'All Contacts' address book | |
DmContactCollection | ListAllContacts () |
Lists all the contacts in the dotMailer account, by accessing the special 'All Contacts' address book | |
DmContactCollection | ListUnsubscribedContactsInAddressBookSinceDate (int addressBookId, DateTime sinceDate) |
Returns a DmContactCollection of contacts that have unsubscribed from the specified address book | |
bool | RemoveAllAddressBookContacts (int addressBookId, bool preventResubscribe, bool totalUnsubscribe) |
Removes all contacts from the specified address book | |
bool | RemoveAddressBookContact (int addressBookId, string contactEmail, bool preventResubscribe, bool totalUnsubscribe) |
Removes a single the contacts from the specified address book | |
void | RemoveAddressBookContacts (int addressBookId, IDmContactCollection contactsToRemove) |
Removes a collection of contacts from the specified address book | |
void | RemoveAddressBookContacts (int addressBookId, IEnumerable< string > emailAddressToRemove) |
Removes the specified email addresses from the specified addressbook. | |
void | RemoveAddressBookContacts (string addressBookName, IEnumerable< string > emailAddressToRemove) |
Removes the specified email addresses from the specified addressbook. | |
bool | DeleteAddressBook (int addressBookId) |
Deletes the specified address book | |
DmAddressBook | GetAddressBookByName (string addressBookName) |
Returns the first address book that has the specified name Throws exception if the address book is not found | |
int | GetContactCount (int addressBookId) |
Returns the number of contact in the specified address book | |
DmAddressBook | GetAddressBookById (int addressBookId) |
Returns the address book that has the specified Id | |
DmAddressBook | CreateNewDmAddressBook () |
Creates a new DmAddressBook Object | |
DmAddressBookCollection | ListPrivateAddressBooks () |
Lists all private address books for the current account. | |
DmAddressBookCollection | ListPublicAddressBooks () |
Lists all public address books for the current account. | |
DmAddressBookCollection | GetEmptyAddressBookCollection () |
Creates and returns an empty addressbook collection that is linked to the api service | |
Detailed Description
Address Book Factory. Provides methods to manage address books of contacts
Member Function Documentation
DmAddressBook dotMailer.Sdk.AddressBookFactory.CreateAddressBook | ( | IDmAddressBook | addressBook | ) |
Creates a new address book, if the address book already exists, the address book will be read and returned
- Parameters
-
addressBook Interface to the address book data
- Returns
- DmAddressBook instance for the new address book
- Exceptions
-
DmException
DmAddressBook dotMailer.Sdk.AddressBookFactory.CreateAddressBook | ( | string | addressBookName | ) |
Creates a new address book, if the address book already exists, the address book will be read and returned
The name for the new address book
- Returns
- DmAddressBook instance for the new address book
- Exceptions
-
DmException
DmAddressBook dotMailer.Sdk.AddressBookFactory.CreateNewDmAddressBook | ( | ) |
Creates a new DmAddressBook Object
- Returns
- DmAddressBook
bool dotMailer.Sdk.AddressBookFactory.DeleteAddressBook | ( | int | addressBookId | ) |
Deletes the specified address book
- Parameters
-
addressBookId the id of the address book
- Returns
- Exceptions
-
DmException
DmAddressBook dotMailer.Sdk.AddressBookFactory.GetAddressBookById | ( | int | addressBookId | ) |
Returns the address book that has the specified Id
- Parameters
-
addressBookId the id of the required address book
- Returns
DmAddressBook dotMailer.Sdk.AddressBookFactory.GetAddressBookByName | ( | string | addressBookName | ) |
Returns the first address book that has the specified name Throws exception if the address book is not found
- Parameters
-
addressBookName the name of the desired address book
- Returns
- DmAddressBook
int dotMailer.Sdk.AddressBookFactory.GetContactCount | ( | int | addressBookId | ) |
Returns the number of contact in the specified address book
- Parameters
-
addressBookId the address book id
- Returns
- Exceptions
-
DmException
DmAddressBookCollection dotMailer.Sdk.AddressBookFactory.GetEmptyAddressBookCollection | ( | ) |
Creates and returns an empty addressbook collection that is linked to the api service
- Returns
ImportContactResult dotMailer.Sdk.AddressBookFactory.ImportContactsIntoAddressBook | ( | ImportContactOptions | importOptions, |
int | addressBookId, | ||
IEnumerable< IDmContact > | contacts | ||
) |
Adds contacts to the address book specified by the Id
- Parameters
-
importOptions Import Options instance addressBookId Id of the address book contacts IEnumerable List of the contact data
- Returns
- InportContactResult
- Exceptions
-
DmException
DmAddressBookCollection dotMailer.Sdk.AddressBookFactory.ListAddressBooks | ( | ) |
Returns an DmAddressBookCollection of the address books in the dotMailer account
- Returns
- DmAddressBookCollection
- Exceptions
-
DmException
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListAllContacts | ( | ) |
Lists all the contacts in the dotMailer account, by accessing the special 'All Contacts' address book
- Returns
- DmContactCollection
- Exceptions
-
DmException
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListAllContactsWithContactData | ( | ) |
Lists all the contacts, with full data, in the dotMailer account, by accessing the special 'All Contacts' address book
- Returns
- DmContactCollection
- Exceptions
-
DmException
DmCampaignCollection dotMailer.Sdk.AddressBookFactory.ListCampaignsForAddressBook | ( | int | addressBookId | ) |
Returns a DmCampaignCollection of campaigns that have sent emails using the specified address book
- Parameters
-
addressBookId the address book id
- Returns
- DmCampaignCollection
- Exceptions
-
DmException
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListContactsInAddressBook | ( | string | addressbookName, |
ListContactOptions | listOptions | ||
) |
Returns an DmContactCollection of contacts that exist in the specified address book
- Parameters
-
addressbookName The name of the address book listOptions Email only or full data
- Returns
- DmContactCollection
- Exceptions
-
DmException
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListContactsInAddressBook | ( | int | addressBookId, |
ListContactOptions | listOptions | ||
) |
Returns an DmContactCollection of contacts that exist in the specified address book
- Parameters
-
addressBookId Id of the address book listOptions Email only or full data
- Returns
- DmContactCollection
- Exceptions
-
DmException
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListContactsInAddressBookModifiedSince | ( | int | addressBookId, |
DateTime | sinceDate | ||
) |
Returns a DmContactCollection of the contacts that have been modified since the specified data in the specified address book.
- Parameters
-
addressBookId ID of the address book sinceDate Contacts modified since this date
- Returns
- DmContactCollection
- Exceptions
-
DmException
DmAddressBookCollection dotMailer.Sdk.AddressBookFactory.ListPrivateAddressBooks | ( | ) |
Lists all private address books for the current account.
Only the account holder can add or remove contacts from private address books
- Returns
DmAddressBookCollection dotMailer.Sdk.AddressBookFactory.ListPublicAddressBooks | ( | ) |
Lists all public address books for the current account.
Contacts can join/unsubscribe from public address books via the unsubscribe page
- Returns
DmContactCollection dotMailer.Sdk.AddressBookFactory.ListUnsubscribedContactsInAddressBookSinceDate | ( | int | addressBookId, |
DateTime | sinceDate | ||
) |
Returns a DmContactCollection of contacts that have unsubscribed from the specified address book
- Parameters
-
addressBookId Id of the address book sinceDate Starting date
- Returns
- DmContactCollection
- Exceptions
-
DmException
bool dotMailer.Sdk.AddressBookFactory.RemoveAddressBookContact | ( | int | addressBookId, |
string | contactEmail, | ||
bool | preventResubscribe, | ||
bool | totalUnsubscribe | ||
) |
Removes a single the contacts from the specified address book
- Parameters
-
addressBookId Id of the address book contactEmail The email of the contact preventResubscribe If this is set to true the contacts will be added to the address book specific suppression list totalUnsubscribe If this is set to true the contacts will be added to the account suppression list.
- Returns
- Exceptions
-
DmException
void dotMailer.Sdk.AddressBookFactory.RemoveAddressBookContacts | ( | int | addressBookId, |
IDmContactCollection | contactsToRemove | ||
) |
Removes a collection of contacts from the specified address book
- Parameters
-
addressBookId Id of the address book contactsToRemove The collection to remove
- Returns
void dotMailer.Sdk.AddressBookFactory.RemoveAddressBookContacts | ( | int | addressBookId, |
IEnumerable< string > | emailAddressToRemove | ||
) |
Removes the specified email addresses from the specified addressbook.
- Parameters
-
addressBookId the id of the address book emailAddressToRemove list of email addresses to remove
void dotMailer.Sdk.AddressBookFactory.RemoveAddressBookContacts | ( | string | addressBookName, |
IEnumerable< string > | emailAddressToRemove | ||
) |
Removes the specified email addresses from the specified addressbook.
- Parameters
-
addressBookName the name of the address book emailAddressToRemove list of email addresses to remove
bool dotMailer.Sdk.AddressBookFactory.RemoveAllAddressBookContacts | ( | int | addressBookId, |
bool | preventResubscribe, | ||
bool | totalUnsubscribe | ||
) |
Removes all contacts from the specified address book
- Parameters
-
addressBookId The id of the address book preventResubscribe If this is set to true the contacts will be added to the address book specific suppression list totalUnsubscribe If this is set to true the contacts will be added to the account suppression list.
- Returns
- true if all of the contacts were removed
- Exceptions
-
DmException
void dotMailer.Sdk.AddressBookFactory.UpdateContactsResult | ( | ImportContactResult | result | ) |
Updates an existing ImportContactResult object. Will poll each import session from the web service, in order to update the overall status
- Parameters
-
result ImportContactResult instance that was obtained from ImportContactsIntoAddressBook
- Exceptions
-
DmException
Generated by 1.8.3