example-data.com

invoices / #38

fromUserId
60
toUserId
17
invoiceNumber
INV-2025-0038
status
paid
issuedAt
dueAt
paidAt
subtotal
19542.31
tax
977.12
total
20519.43
currency
AUD
lineItems
[
  {
    "description": "Project management",
    "quantity": 24,
    "unitPrice": 227.34,
    "lineTotal": 5456.16
  },
  {
    "description": "Consulting services",
    "quantity": 3,
    "unitPrice": 339.98,
    "lineTotal": 1019.94
  },
  {
    "description": "Documentation",
    "quantity": 26,
    "unitPrice": 310.92,
    "lineTotal": 8083.92
  },
  {
    "description": "System integration",
    "quantity": 7,
    "unitPrice": 407.11,
    "lineTotal": 2849.77
  },
  {
    "description": "License fee",
    "quantity": 39,
    "unitPrice": 54.68,
    "lineTotal": 2132.52
  }
]
createdAt

Component variants

curl -sS \
  "https://example-data.com/api/v1/invoices/38" \
  -H "Accept: application/json"
const res = await fetch(
  "https://example-data.com/api/v1/invoices/38"
);
const invoice = await res.json();
import type { Invoice } from "https://example-data.com/types/invoices.d.ts";

const res = await fetch(
  "https://example-data.com/api/v1/invoices/38"
);
const invoice = (await res.json()) as Invoice;
import requests

res = requests.get(
    "https://example-data.com/api/v1/invoices/38"
)
invoice = res.json()
{
  "id": 38,
  "fromUserId": 60,
  "toUserId": 17,
  "invoiceNumber": "INV-2025-0038",
  "status": "paid",
  "issuedAt": "2025-07-10T17:35:28.032Z",
  "dueAt": "2025-08-15T17:35:28.032Z",
  "paidAt": "2025-07-18T07:50:09.644Z",
  "subtotal": 19542.31,
  "tax": 977.12,
  "total": 20519.43,
  "currency": "AUD",
  "lineItems": [
    {
      "description": "Project management",
      "quantity": 24,
      "unitPrice": 227.34,
      "lineTotal": 5456.16
    },
    {
      "description": "Consulting services",
      "quantity": 3,
      "unitPrice": 339.98,
      "lineTotal": 1019.94
    },
    {
      "description": "Documentation",
      "quantity": 26,
      "unitPrice": 310.92,
      "lineTotal": 8083.92
    },
    {
      "description": "System integration",
      "quantity": 7,
      "unitPrice": 407.11,
      "lineTotal": 2849.77
    },
    {
      "description": "License fee",
      "quantity": 39,
      "unitPrice": 54.68,
      "lineTotal": 2132.52
    }
  ],
  "createdAt": "2025-07-09T20:23:51.283Z"
}
Draftbit