com.createsend
Class People
java.lang.Object
com.createsend.CreateSendBase
com.createsend.People
public class People
- extends CreateSendBase
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
People
public People(AuthenticationDetails auth,
String clientID)
- Constructor.
- Parameters:
auth - The authentication details to use when making API calls.
May be either an OAuthAuthenticationDetails or
ApiKeyAuthenticationDetails instance.clientID - The Client ID to use when making API calls.
getClientID
public String getClientID()
setClientID
public void setClientID(String clientID)
add
public String add(PersonToAdd person)
throws CreateSendException
- Adds a person to the client. If a password is not supplied, an email invitation will be sent to the
person. Otherwise the person will be added with the specified password and immediately activated
- Parameters:
person - The person to add to the client
- Returns:
- The email address of the newly added person
- Throws:
CreateSendException - Thrown when the API responds with HTTP Status >= 400- See Also:
-
Adding a person
details
public Person details(String emailAddress)
throws CreateSendException
- Gets the details for the person with the given email address
- Parameters:
emailAddress - The email address to get the person details for
- Returns:
- The details of the person
- Throws:
CreateSendException - Thrown when the API responds with HTTP Status >= 400- See Also:
-
Getting person details
delete
public void delete(String emailAddress)
throws CreateSendException
- Deletes the person with the specified email address from the client
- Parameters:
emailAddress - The email address of the person to delete
- Throws:
CreateSendException - Thrown when the API responds with HTTP Status >= 400- See Also:
-
Deleting a person
update
public void update(String originalEmailAddress,
Person newDetails)
throws CreateSendException
- Updates the details for an existing person
- Parameters:
originalEmailAddress - The current email address of the existing personnewDetails - The new details for the person.
- Throws:
CreateSendException - Thrown when the API responds with HTTP Status >= 400- See Also:
-
Updating a person
Copyright © 2013. All Rights Reserved.