eCommerce Integration

Adding products from your Wix Stores catalog to an eCommerce cart, checkout, or order, must follow the structure of the catalogReference object.

Pass the catalogReference object as part of the lineItems array to eCommerce functions such as:

The catalogReference object includes the following fields:

  • catalogItemId - When passing Wix Stores products, this is the productId.
  • appId - The Wix Stores app ID. When using products from the Stores catalog, this must always be "215238eb-22a5-4c36-9e7b-e7c08025e04e".
  • options - This optional field can hold different key:value pairs, depending on variant management and whether the product/variant has custom text fields.

The examples below detail about the 2 main uses of the catalogReference object when passing Wix Stores products.

Managed Variants

When a product's variants are managed (product.manageVariants: true), the catalogReference.options should hold the variant's variantId. In the following example, the variant also has customTextFields:

Copy

Non-Managed Variants

When a product's variants are not managed (product.manageVariants: false), the options object should hold the variant's options and choices:

Copy
Did this help?