menu
Menu
Mobify DevCenter
search_icon_focus

Types

@mobify/commerce-integrations/dist/types

Commerce Integrations data types

CartItem

PropertyTypeDescription
.idStringThe cart id.
.productIdStringThe product id.
.productNameStringThe product name.
.quantityPositiveIntegerThe quantity of this product in the cart.
.baseItemPriceNumberThe price for one unit of this product before discounts.
.baseLinePriceNumberThe price for all units of this product before discounts (usually baseItemPrice multiplied by quantity).
.itemPriceNumberThe price for one unit of this product after discounts.
.linePriceNumberThe price for all units of this product in the cart, after discounts (usually baseItemPrice multiplied by quantity).

Cart

PropertyTypeDescription
.idStringThe cart id.
.customerInfoCustomerInformationThe information about the cart owner.
.itemsArray.<CartItem>The cart items.
.shippingAddressOrderAddressThe destination shipping address.
.billingAddressOrderAddressThe billing address.
.shippingMethodsArray.<ShippingMethod>All the possible shipping methods for the cart.
.paymentMethodsArray.<PaymentMethod>All the possible payment methods for the cart.
.selectedShippingMethodIdStringThe selected shipping method for the cart.
.paymentsArray.<Payment>All the current payments applied to the cart (such as credit card or gift card).
.couponEntriesArray.<CouponEntry>All the current coupons applied to the cart.
.subtotalNumberThe subtotal before shipping, discounts, and tax.
.shippingNumberThe shipping cost.
.discountsNumberThe total of all discounts applied to the cart.
.taxNumberThe total tax of the cart.
.totalNumberThe total cost of all the items in the cart after discounts, shipping, and tax.

CategoryList

PropertyType
.dataArray.<Category>
.countNumber
.totalNumber

Category

PropertyTypeDescription
.idStringThe category id.
.nameStringThe category name.
.descriptionStringThe category description.
.thumbnailImageImageThe category thumbnail image.
.backgroundImageImageThe category background image.
.categoriesArray.<Category>The subcategories.

CountryCode


CouponEntry

PropertyTypeDescription
.idStringThe coupon id.
.activeBooleanThe coupon status, whether it’s active or not.
.codeStringThe coupon code.
.nameStringThe coupon name.
.descriptionStringThe coupon description.

CustomerInformation

PropertyTypeDescription
.idStringThe customer id.
.emailEmailThe customer’s email.

CustomerRegistration

PropertyTypeDescription
.firstNameStringThe customer’s first name.
.lastNameStringThe customer’s last name.
.emailStringThe customer’s email address.
.passwordStringThe customer’s password.

HybrisCustomerRegistration

PropertyTypeDescription
.firstNameStringThe customer’s first name.
.lastNameStringThe customer’s last name.
.emailStringThe customer’s email address.
.passwordStringThe customer’s password.
.titleCodeStringThe customer’s title, such as Mr. or Mrs.

Customer

PropertyTypeDescription
.idStringThe customer’s id.
.firstNameStringThe customer’s first name.
.lastNameStringThe customer’s last name.
.emailStringThe customer’s email address.

Email


FilterValue

PropertyTypeDescription
.countIntegerThe filter value hit count. (For example, 10.)
.labelStringThe filter value label text (For example, ‘Red’.)
.valueStringThe filter value (For example, ‘red’.)

Filter

PropertyTypeDescription
.propertyIdStringThe filter’s property id. (For example, color or size.)
.labelStringThe filter’s text used for labels. (For example, the filter color may have a label attribute of “Color”.)
.valuesArray.<FilterValue>The filter values.

ImageSet

PropertyTypeDescription
.imagesArray.<Image>The images.
.variationPropertiesArray.<VariationProperty>The variation properties that apply to the images.
.sizeTypeStringThe images size type (such as ‘small’, ‘medium’, ‘large’, or ‘swatch’).

Image

PropertyTypeDescription
.altStringThe image alt text.
.descriptionStringThe image description.
.srcStringThe image src.
.titleStringThe image title.

Integer


Latitude


PropertyTypeDescription
.hrefURLThe link’s url.
.textStringThe link’s text.
.titleStringThe link’s title.

Longitude


OrderAddress

PropertyTypeDescription
.idStringThe id of the order address.
.titleCodeStringThe title code of the customer. (For example, ‘Mr.’ or ‘Mrs.’.)
.firstNameStringThe customer’s first name.
.lastNameStringThe customer’s last name.
.phonePhoneNumberThe customer’s phone number.
.addressLine1StringThe customer’s street name, street number, and suite/unit.
.addressLine2StringAny additional addressing information. (For example, a company name, or “Attn:”.)
.countryCodeCountryCodeThe country code.
.stateCodeStringThe state code.
.cityStringThe city name.
.postalCodePostalCodeThe postal code.

OrderList

PropertyType
.count.Number
.data.Array.<Product>
.total.Number

Order

PropertyTypeDescription
.idStringThe order id.
.creationDateStringThe date when the order was created.
.statusStringThe status of the order (such as validated, processed, shipped, or cancelled).
.customerInfoCustomerInformationInformation about the customer.
.itemsArray.<CartItem>The order items.
.shippingAddressOrderAddressThe order’s destination shipping address.
.billingAddressOrderAddressThe order’s billing address.
.selectedShippingMethodIdStringThe selected shipping method for the order.
.paymentsArray.<Payment>All the current payments for the order.
.subtotalNumberThe subtotal before shipping, discounts, and tax.
.shippingNumberThe shipping cost.
.discountsNumberThe total discounts applied to the order.
.taxNumberThe order’s total tax.
.totalNumberThe order’s total cost after discounts, shipping, and tax.

PaymentDetails

Details of the payment method (such as credit card, Paypal, or gift card).

PropertyTypeDescription
.typeStringThe type of payment method (such as Visa or Mastercard).
.holderNameStringThe name of the account holder.
.numberStringThe card/account number or code (such as credit card number, or gift card code).
.maskedNumberStringThe card/account number or code, masked.
.usernameStringThe card/account username. (For example, Paypal username.)
.expiryMonthPositiveIntegerThe month when the card/account expires, in number form.
.expiryYearPositiveIntegerThe year when the card/account expires.
.ccvStringThe credit card’s cvv (card verification value).

PaymentMethod

PropertyTypeDescription
.idStringThe payment method id.
.nameStringThe payment method name.
.typesArray.<Object>The different types of the particular payment method. (For example, a credit card payment method can have types Visa and Mastercard.)

Payment

PropertyTypeDescription
.idStringThe payment id.
.amountNumberThe payment amount.
.methodIdStringThe payment method id.
.detailsPaymentDetailsThe customer’s payment details for the specified payment method.

PhoneNumber


PositiveInteger


PostalCode


ProductList

PropertyType
.count.Number
.data.Array.<Product>
.total.Number

ProductSearchRequest

PropertyTypeDescription
.countIntegerThe number of products to return.
.filtersObjectThe search result filters.
.queryStringThe search query.
.startIntegerThe starting position.
.sortStringThe sorting method.

ProductSearchResult

PropertyTypeDescription
.availableBooleanWhether the product is available for order.
.productIdStringThe product id.
.productNameStringThe product name.
.priceNumberThe product price.
.ratingNumberThe product rating.
.defaultImageImageThe product main image.
.variationPropertiesArray.<VariationProperty>The product variations.

ProductSearch

PropertyTypeDescription
.countIntegerThe number of products returned.
.filtersArray.<Filter>The available search filters.
.resultsArray.<ProductSearchResult>The product search results.
.queryStringThe search query.
.selectedFiltersObjectThe selected filters applied to the results as a propertyId and value map.
.selectedSortingOptionStringThe selected sorting option. NOTE: Only single sorting is supported.
.sortingOptionsArray.<SortOption>The available sorting options.
.startIntegerThe search start index.
.totalIntegerThe search hit count.

Product

PropertyTypeDescription
.idStringThe product id.
.nameStringThe product name.
.imageSetsArray.<ImageSet>The product’s image-sets.
.descriptionStringThe product’s description.
.categoryIdStringThe product’s main category id.
.brandStringThe product’s brand name.
.minimumOrderQuantityIntegerThe product’s minimum order quantity.
.stepQuantityIntegerThe product’s step quantity.
.upcStringThe product’s universal product code.
.unitStringThe product’s units, such as ‘each’, ‘ea’, or ‘pair’.
.priceNumberThe default price.
.pricesObjectThe map of price type label and value. For example: {‘Regular’: 99.99, ‘Sale’: 69.99}
.variationsArray.<Variation>The different variations of the product.
.variationPropertiesArray.<VariationProperty>All the product variations’ different properties.
.variationValuesObjectThe product’s property values.

ShippingMethod

PropertyTypeDescription
.idStringThe shipping method id.
.nameStringThe shipping method name.
.costNumberThe cost of shipping.

SortOption

PropertyTypeDescription
.idStringThe unique sort identifier.
.labelStringThe sort label.

StoreSearchRequest

PropertyTypeDescription
.countIntegerThe number of stores to return. Default is 20.
.startIntegerThe zero-based index page number. Default is 0.
.latlonObjectThe geographic coordinates informing the store search location.
.latlon.latitudeLatitude
.latlon.LongitudeLongitude

StoreSearchResult

PropertyTypeDescription
.countIntegerThe number of stores returned.
.startIntegerA zero-based index page number.
.totalIntegerThe total number of search hits.
.storesArray.<Store>The list of stores returned.

Store

PropertyTypeDescription
.addressLine1StringThe store address.
.addressLine2StringA secondary store address.
.cityStringThe city where the store is located.
.countryStringThe country where the store is located.
.descriptionStringThe store description.
.featuresStringThe various features of a store.
.emailStringThe store email.
.idStringThe store unique identifier.
.nameStringThe store name.
.phoneStringThe store phone number.
.postalCodeStringThe store postal code.
.hoursStringThe store hours.
.imagesStringThe store logo.

URL


VariationPropertyValue

Represents values for properties (e.g. size property would have the individual sizes).

PropertyType
.nameString
.valueString
.mainImageImage
.swatchImageImage

VariationProperty

Represents things like “color”, “size”, “width”, etc.

PropertyTypeDescription
.idStringThe variation property id.
.labelStringThe variation property label.
.valuesArray.<VariationPropertyValue>The variation property values.

Variation

PropertyTypeDescription
.idStringThe variation id (NOTE: In some cases this value may have to be generated).
.priceNumberThe product price.
.orderableBooleanWhether this variation of the product can be ordered.
.valuesObjectThe variation values.