Search.../

getAbandonedCart( )

Gets the specified abandoned shopping cart.

Description

The getAbandonedCart() function returns a Promise that resolves to the specified abandoned shopping cart.

Authorization

Request

This endpoint does not take any parameters

Response Object

Fulfilled - The retrieved abandoned cart.

NAME
TYPE
DESCRIPTION
_id
string

Unique identifier of the shopping cart.

abandonTime
string

Date and time the shopping cart was abandoned.

total
string

Total price of all items in the cart.

buyerInfo
BuyerInfo

The buyer's information.

activities
Activity

Log of updates related to the cart.

status
string

Status of the abandoned cart. Either "ABANDONED" or "RECOVERED".

Status/Error Codes

Was this helpful?

Get an abandoned cart

Copy Code
1import wixStoresBackend from 'wix-stores-backend'
2
3export function getAbandonedCart() {
4 return wixStoresBackend.getAbandonedCart();
5}
6
7/* Returned promise resolves to:
8 *
9 * {
10 * "_id": "b5b63fe3-85f0-459a-b90f-7195ebc727f8",
11 * "abandonTime": "2019-06-19T12:20:14.998Z",
12 * "total": "$25.00",
13 * "buyerInfo": {
14 * "id": "f6c0f9c2-a02d-4e9f-a58d-99729af244d9",
15 * "firstName": "John",
16 * "lastName": "Doe",
17 * "email": "john.doe@somedomain.com",
18 * "phone": "5555555555",
19 * "identityType": "CONTACT"
20 * },
21 * "activities": [
22 * {
23 * "type":"EMAIL_SENT",
24 * "timestamp":"2019-11-10T13:57:23.356Z",
25 * "message":"email status has changed to: EMAIL_SENT",
26 * "customData":{
27 * "namespace":"wixstores_email_status"
28 * }
29 * }
30 * ],
31 * "status": "ABANDONED"
32 * }
33 */