example-data.com
Menu
Browse docs and collections

orders

orders

Page 39 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": 913,
      "userId": 230,
      "status": "refunded",
      "currency": "USD",
      "subtotal": 1810.7,
      "tax": 158.44,
      "shipping": 0,
      "total": 1969.14,
      "placedAt": "2025-12-16T17:34:44.236Z",
      "shippedAt": null,
      "deliveredAt": null,
      "createdAt": "2025-12-16T17:34:44.236Z",
      "updatedAt": "2025-12-16T17:34:44.236Z"
    },
    {
      "id": 914,
      "userId": 170,
      "status": "cancelled",
      "currency": "USD",
      "subtotal": 4591.21,
      "tax": 401.73,
      "shipping": 0,
      "total": 4992.94,
      "placedAt": "2025-04-11T18:30:50.670Z",
      "shippedAt": null,
      "deliveredAt": null,
      "createdAt": "2025-04-11T18:30:50.670Z",
      "updatedAt": "2025-04-11T18:30:50.670Z"
    },
    {
      "id": 915,
      "userId": 181,
      "status": "delivered",
      "currency": "USD",
      "subtotal": 1992.93,
      "tax": 174.38,
      "shipping": 0,
      "total": 2167.31,
      "placedAt": "2025-09-21T09:55:25.205Z",
      "shippedAt": "2025-09-23T20:32:27.071Z",
      "deliveredAt": "2025-09-30T06:06:56.816Z",
      "createdAt": "2025-09-21T09:55:25.205Z",
      "updatedAt": "2025-09-30T06:06:56.816Z"
    }
  ],
  "meta": {
    "page": 39,
    "limit": 24,
    "total": 1000,
    "totalPages": 42
  },
  "links": {
    "self": "/api/v1/orders?page=39&limit=24",
    "first": "/api/v1/orders?page=1&limit=24",
    "last": "/api/v1/orders?page=42&limit=24",
    "next": "/api/v1/orders?page=40&limit=24",
    "prev": "/api/v1/orders?page=38&limit=24"
  }
}