example-data.com
Menu
Browse docs and collections

Overview

invoices / #278

invoices #278

fromUserId
Bradford Doyle @bradford.doyle42
toUserId
Webster Skiles @webster_skiles39
invoiceNumber
INV-2026-0278
status
cancelled
issuedAt
dueAt
paidAt
subtotal
37191.13
tax
0
total
37191.13
currency
AUD
lineItems
              [
  {
    "description": "Content writing",
    "quantity": 9,
    "unitPrice": 407.12,
    "lineTotal": 3664.08
  },
  {
    "description": "Accounting services",
    "quantity": 30,
    "unitPrice": 214.13,
    "lineTotal": 6423.9
  },
  {
    "description": "Software development",
    "quantity": 33,
    "unitPrice": 70.45,
    "lineTotal": 2324.85
  },
  {
    "description": "Documentation",
    "quantity": 24,
    "unitPrice": 106.69,
    "lineTotal": 2560.56
  },
  {
    "description": "Maintenance contract",
    "quantity": 19,
    "unitPrice": 464.86,
    "lineTotal": 8832.34
  },
  {
    "description": "Legal review",
    "quantity": 28,
    "unitPrice": 478.05,
    "lineTotal": 13385.4
  }
]
            
createdAt

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/invoices/278" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/invoices/278"
);
const invoice = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/invoices.d.ts https://example-data.com/types/invoices.d.ts
import type { Invoice } from "./types/invoices";

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

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/invoices/278"
)
invoice = res.json()

Response

{
  "id": 278,
  "fromUserId": 79,
  "toUserId": 5,
  "invoiceNumber": "INV-2026-0278",
  "status": "cancelled",
  "issuedAt": "2026-03-18T08:01:33.001Z",
  "dueAt": "2026-04-05T08:01:33.001Z",
  "paidAt": null,
  "subtotal": 37191.13,
  "tax": 0,
  "total": 37191.13,
  "currency": "AUD",
  "lineItems": [
    {
      "description": "Content writing",
      "quantity": 9,
      "unitPrice": 407.12,
      "lineTotal": 3664.08
    },
    {
      "description": "Accounting services",
      "quantity": 30,
      "unitPrice": 214.13,
      "lineTotal": 6423.9
    },
    {
      "description": "Software development",
      "quantity": 33,
      "unitPrice": 70.45,
      "lineTotal": 2324.85
    },
    {
      "description": "Documentation",
      "quantity": 24,
      "unitPrice": 106.69,
      "lineTotal": 2560.56
    },
    {
      "description": "Maintenance contract",
      "quantity": 19,
      "unitPrice": 464.86,
      "lineTotal": 8832.34
    },
    {
      "description": "Legal review",
      "quantity": 28,
      "unitPrice": 478.05,
      "lineTotal": 13385.4
    }
  ],
  "createdAt": "2026-03-17T12:08:02.235Z"
}