> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt ## Resource: eCommerce Integration ## Article: eCommerce Integration ## Article Link: https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration.md ## Article Content: # 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](https://dev.wix.com/docs/rest/business-solutions/e-commerce/introduction.md) methods such as: + [Add To Cart](https://dev.wix.com/docs/rest/business-solutions/e-commerce/purchase-flow/cart/cart/add-to-cart.md). + [Create Checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/purchase-flow/checkout/checkout/create-checkout.md) and [Add To Checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/purchase-flow/checkout/checkout/add-to-checkout.md). + [Create Order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/orders/create-order.md). 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](https://support.wix.com/en/article/wix-stores-adding-and-customizing-product-options#setting-different-prices-for-variants) 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`: ```json { "catalogReference": { "catalogItemId": "5376f9ec-b92e-efa9-e4a1-f4f480aa0d3a", "appId": "215238eb-22a5-4c36-9e7b-e7c08025e04e", "options": { "variantId": "00000000-0000-0020-0005-ad9cdc10d3b8", "customTextFields": { "What would you like written on the custom label?": "Hope you enjoy the coffee! :)" } } } } ``` ## 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: ```json { "catalogReference": { "catalogItemId": "4d93fb7e-e612-612f-5c27-81b35b503ad7", "appId": "215238eb-22a5-4c36-9e7b-e7c08025e04e", "options": { "options": { "Size": "Medium", "Color": "Red" } } } } ```