example-data.com
Menu
Browse docs and collections

Overview

orders / #170

orders #170

userId
Alvena Emmerich @alvena_emmerich52
status
delivered
currency
USD
subtotal
807.72
tax
70.68
shipping
0
total
878.4
placedAt
shippedAt
deliveredAt
createdAt
updatedAt

Component variants

Related

Request

curl example

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

JavaScript example

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

TypeScript example

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

const res = await fetch(
  "https://example-data.com/api/v1/orders/170"
);
const order = (await res.json()) as Order;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/orders/170"
)
order = res.json()

Response

{
  "id": 170,
  "userId": 8,
  "status": "delivered",
  "currency": "USD",
  "subtotal": 807.72,
  "tax": 70.68,
  "shipping": 0,
  "total": 878.4,
  "placedAt": "2025-06-03T07:46:43.445Z",
  "shippedAt": "2025-06-05T20:10:34.418Z",
  "deliveredAt": "2025-06-11T11:54:14.529Z",
  "createdAt": "2025-06-03T07:46:43.445Z",
  "updatedAt": "2025-06-11T11:54:14.529Z"
}