example-data.com

invoices / #188

fromUserId
180
toUserId
51
invoiceNumber
INV-2025-0188
status
draft
issuedAt
dueAt
paidAt
subtotal
7063.94
tax
1412.79
total
8476.73
currency
USD
lineItems
[
  {
    "description": "Accounting services",
    "quantity": 15,
    "unitPrice": 155.81,
    "lineTotal": 2337.15
  },
  {
    "description": "Content writing",
    "quantity": 4,
    "unitPrice": 412.91,
    "lineTotal": 1651.64
  },
  {
    "description": "Hardware supply",
    "quantity": 19,
    "unitPrice": 161.85,
    "lineTotal": 3075.15
  }
]
createdAt

Component variants

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

res = requests.get(
    "https://example-data.com/api/v1/invoices/188"
)
invoice = res.json()
{
  "id": 188,
  "fromUserId": 180,
  "toUserId": 51,
  "invoiceNumber": "INV-2025-0188",
  "status": "draft",
  "issuedAt": "2025-03-18T16:02:00.257Z",
  "dueAt": "2025-04-06T16:02:00.257Z",
  "paidAt": null,
  "subtotal": 7063.94,
  "tax": 1412.79,
  "total": 8476.73,
  "currency": "USD",
  "lineItems": [
    {
      "description": "Accounting services",
      "quantity": 15,
      "unitPrice": 155.81,
      "lineTotal": 2337.15
    },
    {
      "description": "Content writing",
      "quantity": 4,
      "unitPrice": 412.91,
      "lineTotal": 1651.64
    },
    {
      "description": "Hardware supply",
      "quantity": 19,
      "unitPrice": 161.85,
      "lineTotal": 3075.15
    }
  ],
  "createdAt": "2025-03-18T04:25:14.451Z"
}
Draftbit