example-data.com

invoices / #72

fromUserId
125
toUserId
137
invoiceNumber
INV-2025-0072
status
overdue
issuedAt
dueAt
paidAt
subtotal
7346.19
tax
1101.93
total
8448.12
currency
AUD
lineItems
[
  {
    "description": "Implementation services",
    "quantity": 18,
    "unitPrice": 399.13,
    "lineTotal": 7184.34
  },
  {
    "description": "Implementation services",
    "quantity": 5,
    "unitPrice": 32.37,
    "lineTotal": 161.85
  }
]
createdAt

Component variants

curl -sS \
  "https://example-data.com/api/v1/invoices/72" \
  -H "Accept: application/json"
const res = await fetch(
  "https://example-data.com/api/v1/invoices/72"
);
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/72"
);
const invoice = (await res.json()) as Invoice;
import requests

res = requests.get(
    "https://example-data.com/api/v1/invoices/72"
)
invoice = res.json()
{
  "id": 72,
  "fromUserId": 125,
  "toUserId": 137,
  "invoiceNumber": "INV-2025-0072",
  "status": "overdue",
  "issuedAt": "2025-03-04T09:33:52.709Z",
  "dueAt": "2025-04-23T09:33:52.709Z",
  "paidAt": null,
  "subtotal": 7346.19,
  "tax": 1101.93,
  "total": 8448.12,
  "currency": "AUD",
  "lineItems": [
    {
      "description": "Implementation services",
      "quantity": 18,
      "unitPrice": 399.13,
      "lineTotal": 7184.34
    },
    {
      "description": "Implementation services",
      "quantity": 5,
      "unitPrice": 32.37,
      "lineTotal": 161.85
    }
  ],
  "createdAt": "2025-03-03T17:40:39.071Z"
}
Draftbit