addToCurrentCart( )


Adds catalog line items to the current site visitor's cart.

Notes:

  • When adding catalog line items, the lineItems.catalogReference.appId and lineItems.catalogReference.catalogItemId fields are required.
  • This method requires visitor or member authentication.
Permissions
Manage eCommerce - all permissions
Manage Stores - all permissions
Manage Restaurants - all permissions
Learn more about app permissions.
Method Declaration
Copy
Method Parameters
optionsAddToCurrentCartOptions

Items to be added to the current cart.

Returns
Return Type:Promise<AddToCartResponse>
Errors

This method doesn't return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?