example-data.com

invoices / #21

fromUserId
123
toUserId
95
invoiceNumber
INV-2026-0021
status
paid
issuedAt
dueAt
paidAt
subtotal
28858.7
tax
1442.94
total
30301.64
currency
USD
lineItems
[
  {
    "description": "Quality assurance",
    "quantity": 11,
    "unitPrice": 299.55,
    "lineTotal": 3295.05
  },
  {
    "description": "Legal review",
    "quantity": 4,
    "unitPrice": 69.61,
    "lineTotal": 278.44
  },
  {
    "description": "System integration",
    "quantity": 33,
    "unitPrice": 467.16,
    "lineTotal": 15416.28
  },
  {
    "description": "Design work",
    "quantity": 19,
    "unitPrice": 318.98,
    "lineTotal": 6060.62
  },
  {
    "description": "Technical support",
    "quantity": 9,
    "unitPrice": 401.29,
    "lineTotal": 3611.61
  },
  {
    "description": "Project management",
    "quantity": 14,
    "unitPrice": 14.05,
    "lineTotal": 196.7
  }
]
createdAt

Component variants

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

res = requests.get(
    "https://example-data.com/api/v1/invoices/21"
)
invoice = res.json()
{
  "id": 21,
  "fromUserId": 123,
  "toUserId": 95,
  "invoiceNumber": "INV-2026-0021",
  "status": "paid",
  "issuedAt": "2026-02-06T23:38:02.699Z",
  "dueAt": "2026-03-21T23:38:02.699Z",
  "paidAt": "2026-02-21T05:11:50.854Z",
  "subtotal": 28858.7,
  "tax": 1442.94,
  "total": 30301.64,
  "currency": "USD",
  "lineItems": [
    {
      "description": "Quality assurance",
      "quantity": 11,
      "unitPrice": 299.55,
      "lineTotal": 3295.05
    },
    {
      "description": "Legal review",
      "quantity": 4,
      "unitPrice": 69.61,
      "lineTotal": 278.44
    },
    {
      "description": "System integration",
      "quantity": 33,
      "unitPrice": 467.16,
      "lineTotal": 15416.28
    },
    {
      "description": "Design work",
      "quantity": 19,
      "unitPrice": 318.98,
      "lineTotal": 6060.62
    },
    {
      "description": "Technical support",
      "quantity": 9,
      "unitPrice": 401.29,
      "lineTotal": 3611.61
    },
    {
      "description": "Project management",
      "quantity": 14,
      "unitPrice": 14.05,
      "lineTotal": 196.7
    }
  ],
  "createdAt": "2026-02-06T12:46:42.057Z"
}
Draftbit