Cart
This object represents a complete shopping cart session of the customer.
Please see this note about shipping costs.
Type | Field | Description |
---|---|---|
String | cartId | The unique ID for the cart. This needs to be stored as a cookie on the customer's browser so that the cart can be retrieved. |
String | paymentMethod | Type of payment method. See the PAYMENT_METHOD_ constants in the checkoutapi.js file for valid values. |
String | creditCardType | Type of credit card. See the CREDIT_CARD_TYPE_ constants in the checkoutapi.js file for valid values. |
String[] | creditCardTypes | An array of credit card types (Visa, Mastercard, etc.) that are currently accepted. Used to generate drop down lists. |
String | creditCardNumber | Credit card number |
String | creditCardToken | Credit card token (if you are using a tokenizing gateway like Stripe.com) |
integer | creditCardExpirationMonth | Credit card expiration month 1 = January 12 = December |
integer | creditCardExpirationYear | Credit card expiration year. Must be a four digit year. |
String | creditCardVerificationNumber | Credit card verification number 4 digits for American Express and 3 digits for all other types of credit cards. |
boolean | collectCreditCardVerificationNumber | True if the CVV2 should be collected for this merchant. |
String | purchaseOrderNumber | Purchase order number |
String | billToFirstName | Bill to first name |
String | billToLastName | Bill to last name |
String | billToTitle | Bill to title |
String | billToCompany | Bill to company |
String | billToAddress1 | Bill to address line 1 |
String | billToAddress2 | Bill to address line 2 |
String | billToCity | Bill to city |
String | billToState | Bill to state |
String | billToPostalCode | Bill to postal code |
String | billToCountry | Bill to country. Must be a valid country name from the getAllowedCountries() API call. |
String | billToDayPhone | Bill to day phone |
String | billToEveningPhone | Bill to evening phone |
String | Email address | |
String | emailConfirm | Second copy of email address used to confirm the customer entered it correctly |
String | ccEmail | CC Email address |
String | giftEmail | Gift Email address |
boolean | mailingListOptIn | Whether the customers wants to receive news and special offers via email. |
String | shipToFirstName | Ship to first name |
String | shipToLastName | Ship to last name |
String | shipToTitle | Ship to title |
String | shipToCompany | Ship to company |
String | shipToAddress1 | Ship to address line 1 |
String | shipToAddress2 | Ship to address line 2 |
String | shipToCity | Ship to city |
String | shipToState | Ship to state |
String | shipToPostalCode | Ship to postal code |
String | shipToCountry | Ship to country. Must be a valid country name from the getAllowedCountries() API call. |
String | shipToPhone | Ship to phone |
String | shippingMethod | Shipping method |
boolean | needShipping | true if the cart needs shipping calculated. |
Date | shipOnDate | Ship on date (optional) |
Date | deliveryDate | Delivery date (optional) |
boolean | shipToResidential | True if the address is residential. |
String | specialInstructions | Special instructions for delivery. |
CartItem[] | items | All the items in the cart. |
number | subtotal | Subtotal |
number | subtotalDiscount | Subtotal discount (because of coupon) |
number | subtotalWithDiscount | Subtotal after discounts have been applied |
number | taxExempt | True if the customer is tax exempt |
number | taxRate | Tax rate |
number | tax | Tax |
number | taxableSubtotal | Taxable subtotal |
number | taxableSubtotalDiscount | Taxable subtotal discount (because of coupons) |
number | taxableSubtotalWithDiscount | Taxable subtotal after discounts. |
number | buysafeBondCost | Cost of the buySAFE bond (for buySAFE merchants only) |
number | shippingHandling | Shipping and handling cost |
number | shippingHandlingDiscount | Shipping and handling discount (because of coupon) |
number | shippingHandlingWithDiscount | Shipping and handling cost after discount applied. |
number | giftCharge | Gift charge |
String | giftEmail | Email address of the person receiving this purchase as a gift |
number | giftCertificateAmount | Gift certificate amount |
number | giftWrapCost | Gift wrap cost |
String | giftMessage | Gift message |
number | surcharge | Credit card surcharge amount |
number | total | Total |
boolean | buysafeBondAvailable | buySAFE bond availability |
number | buysafeBondFree | True if the buySAFE bond is free to the customer |
boolean | buysafeBondWanted | True if the customer has opted in to a buySAFE bond |
String | buysafeBondingSignal | The HTML code for the buySAFE flash control |
String | buysafeBondingSignalJavascript | The Javascript code for the buySAFE flash control |
String | buysafeCartDisplayText | The sales text to display by the buySAFE control |
String | buysafeCartDisplayUrl | The URL to link the sales text to so the customer can learn more about buySAFE. |
String | ipAddress | IP Address of the customer. Used for geo-location of shipping estimates. |
String | screenBrandingThemeCode | The screen branding theme associated with the cart. |
String | advertisingSource | Advertising source the customer selected or entered. |
coupons | Coupons that have been applied to the cart. | |
boolean | hasPayPal | True if the merchant has PayPal enabled. |
boolean | payPalCompatible | True if this cart is compatible with PayPal |
String | payPalButtonUrl | URL of the PayPal express checkout image |
String | payPalButtonAltText | Alt text to use on the PayPal express checkout image |
String | customField1 | A custom field to store up to 50 characters. |
String | customField2 | A custom field to store up to 50 characters. |
String | customField3 | A custom field to store up to 50 characters. |
String | customField4 | A custom field to store up to 50 characters. |
String | customField5 | A custom field to store up to 50 characters. |
String | customField6 | A custom field to store up to 50 characters. |
String | customField7 | A custom field to store up to 50 characters. |
boolean | insureShipAvailable | True if bond is available. |
boolean | insureShipSeparate | True if the bond would be separate from shipping. |
number | insureShipCost | Cost of the bond |
Boolean | insureShipWanted | True/false if the bond is wanted. This will be null if the customer has not made a choice yet. |
String | taxCounty | The tax county assigned to this customer. See method getTaxCounties(). |
String | affiliateId | The ID of the affiliate associated with this cart. You can set this field to manually assign an order to a specific affiliate. If no affiliate is associated with the order then this field will be null. |
boolean | loggedIn | true if a customer profile is active, false if otherwise |
CustomerProfile | customerProfile | If loggedIn , this variable will contain the CustomerProfile for the current session. |
number | arbitraryTax | Override field allowing merchants to override calculated tax. To use this field, the Tax must be configured to allow overrides. |
number | arbitraryTaxableSubtotal | Override field allowing merchants to override the taxable subtotal. To use this field, the Tax must be configured to allow overrides. |
number | arbitraryTaxRate | Override field allowing merchants to override calculated tax rate. To use this field, the Tax must be configured to allow overrides. |
number | arbitraryShippingHandlingTotal | Override field allowing merchant to override the shipping and handling calculated by the system. To use this field, the Shipping and Handling must be configured to allow overrides. |
boolean | liftGate | True if this purchase will require delivery by lift gate, false (default) otherwise. |