example-data.com
Menu
Browse docs and collections

Overview

food-orders / #423

food-orders #423

userId
Daisy Kuhic @daisy_kuhic24
restaurantId
Howe, Kunde and Ortiz · Rosemead · ★ 4.9
items
              [
  {
    "menuItemId": 1152,
    "quantity": 1,
    "unitPrice": 19.43,
    "lineTotal": 19.43
  },
  {
    "menuItemId": 1167,
    "quantity": 3,
    "unitPrice": 74.11,
    "lineTotal": 222.33
  },
  {
    "menuItemId": 1153,
    "quantity": 2,
    "unitPrice": 5.83,
    "lineTotal": 11.66
  },
  {
    "menuItemId": 1156,
    "quantity": 4,
    "unitPrice": 35.71,
    "lineTotal": 142.84
  },
  {
    "menuItemId": 1171,
    "quantity": 3,
    "unitPrice": 79.93,
    "lineTotal": 239.79
  }
]
            
subtotal
636.05
deliveryFee
6.82
tip
5.05
total
647.92
currency
USD
status
out_for_delivery
placedAt
deliveredAt

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/food-orders/423" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/food-orders/423"
);
const foodOrder = await res.json();

TypeScript example

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

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

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/food-orders/423"
)
food_order = res.json()

Response

{
  "id": 423,
  "userId": 172,
  "restaurantId": 79,
  "items": [
    {
      "menuItemId": 1152,
      "quantity": 1,
      "unitPrice": 19.43,
      "lineTotal": 19.43
    },
    {
      "menuItemId": 1167,
      "quantity": 3,
      "unitPrice": 74.11,
      "lineTotal": 222.33
    },
    {
      "menuItemId": 1153,
      "quantity": 2,
      "unitPrice": 5.83,
      "lineTotal": 11.66
    },
    {
      "menuItemId": 1156,
      "quantity": 4,
      "unitPrice": 35.71,
      "lineTotal": 142.84
    },
    {
      "menuItemId": 1171,
      "quantity": 3,
      "unitPrice": 79.93,
      "lineTotal": 239.79
    }
  ],
  "subtotal": 636.05,
  "deliveryFee": 6.82,
  "tip": 5.05,
  "total": 647.92,
  "currency": "USD",
  "status": "out_for_delivery",
  "placedAt": "2025-10-17T19:58:24.836Z",
  "deliveredAt": null
}