example-data.com
Menu
Browse docs and collections

Overview

food-orders / #264

food-orders #264

userId
Conrad Connelly @conrad.connelly22
restaurantId
McDermott - Metz · East Darlene · ★ 2.7
items
              [
  {
    "menuItemId": 60,
    "quantity": 2,
    "unitPrice": 3.97,
    "lineTotal": 7.94
  },
  {
    "menuItemId": 58,
    "quantity": 2,
    "unitPrice": 33.94,
    "lineTotal": 67.88
  },
  {
    "menuItemId": 54,
    "quantity": 4,
    "unitPrice": 56.24,
    "lineTotal": 224.96
  }
]
            
subtotal
300.78
deliveryFee
2.24
tip
11.57
total
314.59
currency
USD
status
delivered
placedAt
deliveredAt

Component variants

Related

Request

curl example

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

JavaScript example

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

Python example

import requests

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

Response

{
  "id": 264,
  "userId": 30,
  "restaurantId": 6,
  "items": [
    {
      "menuItemId": 60,
      "quantity": 2,
      "unitPrice": 3.97,
      "lineTotal": 7.94
    },
    {
      "menuItemId": 58,
      "quantity": 2,
      "unitPrice": 33.94,
      "lineTotal": 67.88
    },
    {
      "menuItemId": 54,
      "quantity": 4,
      "unitPrice": 56.24,
      "lineTotal": 224.96
    }
  ],
  "subtotal": 300.78,
  "deliveryFee": 2.24,
  "tip": 11.57,
  "total": 314.59,
  "currency": "USD",
  "status": "delivered",
  "placedAt": "2026-02-27T21:26:18.152Z",
  "deliveredAt": "2026-02-27T23:32:54.508Z"
}