example-data.com
Menu
Browse docs and collections

Overview

carts / #109

carts #109

userId
Hilda Crooks @hilda_crooks61
currency
USD
subtotal
2993.37
itemCount
13
updatedAt
createdAt

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/carts/109" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/carts/109"
);
const cart = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/carts.d.ts https://example-data.com/types/carts.d.ts
import type { Cart } from "./types/carts";

const res = await fetch(
  "https://example-data.com/api/v1/carts/109"
);
const cart = (await res.json()) as Cart;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/carts/109"
)
cart = res.json()

Response

{
  "id": 109,
  "userId": 187,
  "currency": "USD",
  "subtotal": 2993.37,
  "itemCount": 13,
  "updatedAt": "2025-08-08T10:45:06.872Z",
  "createdAt": "2024-08-16T23:39:03.497Z"
}