orders #301
- userId
-
Arnaldo Friesen @arnaldo_friesen78
- status
- delivered
- currency
- USD
- subtotal
- 3425.34
- tax
- 299.72
- shipping
- 0
- total
- 3725.06
- placedAt
- shippedAt
- deliveredAt
- createdAt
- updatedAt
Overview
orders / #301
#301
#301
Request
curl example
curl -sS \ "https://example-data.com/api/v1/orders/301" \ -H "Accept: application/json"
JavaScript example
const res = await fetch( "https://example-data.com/api/v1/orders/301" ); 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/301"
);
const order = (await res.json()) as Order; Python example
import requests
res = requests.get(
"https://example-data.com/api/v1/orders/301"
)
order = res.json() Response
{
"id": 301,
"userId": 113,
"status": "delivered",
"currency": "USD",
"subtotal": 3425.34,
"tax": 299.72,
"shipping": 0,
"total": 3725.06,
"placedAt": "2024-12-15T12:14:58.599Z",
"shippedAt": "2024-12-17T17:39:26.672Z",
"deliveredAt": "2024-12-19T14:02:00.649Z",
"createdAt": "2024-12-15T12:14:58.599Z",
"updatedAt": "2024-12-19T14:02:00.649Z"
}