example-data.com

food-orders / #20

userId
Ari Howe @ari.howe73
restaurantId
Hudson - Lueilwitz · South Lesliefurt · ★ 4.9
items
[
  {
    "menuItemId": 579,
    "quantity": 4,
    "unitPrice": 17.49,
    "lineTotal": 69.96
  }
]
subtotal
69.96
deliveryFee
6.05
tip
8.69
total
84.7
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

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

res = requests.get(
    "https://example-data.com/api/v1/food-orders/20"
)
food_order = res.json()
{
  "id": 20,
  "userId": 167,
  "restaurantId": 40,
  "items": [
    {
      "menuItemId": 579,
      "quantity": 4,
      "unitPrice": 17.49,
      "lineTotal": 69.96
    }
  ],
  "subtotal": 69.96,
  "deliveryFee": 6.05,
  "tip": 8.69,
  "total": 84.7,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2025-01-24T02:03:53.446Z",
  "deliveredAt": "2025-01-24T04:01:06.828Z"
}
Draftbit