POST | /v2/{ApiKey}/club/{StoreId}/prospect | (obsolete) Create a Prospect |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class CreateProspectRequestV2 extends CreateProspectRequestV2Dto implements IRestrictedApiRequest
{
/**
* Api Key - grants access to resources
*/
@ApiMember(DataType="string", Description="Api Key - grants access to resources", IsRequired=true, Name="ApiKey", ParameterType="query")
public String ApiKey = null;
/**
* ClubReady Club ID (StoreID internally)
*/
@ApiMember(DataType="integer", Description="ClubReady Club ID (StoreID internally)", IsRequired=true, Name="StoreId", ParameterType="query")
public Integer StoreId = null;
/**
* First Name
*/
@ApiMember(DataType="string", Description="First Name", IsRequired=true, Name="FirstName", ParameterType="query")
public String FirstName = null;
/**
* Last Name
*/
@ApiMember(DataType="string", Description="Last Name", IsRequired=true, Name="LastName", ParameterType="query")
public String LastName = null;
/**
* Email Address
*/
@ApiMember(DataType="string", Description="Email Address", IsRequired=true, Name="Email", ParameterType="query")
public String Email = null;
/**
* Gender
*/
@ApiMember(DataType="string", Description="Gender", Name="Gender", ParameterType="query")
public String Gender = null;
/**
* Address
*/
@ApiMember(DataType="string", Description="Address", Name="Address", ParameterType="query")
public String Address = null;
/**
* City
*/
@ApiMember(DataType="string", Description="City", Name="City", ParameterType="query")
public String City = null;
@ApiMember(DataType="string", Name="State", ParameterType="query")
public String State = null;
@ApiMember(DataType="string", Name="Zip", ParameterType="query")
public String Zip = null;
public String Phone = null;
public String WorkPhone = null;
public Date DateOfBirth = null;
public String CellPhone = null;
/**
* Specify a Package to apply to the new prospect
*/
@ApiMember(DataType="integer", Description="Specify a Package to apply to the new prospect", Name="AddPackageId", ParameterType="query")
public Integer AddPackageId = null;
/**
* Specify a specific Prospect Type for the new prospect
*/
@ApiMember(DataType="integer", Description="Specify a specific Prospect Type for the new prospect", Name="ProspectTypeId", ParameterType="query")
public Integer ProspectTypeId = null;
/**
* Specify a specific Referral Type for the new prospect
*/
@ApiMember(DataType="integer", Description="Specify a specific Referral Type for the new prospect", Name="ReferralTypeId", ParameterType="query")
public Integer ReferralTypeId = null;
/**
* Send a Welcome email to the new prospect
*/
@ApiMember(DataType="boolean", Description="Send a Welcome email to the new prospect", IsRequired=true, Name="SendEmail", ParameterType="query")
public Boolean SendEmail = null;
/**
* Only used if SendEmail = True
*/
@ApiMember(DataType="integer", Description="Only used if SendEmail = True", Name="EmailTemplateId", ParameterType="query")
public Integer EmailTemplateId = null;
/**
*
*/
@ApiMember(DataType="string", Description="", Name="Coupon", ParameterType="query")
public String Coupon = null;
/**
* Add an internal note for the new prospect
*/
@ApiMember(DataType="string", Description="Add an internal note for the new prospect", Name="Note", ParameterType="query")
public String Note = null;
public Integer RestrictedId = null;
public RestrictedResourceType RestrictedResourceType = null;
public String getApiKey() { return ApiKey; }
public CreateProspectRequestV2 setApiKey(String value) { this.ApiKey = value; return this; }
public Integer getStoreId() { return StoreId; }
public CreateProspectRequestV2 setStoreId(Integer value) { this.StoreId = value; return this; }
public String getFirstName() { return FirstName; }
public CreateProspectRequestV2 setFirstName(String value) { this.FirstName = value; return this; }
public String getLastName() { return LastName; }
public CreateProspectRequestV2 setLastName(String value) { this.LastName = value; return this; }
public String getEmail() { return Email; }
public CreateProspectRequestV2 setEmail(String value) { this.Email = value; return this; }
public String getGender() { return Gender; }
public CreateProspectRequestV2 setGender(String value) { this.Gender = value; return this; }
public String getAddress() { return Address; }
public CreateProspectRequestV2 setAddress(String value) { this.Address = value; return this; }
public String getCity() { return City; }
public CreateProspectRequestV2 setCity(String value) { this.City = value; return this; }
public String getState() { return State; }
public CreateProspectRequestV2 setState(String value) { this.State = value; return this; }
public String getZip() { return Zip; }
public CreateProspectRequestV2 setZip(String value) { this.Zip = value; return this; }
public String getPhone() { return Phone; }
public CreateProspectRequestV2 setPhone(String value) { this.Phone = value; return this; }
public String getWorkPhone() { return WorkPhone; }
public CreateProspectRequestV2 setWorkPhone(String value) { this.WorkPhone = value; return this; }
public Date getDateOfBirth() { return DateOfBirth; }
public CreateProspectRequestV2 setDateOfBirth(Date value) { this.DateOfBirth = value; return this; }
public String getCellPhone() { return CellPhone; }
public CreateProspectRequestV2 setCellPhone(String value) { this.CellPhone = value; return this; }
public Integer getAddPackageId() { return AddPackageId; }
public CreateProspectRequestV2 setAddPackageId(Integer value) { this.AddPackageId = value; return this; }
public Integer getProspectTypeId() { return ProspectTypeId; }
public CreateProspectRequestV2 setProspectTypeId(Integer value) { this.ProspectTypeId = value; return this; }
public Integer getReferralTypeId() { return ReferralTypeId; }
public CreateProspectRequestV2 setReferralTypeId(Integer value) { this.ReferralTypeId = value; return this; }
public Boolean isSendEmail() { return SendEmail; }
public CreateProspectRequestV2 setSendEmail(Boolean value) { this.SendEmail = value; return this; }
public Integer getEmailTemplateId() { return EmailTemplateId; }
public CreateProspectRequestV2 setEmailTemplateId(Integer value) { this.EmailTemplateId = value; return this; }
public String getCoupon() { return Coupon; }
public CreateProspectRequestV2 setCoupon(String value) { this.Coupon = value; return this; }
public String getNote() { return Note; }
public CreateProspectRequestV2 setNote(String value) { this.Note = value; return this; }
public Integer getRestrictedId() { return RestrictedId; }
public CreateProspectRequestV2 setRestrictedId(Integer value) { this.RestrictedId = value; return this; }
public RestrictedResourceType getRestrictedResourceType() { return RestrictedResourceType; }
public CreateProspectRequestV2 setRestrictedResourceType(RestrictedResourceType value) { this.RestrictedResourceType = value; return this; }
}
public static class CreateProspectRequestV2Dto extends ApiDtoBase
{
public String FirstName = null;
public String LastName = null;
public String Address = null;
public String City = null;
public String State = null;
public String Zip = null;
public String Email = null;
public String Gender = null;
public Integer AddPackageId = null;
public Integer ProspectTypeId = null;
public Integer ReferralTypeId = null;
public Boolean SendEmail = null;
public String Phone = null;
public String WorkPhone = null;
public Date DateOfBirth = null;
public String CellPhone = null;
public String Coupon = null;
public String Note = null;
public Integer EmailTemplateId = null;
public String getFirstName() { return FirstName; }
public CreateProspectRequestV2Dto setFirstName(String value) { this.FirstName = value; return this; }
public String getLastName() { return LastName; }
public CreateProspectRequestV2Dto setLastName(String value) { this.LastName = value; return this; }
public String getAddress() { return Address; }
public CreateProspectRequestV2Dto setAddress(String value) { this.Address = value; return this; }
public String getCity() { return City; }
public CreateProspectRequestV2Dto setCity(String value) { this.City = value; return this; }
public String getState() { return State; }
public CreateProspectRequestV2Dto setState(String value) { this.State = value; return this; }
public String getZip() { return Zip; }
public CreateProspectRequestV2Dto setZip(String value) { this.Zip = value; return this; }
public String getEmail() { return Email; }
public CreateProspectRequestV2Dto setEmail(String value) { this.Email = value; return this; }
public String getGender() { return Gender; }
public CreateProspectRequestV2Dto setGender(String value) { this.Gender = value; return this; }
public Integer getAddPackageId() { return AddPackageId; }
public CreateProspectRequestV2Dto setAddPackageId(Integer value) { this.AddPackageId = value; return this; }
public Integer getProspectTypeId() { return ProspectTypeId; }
public CreateProspectRequestV2Dto setProspectTypeId(Integer value) { this.ProspectTypeId = value; return this; }
public Integer getReferralTypeId() { return ReferralTypeId; }
public CreateProspectRequestV2Dto setReferralTypeId(Integer value) { this.ReferralTypeId = value; return this; }
public Boolean isSendEmail() { return SendEmail; }
public CreateProspectRequestV2Dto setSendEmail(Boolean value) { this.SendEmail = value; return this; }
public String getPhone() { return Phone; }
public CreateProspectRequestV2Dto setPhone(String value) { this.Phone = value; return this; }
public String getWorkPhone() { return WorkPhone; }
public CreateProspectRequestV2Dto setWorkPhone(String value) { this.WorkPhone = value; return this; }
public Date getDateOfBirth() { return DateOfBirth; }
public CreateProspectRequestV2Dto setDateOfBirth(Date value) { this.DateOfBirth = value; return this; }
public String getCellPhone() { return CellPhone; }
public CreateProspectRequestV2Dto setCellPhone(String value) { this.CellPhone = value; return this; }
public String getCoupon() { return Coupon; }
public CreateProspectRequestV2Dto setCoupon(String value) { this.Coupon = value; return this; }
public String getNote() { return Note; }
public CreateProspectRequestV2Dto setNote(String value) { this.Note = value; return this; }
public Integer getEmailTemplateId() { return EmailTemplateId; }
public CreateProspectRequestV2Dto setEmailTemplateId(Integer value) { this.EmailTemplateId = value; return this; }
}
public static class ApiDtoBase
{
public String ApiKey = null;
public Integer StoreId = null;
public Integer ChainId = null;
public String getApiKey() { return ApiKey; }
public ApiDtoBase setApiKey(String value) { this.ApiKey = value; return this; }
public Integer getStoreId() { return StoreId; }
public ApiDtoBase setStoreId(Integer value) { this.StoreId = value; return this; }
public Integer getChainId() { return ChainId; }
public ApiDtoBase setChainId(Integer value) { this.ChainId = value; return this; }
}
public static enum RestrictedResourceType
{
Store,
Chain,
User,
Undefined;
}
}
Java CreateProspectRequestV2 DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /v2/{ApiKey}/club/{StoreId}/prospect HTTP/1.1
Host: clubready.com
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"ApiKey":"String","StoreId":0,"FirstName":"String","LastName":"String","Email":"String","Gender":"String","Address":"String","City":"String","State":"String","Zip":"String","Phone":"String","WorkPhone":"String","DateOfBirth":"0001-01-01T00:00:00.0000000","CellPhone":"String","AddPackageId":0,"ProspectTypeId":0,"ReferralTypeId":0,"SendEmail":false,"EmailTemplateId":0,"Coupon":"String","Note":"String","RestrictedId":0,"RestrictedResourceType":"Store","ChainId":0}