example-data.com
Menu
Browse docs and collections

Overview

food-orders / #430

food-orders #430

userId
Fritz Skiles @fritz_skiles
restaurantId
Schoen, Cole and Bauch · Thompsonberg · ★ 3.1
items
              [
  {
    "menuItemId": 459,
    "quantity": 3,
    "unitPrice": 41,
    "lineTotal": 123
  },
  {
    "menuItemId": 464,
    "quantity": 2,
    "unitPrice": 44.08,
    "lineTotal": 88.16
  },
  {
    "menuItemId": 466,
    "quantity": 4,
    "unitPrice": 18.03,
    "lineTotal": 72.12
  },
  {
    "menuItemId": 475,
    "quantity": 2,
    "unitPrice": 76.5,
    "lineTotal": 153
  }
]
            
subtotal
436.28
deliveryFee
5.2
tip
11.59
total
453.07
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 430,
  "userId": 144,
  "restaurantId": 31,
  "items": [
    {
      "menuItemId": 459,
      "quantity": 3,
      "unitPrice": 41,
      "lineTotal": 123
    },
    {
      "menuItemId": 464,
      "quantity": 2,
      "unitPrice": 44.08,
      "lineTotal": 88.16
    },
    {
      "menuItemId": 466,
      "quantity": 4,
      "unitPrice": 18.03,
      "lineTotal": 72.12
    },
    {
      "menuItemId": 475,
      "quantity": 2,
      "unitPrice": 76.5,
      "lineTotal": 153
    }
  ],
  "subtotal": 436.28,
  "deliveryFee": 5.2,
  "tip": 11.59,
  "total": 453.07,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2026-02-09T20:31:37.783Z",
  "deliveredAt": "2026-02-09T23:31:15.369Z"
}