Package model
Class AdditionalPurchaseData
java.lang.Object
model.AdditionalPurchaseData
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2022-06-24T13:03:18.088665-07:00[America/Los_Angeles]")
public class AdditionalPurchaseData
extends Object
The additional information about the purchase. Used for Level 2 and Level 3 Processing.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddItemDataItem(AdditionalPurchaseDataItemDataInner itemDataItem) customerReferenceNumber(String customerReferenceNumber) customsDutyAmount(Long customsDutyAmount) destinationCountryCode(String destinationCountryCode) destinationPostalCode(String destinationPostalCode) discountAmount(Long discountAmount) booleanstatic AdditionalPurchaseDataCreate an instance of AdditionalPurchaseData given an JSON stringThe customer reference for the purchase (max 17 characters).The duty in cents on the total purchase amount for the orderThe ISO country code of the order destination.The postal code of the order destination (10 characters)The amount in cents of the discount for the order.The order's invoice number (max 15 characters)Get itemDataGet orderDateTotal aggregate tax amount in cents for the entire purchase.The postal code from where order is shipped (10 characters)The shipping cost in cents for the order.For tax exempt purchases set to True.inthashCode()invoiceReferenceNumber(String invoiceReferenceNumber) itemData(List<AdditionalPurchaseDataItemDataInner> itemData) orderDate(AdditionalPurchaseDataOrderDate orderDate) voidsetCustomerReferenceNumber(String customerReferenceNumber) voidsetCustomsDutyAmount(Long customsDutyAmount) voidsetDestinationCountryCode(String destinationCountryCode) voidsetDestinationPostalCode(String destinationPostalCode) voidsetDiscountAmount(Long discountAmount) voidsetInvoiceReferenceNumber(String invoiceReferenceNumber) voidsetItemData(List<AdditionalPurchaseDataItemDataInner> itemData) voidsetOrderDate(AdditionalPurchaseDataOrderDate orderDate) voidsetSalesTax(Long salesTax) voidsetShipFromPostalCode(String shipFromPostalCode) voidsetShippingAmount(Long shippingAmount) voidsetTaxExempt(Boolean taxExempt) shipFromPostalCode(String shipFromPostalCode) shippingAmount(Long shippingAmount) toJson()Convert an instance of AdditionalPurchaseData to an JSON stringtoString()static voidvalidateJsonObject(com.google.gson.JsonObject jsonObj) Validates the JSON Object and throws an exception if issues found
-
Field Details
-
SERIALIZED_NAME_CUSTOMER_REFERENCE_NUMBER
- See Also:
-
SERIALIZED_NAME_CUSTOMS_DUTY_AMOUNT
- See Also:
-
SERIALIZED_NAME_DESTINATION_COUNTRY_CODE
- See Also:
-
SERIALIZED_NAME_DESTINATION_POSTAL_CODE
- See Also:
-
SERIALIZED_NAME_DISCOUNT_AMOUNT
- See Also:
-
SERIALIZED_NAME_INVOICE_REFERENCE_NUMBER
- See Also:
-
SERIALIZED_NAME_ITEM_DATA
- See Also:
-
SERIALIZED_NAME_ORDER_DATE
- See Also:
-
SERIALIZED_NAME_SALES_TAX
- See Also:
-
SERIALIZED_NAME_SHIP_FROM_POSTAL_CODE
- See Also:
-
SERIALIZED_NAME_SHIPPING_AMOUNT
- See Also:
-
SERIALIZED_NAME_TAX_EXEMPT
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
AdditionalPurchaseData
public AdditionalPurchaseData()
-
-
Method Details
-
customerReferenceNumber
-
getCustomerReferenceNumber
The customer reference for the purchase (max 17 characters).- Returns:
- customerReferenceNumber
-
setCustomerReferenceNumber
-
customsDutyAmount
-
getCustomsDutyAmount
The duty in cents on the total purchase amount for the order- Returns:
- customsDutyAmount
-
setCustomsDutyAmount
-
destinationCountryCode
-
getDestinationCountryCode
The ISO country code of the order destination.- Returns:
- destinationCountryCode
-
setDestinationCountryCode
-
destinationPostalCode
-
getDestinationPostalCode
The postal code of the order destination (10 characters)- Returns:
- destinationPostalCode
-
setDestinationPostalCode
-
discountAmount
-
getDiscountAmount
The amount in cents of the discount for the order.- Returns:
- discountAmount
-
setDiscountAmount
-
invoiceReferenceNumber
-
getInvoiceReferenceNumber
The order's invoice number (max 15 characters)- Returns:
- invoiceReferenceNumber
-
setInvoiceReferenceNumber
-
itemData
-
addItemDataItem
-
getItemData
Get itemData- Returns:
- itemData
-
setItemData
-
orderDate
-
getOrderDate
Get orderDate- Returns:
- orderDate
-
setOrderDate
-
salesTax
-
getSalesTax
Total aggregate tax amount in cents for the entire purchase. Field is automatically calculated if you pass in the itemized tax amounts. For non-taxable transactions either set `sales_tax` to 0 or omit from payload and also set `tax_exempt` to **True**.- Returns:
- salesTax
-
setSalesTax
-
shipFromPostalCode
-
getShipFromPostalCode
The postal code from where order is shipped (10 characters)- Returns:
- shipFromPostalCode
-
setShipFromPostalCode
-
shippingAmount
-
getShippingAmount
The shipping cost in cents for the order.- Returns:
- shippingAmount
-
setShippingAmount
-
taxExempt
-
getTaxExempt
For tax exempt purchases set to True.- Returns:
- taxExempt
-
setTaxExempt
-
equals
-
hashCode
public int hashCode() -
toString
-
validateJsonObject
Validates the JSON Object and throws an exception if issues found- Parameters:
jsonObj- JSON Object- Throws:
IOException- if the JSON Object is invalid with respect to AdditionalPurchaseData
-
fromJson
Create an instance of AdditionalPurchaseData given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of AdditionalPurchaseData
- Throws:
IOException- if the JSON string is invalid with respect to AdditionalPurchaseData
-
toJson
Convert an instance of AdditionalPurchaseData to an JSON string- Returns:
- JSON string
-