cart.list
This method is used to list Carts, filering the results and selecting the fields returned.
Version
v2
Arguments
This method has the path /cart/<version>/cart.list
and
follows the MicroBase API calling conventions.
Argument | Required | Type | Example | Description |
---|---|---|---|---|
id | no | String List | SJlkcsaQ, WER1YST2 | Comma separated Cart ids list. |
status | no | String List | ACTIVE | Comma separated statuses list. |
customerId | no | String | r1Qk_gpgX | Customer id. |
currency | no | String List | EUR, USD | Comma separated Currency list to return. |
country | no | String List | CA, ES | Comma separated Country list to return. |
channel | no | String List | WEB | Comma separated Channel list to return. |
gateway | no | String List | stripe | Comma separated Gateway list to return. |
limit | no | Number | 5 | Maximum number of documents to return. Defaults to 10 |
skip | no | Number | 10 | Skips over the first specified number of documents. Defaults to 0 . |
Response
Returns a page:
{
"ok": true,
"page": {
"limit": 10,
"skip": 0
},
"data": [
{
"id": "H19PRsec",
"customerId": "ANON",
"expirationTime": "2016-08-23T15:16:50.407Z",
"tax": 0,
"beforeTax": 0,
"items": []
}
]
}
Errors
Expected errors that this method could return. Some errors return additional data.
Error | Data | Description |
---|---|---|
Example
curl --request GET \
--url http://localhost:3001/services/cart/v2/cart.list?customerId=r1xf4pZ1Q-&status=ACTIVE \
--header 'authorization: Bearer xxxxx...' \
--header 'accept: application/json' \
--header 'content-type: application/json'