SpreadWebServcie.AddSubscribersByInfo Method

 

It adds more then one subscribers into an existing subscription by his/her email as well as other Info. Such as First Name, Company, Job Title, etc.

public Dataset addSubscribersByInfo (

string loginEmail,

string password,

Subscriber[] subscriberArgs,

string subscription,

DoubleOptIn optInType

)

Parameters

Parameter

Type

Description

loginEmail

String

The login email of your Spread account.

password

String

The password of your Spread account or API Key which you can retrieve from your Spread account (My account=> Settings).

subscriberArgs

Subscriber[]

Array of info of subscribers to be added.

subscription

String

The name of target subscription to be added.

optInType

DoubleOptIn

Double Opt-in option.

Return Value

Dataset containing error messages if any.

Example

string loginName = "spread@reasonables.com";

string loginPassword = "spread";

string customerEmail = "alan@reasonables.com";

string targetSubscription = "NoClone VIP";

DoubleOptIn addOption = DoubleOptIn.Off;

Dataset errors;

 

//Create an array of subscriber

Subscriber[] customer = new Subscriber[2];

 

//Create more then one Subscriber objects

Subscriber customerA = new Subscriber();
customerA.email =
"alan@reasonables.com";
customerA.firstName =
"Alan";
customerA.lastName =
"Wo";
customerA.company =
"Reasonable Software";

 

Subscriber customerB = new Subscriber();
customerB.email =
" circle@reasonables.com";
customerB.firstName =
"Circle";
customerB.lastName =
"Ching";
customerB.jobTitle =
"CEO";

 

//Put the Subscriber objects into array

customer[0] = customerA;

customer[1] = customerB;

 

//Create a SpreadWebService object and use its method.

SpreadWebService MySpread = new SpreadWebService();

 

errors = MySpread.addSubscribersByInfo (loginName, loginPassword, customer, targetSubscription, addOption);

See Also

SpreadWebService Class | Spread Web Service Namespace

Subscriber Class

DoubleOptIn Enumeration