invoices / #137
- fromUserId
- 47
- toUserId
- 132
- invoiceNumber
- INV-2024-0137
- status
- paid
- issuedAt
- dueAt
- paidAt
- subtotal
- 4394.2
- tax
- 878.84
- total
- 5273.04
- currency
- USD
- lineItems
-
[ { "description": "Marketing services", "quantity": 4, "unitPrice": 135.16, "lineTotal": 540.64 }, { "description": "Consulting services", "quantity": 30, "unitPrice": 76.34, "lineTotal": 2290.2 }, { "description": "Technical support", "quantity": 12, "unitPrice": 130.28, "lineTotal": 1563.36 } ] - createdAt
Component variants
Medium
#137
#137
Small
invoices/137 curl -sS \
"https://example-data.com/api/v1/invoices/137" \
-H "Accept: application/json"const res = await fetch(
"https://example-data.com/api/v1/invoices/137"
);
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/137"
);
const invoice = (await res.json()) as Invoice;import requests
res = requests.get(
"https://example-data.com/api/v1/invoices/137"
)
invoice = res.json() {
"id": 137,
"fromUserId": 47,
"toUserId": 132,
"invoiceNumber": "INV-2024-0137",
"status": "paid",
"issuedAt": "2024-12-17T07:24:16.966Z",
"dueAt": "2025-01-15T07:24:16.966Z",
"paidAt": "2024-12-30T21:01:03.856Z",
"subtotal": 4394.2,
"tax": 878.84,
"total": 5273.04,
"currency": "USD",
"lineItems": [
{
"description": "Marketing services",
"quantity": 4,
"unitPrice": 135.16,
"lineTotal": 540.64
},
{
"description": "Consulting services",
"quantity": 30,
"unitPrice": 76.34,
"lineTotal": 2290.2
},
{
"description": "Technical support",
"quantity": 12,
"unitPrice": 130.28,
"lineTotal": 1563.36
}
],
"createdAt": "2024-12-16T11:02:16.416Z"
}