| POST | /payments/creditcard/token | (Deprecated) | (Deprecated) |
|---|---|---|---|
| POST | /payments/creditcard/ref |
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class CreditCardReference
{
@ApiMember(IsRequired=true)
public String GroupId = null;
@ApiMember(IsRequired=true)
public String CardNumber = null;
@ApiMember(IsRequired=true)
public String CardType = null;
@ApiMember(IsRequired=true)
public Integer ExpirationMonth = null;
@ApiMember(IsRequired=true)
public Integer ExpirationYear = null;
public String getGroupId() { return GroupId; }
public CreditCardReference setGroupId(String value) { this.GroupId = value; return this; }
public String getCardNumber() { return CardNumber; }
public CreditCardReference setCardNumber(String value) { this.CardNumber = value; return this; }
public String getCardType() { return CardType; }
public CreditCardReference setCardType(String value) { this.CardType = value; return this; }
public Integer getExpirationMonth() { return ExpirationMonth; }
public CreditCardReference setExpirationMonth(Integer value) { this.ExpirationMonth = value; return this; }
public Integer getExpirationYear() { return ExpirationYear; }
public CreditCardReference setExpirationYear(Integer value) { this.ExpirationYear = value; return this; }
}
public static class CreditCardReferenceReply implements IHaveErrorField
{
/**
* Same as CardReference, however this field is deprecated
*/
@ApiMember(Description="Same as CardReference, however this field is deprecated")
public String CardToken = null;
public String ErrorMessage = null;
public Integer ErrorCode = null;
@ApiMember(ExcludeInSchema=true)
public Boolean IsError = null;
public String CardReference = null;
public String getCardToken() { return CardToken; }
public CreditCardReferenceReply setCardToken(String value) { this.CardToken = value; return this; }
public String getErrorMessage() { return ErrorMessage; }
public CreditCardReferenceReply setErrorMessage(String value) { this.ErrorMessage = value; return this; }
public Integer getErrorCode() { return ErrorCode; }
public CreditCardReferenceReply setErrorCode(Integer value) { this.ErrorCode = value; return this; }
public Boolean getIsError() { return IsError; }
public CreditCardReferenceReply setIsError(Boolean value) { this.IsError = value; return this; }
public String getCardReference() { return CardReference; }
public CreditCardReferenceReply setCardReference(String value) { this.CardReference = 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 /payments/creditcard/token HTTP/1.1
Host: devapi.billhighway.com
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"GroupId":"String","CardNumber":"String","CardType":"String","ExpirationMonth":0,"ExpirationYear":0}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length
{"CardToken":"String","ErrorMessage":"String","ErrorCode":0,"IsError":false,"CardReference":"String"}