Shopping cart containing items a customer intends to purchase. Tracks cart contents, total value, currency, status, and timestamps for e-commerce checkout processes.
https://api.mockly.codes/carts?page=1&limit=10&count=10Configure your request and click Send Request to see the response here.
/cartsGet a collection of carts
/commerce/carts/carts/:idGet a single cart by ID
/commerce/carts/:id/carts/metaGet resource metadata and schema
/commerce/carts/metaThe search feature allows you to filter results by searching for text across all or specific fields. Choose between ?q= or ?search= parameter names.
Search across all text fields:
GET https://api.mockly.codes/carts?q=laptopGET https://api.mockly.codes/carts?q=laptop&search_fields=name,descriptionsearch_fields, all text fields are searched// Get 10 carts
fetch('https://api.mockly.codes/carts?count=10')
.then(res => res.json())
.then(data => console.log(data));import requests
response = requests.get(
'https://api.mockly.codes/carts?count=10'
)
data = response.json()curl "https://api.mockly.codes/carts?count=10"fetch('https://api.mockly.codes/carts?nocache=true')idintegerUnique identifier for the shopping cart
random_intuser_idintegerForeign key reference to the user or customer who owns this cart
random_intitemsarrayArray of product identifiers or item names currently in the cart
tagstotalnumberTotal price of all items in the cart including any applicable discounts
pricecurrencystringISO currency code for the cart total (e.g., USD, EUR, GBP)
currencystatusstringCurrent status of the cart (e.g., active, abandoned, converted, expired)
statuscreated_atstringTimestamp when the cart was first created
past_datedate-timeupdated_atstringTimestamp when the cart was last modified
past_datedate-timecountintegerNumber of items to return (default: 10, max: 100)
seedintegerSeed for reproducible data generation
nocachebooleanBypass cache and generate fresh data on every request