example-data.com
Menu
Browse docs and collections

Overview

food-orders / #444

food-orders #444

userId
Norbert Jacobi @norbert_jacobi92
restaurantId
Hayes - McDermott · Lake Tanya · ★ 2.5
items
              [
  {
    "menuItemId": 1010,
    "quantity": 4,
    "unitPrice": 61.89,
    "lineTotal": 247.56
  },
  {
    "menuItemId": 1011,
    "quantity": 4,
    "unitPrice": 74.6,
    "lineTotal": 298.4
  },
  {
    "menuItemId": 1017,
    "quantity": 3,
    "unitPrice": 12.46,
    "lineTotal": 37.38
  },
  {
    "menuItemId": 1014,
    "quantity": 3,
    "unitPrice": 31.24,
    "lineTotal": 93.72
  },
  {
    "menuItemId": 1012,
    "quantity": 3,
    "unitPrice": 25.27,
    "lineTotal": 75.81
  }
]
            
subtotal
752.87
deliveryFee
4.78
tip
7.42
total
765.07
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

Request

curl example

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

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/food-orders/444"
);
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/444"
);
const foodOrder = (await res.json()) as FoodOrder;

Python example

import requests

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

Response

{
  "id": 444,
  "userId": 101,
  "restaurantId": 68,
  "items": [
    {
      "menuItemId": 1010,
      "quantity": 4,
      "unitPrice": 61.89,
      "lineTotal": 247.56
    },
    {
      "menuItemId": 1011,
      "quantity": 4,
      "unitPrice": 74.6,
      "lineTotal": 298.4
    },
    {
      "menuItemId": 1017,
      "quantity": 3,
      "unitPrice": 12.46,
      "lineTotal": 37.38
    },
    {
      "menuItemId": 1014,
      "quantity": 3,
      "unitPrice": 31.24,
      "lineTotal": 93.72
    },
    {
      "menuItemId": 1012,
      "quantity": 3,
      "unitPrice": 25.27,
      "lineTotal": 75.81
    }
  ],
  "subtotal": 752.87,
  "deliveryFee": 4.78,
  "tip": 7.42,
  "total": 765.07,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2026-02-16T10:50:46.012Z",
  "deliveredAt": "2026-02-16T13:43:27.150Z"
}