Add

Overview 

Adds a new subscriber to your list and returns a status

Syntax 

Add(1)

Function Properties 

OrdinalTypeDescription
1objectRequiredJSON object representing the properties of the new subscriber

Example 

This sample code adds a subscriber to the specified list:

1var newSubscriber = {
2    "EmailAddress": "test.008@example.com",
3    "SubscriberKey": "20100730001",
4    "EmailTypePreference": "Text",
5    "Attributes":{"First Name": "test.008", "Last Name": "test.008" },
6    "Lists": {"Status": "Active", "ID": 12345, "Action": "Create"}
7};
8
9var status = Subscriber.Add(newSubscriber);