example-data.com

food-orders / #135

userId
Lilla Koss @lilla.koss
restaurantId
Hauck, Larson and West · Port Shayna · ★ 4.4
items
[
  {
    "menuItemId": 1091,
    "quantity": 1,
    "unitPrice": 40.42,
    "lineTotal": 40.42
  }
]
subtotal
40.42
deliveryFee
0.3
tip
8.53
total
49.25
currency
USD
status
cancelled
placedAt
deliveredAt

Component variants

Related

curl -sS \
  "https://example-data.com/api/v1/food-orders/135" \
  -H "Accept: application/json"
const res = await fetch(
  "https://example-data.com/api/v1/food-orders/135"
);
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/135"
);
const foodOrder = (await res.json()) as FoodOrder;
import requests

res = requests.get(
    "https://example-data.com/api/v1/food-orders/135"
)
food_order = res.json()
{
  "id": 135,
  "userId": 59,
  "restaurantId": 73,
  "items": [
    {
      "menuItemId": 1091,
      "quantity": 1,
      "unitPrice": 40.42,
      "lineTotal": 40.42
    }
  ],
  "subtotal": 40.42,
  "deliveryFee": 0.3,
  "tip": 8.53,
  "total": 49.25,
  "currency": "USD",
  "status": "cancelled",
  "placedAt": "2025-02-24T23:59:54.571Z",
  "deliveredAt": null
}
Draftbit