example-data.com

food-orders / #210

userId
Era Mitchell @era.mitchell21
restaurantId
Hickle, Glover and Christiansen · Zulauffurt · ★ 3.7
items
[
  {
    "menuItemId": 318,
    "quantity": 4,
    "unitPrice": 5.96,
    "lineTotal": 23.84
  },
  {
    "menuItemId": 314,
    "quantity": 1,
    "unitPrice": 10.27,
    "lineTotal": 10.27
  },
  {
    "menuItemId": 320,
    "quantity": 1,
    "unitPrice": 19.94,
    "lineTotal": 19.94
  },
  {
    "menuItemId": 323,
    "quantity": 2,
    "unitPrice": 75.38,
    "lineTotal": 150.76
  },
  {
    "menuItemId": 307,
    "quantity": 4,
    "unitPrice": 69.37,
    "lineTotal": 277.48
  }
]
subtotal
482.29
deliveryFee
3.38
tip
9.17
total
494.84
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

curl -sS \
  "https://example-data.com/api/v1/food-orders/210" \
  -H "Accept: application/json"
const res = await fetch(
  "https://example-data.com/api/v1/food-orders/210"
);
const foodOrder = await res.json();
import type { FoodOrder } from "https://example-data.com/types/food-orders.d.ts";

const res = await fetch(
  "https://example-data.com/api/v1/food-orders/210"
);
const foodOrder = (await res.json()) as FoodOrder;
import requests

res = requests.get(
    "https://example-data.com/api/v1/food-orders/210"
)
food_order = res.json()
{
  "id": 210,
  "userId": 243,
  "restaurantId": 20,
  "items": [
    {
      "menuItemId": 318,
      "quantity": 4,
      "unitPrice": 5.96,
      "lineTotal": 23.84
    },
    {
      "menuItemId": 314,
      "quantity": 1,
      "unitPrice": 10.27,
      "lineTotal": 10.27
    },
    {
      "menuItemId": 320,
      "quantity": 1,
      "unitPrice": 19.94,
      "lineTotal": 19.94
    },
    {
      "menuItemId": 323,
      "quantity": 2,
      "unitPrice": 75.38,
      "lineTotal": 150.76
    },
    {
      "menuItemId": 307,
      "quantity": 4,
      "unitPrice": 69.37,
      "lineTotal": 277.48
    }
  ],
  "subtotal": 482.29,
  "deliveryFee": 3.38,
  "tip": 9.17,
  "total": 494.84,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2025-01-26T06:28:42.306Z",
  "deliveredAt": "2025-01-26T09:05:34.864Z"
}
Draftbit