Contact_Add

Contact_Add( string keystring emailstruct customFields,optional struct optionalParameters)

Note: When using one of the  API wrappers, you do not need to pass the API key. The wrapper will pass the key for you, your first parameter should be the second parameter in the signature.

Description

Add a contact with custom fields
 

Parameters

  string key Your API key - used to authenticate your account
  string email Email address of the contact
  struct customFields is a container for custom field data
customFields is a struct which can contain:
- customFieldToken => value
- customFieldId => value

Ex:
customFields = {"first_name":"Test","last_name":"User"}

or

customFields = {1:"Test",2:"User"}
optional struct optionalParameters A struct of optional parameters, see below for valid keys

optionalParameters can include:

bool activateDeleted If this contact was already deleted, reactivate them - defaults to true
bool updateCustomFields If this contact already exists, replace custom field values with values provided - defaults to false. Will not update the custom fields for a contact that is deactivated (bounced, globally unsubscribed, etc.)

Return

bool Returns true on success
 

Still need help? Contact Us Contact Us