example-data.com
Menu
Browse docs and collections

orders

orders

Page 30 of 42.

Overview

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/orders?limit=25"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/orders?limit=25"
);
const { data, meta } = 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, ListEnvelope } from "./types/orders";

const res = await fetch(
  "https://example-data.com/api/v1/orders?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Order>;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/orders",
    params={"limit": 25},
)
data = res.json()

Response

{
  "data": [
    {
      "id": 697,
      "userId": 25,
      "status": "refunded",
      "currency": "USD",
      "subtotal": 1480.96,
      "tax": 129.58,
      "shipping": 0,
      "total": 1610.54,
      "placedAt": "2025-11-26T20:46:28.331Z",
      "shippedAt": null,
      "deliveredAt": null,
      "createdAt": "2025-11-26T20:46:28.331Z",
      "updatedAt": "2025-11-26T20:46:28.331Z"
    },
    {
      "id": 698,
      "userId": 170,
      "status": "confirmed",
      "currency": "USD",
      "subtotal": 2905.63,
      "tax": 254.24,
      "shipping": 0,
      "total": 3159.87,
      "placedAt": "2025-10-24T02:02:49.667Z",
      "shippedAt": null,
      "deliveredAt": null,
      "createdAt": "2025-10-24T02:02:49.667Z",
      "updatedAt": "2025-10-24T02:02:49.667Z"
    },
    {
      "id": 699,
      "userId": 146,
      "status": "pending",
      "currency": "USD",
      "subtotal": 2846.35,
      "tax": 249.06,
      "shipping": 0,
      "total": 3095.41,
      "placedAt": "2024-06-14T15:06:00.231Z",
      "shippedAt": null,
      "deliveredAt": null,
      "createdAt": "2024-06-14T15:06:00.231Z",
      "updatedAt": "2024-06-14T15:06:00.231Z"
    }
  ],
  "meta": {
    "page": 30,
    "limit": 24,
    "total": 1000,
    "totalPages": 42
  },
  "links": {
    "self": "/api/v1/orders?page=30&limit=24",
    "first": "/api/v1/orders?page=1&limit=24",
    "last": "/api/v1/orders?page=42&limit=24",
    "next": "/api/v1/orders?page=31&limit=24",
    "prev": "/api/v1/orders?page=29&limit=24"
  }
}