orders #397
- userId
-
Vidal Parker @vidal_parker12
- status
- delivered
- currency
- USD
- subtotal
- 1895.81
- tax
- 165.88
- shipping
- 0
- total
- 2061.69
- placedAt
- shippedAt
- deliveredAt
- createdAt
- updatedAt
Overview
orders / #397
#397
#397
Request
curl example
curl -sS \ "https://example-data.com/api/v1/orders/397" \ -H "Accept: application/json"
JavaScript example
const res = await fetch( "https://example-data.com/api/v1/orders/397" ); 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/397"
);
const order = (await res.json()) as Order; Python example
import requests
res = requests.get(
"https://example-data.com/api/v1/orders/397"
)
order = res.json() Response
{
"id": 397,
"userId": 203,
"status": "delivered",
"currency": "USD",
"subtotal": 1895.81,
"tax": 165.88,
"shipping": 0,
"total": 2061.69,
"placedAt": "2025-01-06T02:57:11.979Z",
"shippedAt": "2025-01-08T12:57:43.935Z",
"deliveredAt": "2025-01-10T17:30:51.234Z",
"createdAt": "2025-01-06T02:57:11.979Z",
"updatedAt": "2025-01-10T17:30:51.234Z"
}