E-Commerce Abandoned Carts

What is an Abandoned Cart?

E-Commerce abandoned carts represent a cart in an external integration (such as Shopify or WooCommerce) where a user has placed items into their cart on the store but never completed the purchase. A common use case for abandoned carts is to use them to trigger automations to send emails to remind customers to complete their purchase. See our article on Abandoned Cart Automations for more details on this.

Before you can creating an abandoned cart, you must have created a connection resource for the e-commerce service and a customer resource for the customer who abandoned the cart.

🚧

The automation start Abandons cart will only trigger if the E-Commerce order source is from a realtime webhook ecomOrder.source = 1. For more information please read this article.

Creating an Abandoned Cart

In the v3 order API, carts and orders are the same type of object: E-Commerce Orders.

To create an abandoned cart, create an order using the v3 order API. To create an abandoned cart, ensure the following:

  • externalid is set to null.
  • Include an externalcheckoutid. This is the ID of the cart within your integration.
  • Include an abandoned_date in the past. This is the date the cart was abandoned by the user.

Recovering an Abandoned Cart

If a user completes purchase of an abandoned cart, the order will transition to the state of recovered. In order to transition an order to recovered, simply do an update order operation on your abandoned cart and set the externalid to be the identifier of the order in your external system.