POST | /profile/sign-up |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class ProfileSignUpCreate implements IPost
{
public String firstName = null;
public String lastName = null;
public String emailAddress = null;
public String customerType = null;
public String cultureName = null;
public NAVPhoneUpdate phone = null;
public NAVCASLTermsUpdate caslStatementAgreement = null;
public String getFirstName() { return firstName; }
public ProfileSignUpCreate setFirstName(String value) { this.firstName = value; return this; }
public String getLastName() { return lastName; }
public ProfileSignUpCreate setLastName(String value) { this.lastName = value; return this; }
public String getEmailAddress() { return emailAddress; }
public ProfileSignUpCreate setEmailAddress(String value) { this.emailAddress = value; return this; }
public String getCustomerType() { return customerType; }
public ProfileSignUpCreate setCustomerType(String value) { this.customerType = value; return this; }
public String getCultureName() { return cultureName; }
public ProfileSignUpCreate setCultureName(String value) { this.cultureName = value; return this; }
public NAVPhoneUpdate getPhone() { return phone; }
public ProfileSignUpCreate setPhone(NAVPhoneUpdate value) { this.phone = value; return this; }
public NAVCASLTermsUpdate getCaslStatementAgreement() { return caslStatementAgreement; }
public ProfileSignUpCreate setCaslStatementAgreement(NAVCASLTermsUpdate value) { this.caslStatementAgreement = value; return this; }
}
public static class NAVPhoneUpdate
{
public String number = null;
public String extension = null;
public String codeIdPhoneType = null;
public String countryCode = null;
public String getNumber() { return number; }
public NAVPhoneUpdate setNumber(String value) { this.number = value; return this; }
public String getExtension() { return extension; }
public NAVPhoneUpdate setExtension(String value) { this.extension = value; return this; }
public String getCodeIdPhoneType() { return codeIdPhoneType; }
public NAVPhoneUpdate setCodeIdPhoneType(String value) { this.codeIdPhoneType = value; return this; }
public String getCountryCode() { return countryCode; }
public NAVPhoneUpdate setCountryCode(String value) { this.countryCode = value; return this; }
}
public static class NAVCASLTermsUpdate
{
public String agree = null;
public Date date = null;
public String getAgree() { return agree; }
public NAVCASLTermsUpdate setAgree(String value) { this.agree = value; return this; }
public Date getDate() { return date; }
public NAVCASLTermsUpdate setDate(Date value) { this.date = value; return this; }
}
public static class ProfileSignUpCreateResponse
{
public ResponseStatus responseStatus = null;
public BigDecimal beeNumber = null;
public String accessToken = null;
public Date timestamp = null;
public ResponseStatus getResponseStatus() { return responseStatus; }
public ProfileSignUpCreateResponse setResponseStatus(ResponseStatus value) { this.responseStatus = value; return this; }
public BigDecimal getBeeNumber() { return beeNumber; }
public ProfileSignUpCreateResponse setBeeNumber(BigDecimal value) { this.beeNumber = value; return this; }
public String getAccessToken() { return accessToken; }
public ProfileSignUpCreateResponse setAccessToken(String value) { this.accessToken = value; return this; }
public Date getTimestamp() { return timestamp; }
public ProfileSignUpCreateResponse setTimestamp(Date value) { this.timestamp = value; return this; }
}
}
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 /profile/sign-up HTTP/1.1
Host: extensions.avon.ca
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"firstName":"String","lastName":"String","emailAddress":"String","customerType":"String","cultureName":"String","phone":{"number":"String","extension":"String","codeIdPhoneType":"String","countryCode":"String"},"caslStatementAgreement":{"agree":"String","date":"0001-01-01T00:00:00.0000000"}}
HTTP/1.1 200 OK Content-Type: text/csv Content-Length: length {"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}},"beeNumber":0,"accessToken":"String","timestamp":"0001-01-01T00:00:00.0000000"}