example-data.com
Menu
Browse docs and collections

Overview

food-orders / #379

food-orders #379

userId
Jennifer Hoeger @jennifer.hoeger
restaurantId
Gerhold - Dietrich · North Joshua · ★ 4.9
items
              [
  {
    "menuItemId": 957,
    "quantity": 1,
    "unitPrice": 71.28,
    "lineTotal": 71.28
  },
  {
    "menuItemId": 948,
    "quantity": 1,
    "unitPrice": 63.65,
    "lineTotal": 63.65
  },
  {
    "menuItemId": 949,
    "quantity": 4,
    "unitPrice": 24.93,
    "lineTotal": 99.72
  },
  {
    "menuItemId": 953,
    "quantity": 2,
    "unitPrice": 64.98,
    "lineTotal": 129.96
  }
]
            
subtotal
364.61
deliveryFee
7.34
tip
1.41
total
373.36
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 379,
  "userId": 119,
  "restaurantId": 63,
  "items": [
    {
      "menuItemId": 957,
      "quantity": 1,
      "unitPrice": 71.28,
      "lineTotal": 71.28
    },
    {
      "menuItemId": 948,
      "quantity": 1,
      "unitPrice": 63.65,
      "lineTotal": 63.65
    },
    {
      "menuItemId": 949,
      "quantity": 4,
      "unitPrice": 24.93,
      "lineTotal": 99.72
    },
    {
      "menuItemId": 953,
      "quantity": 2,
      "unitPrice": 64.98,
      "lineTotal": 129.96
    }
  ],
  "subtotal": 364.61,
  "deliveryFee": 7.34,
  "tip": 1.41,
  "total": 373.36,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2026-02-10T23:56:09.939Z",
  "deliveredAt": "2026-02-11T01:13:46.102Z"
}