Hanzo
OpenapiBilling

Read one invoice

Reads one invoice out of the caller's org.

GET /v1/billing/invoices/{id}

Addresshttps://api.hanzo.ai/v1/billing/invoices/{id}
MethodGET
OperationgetInvoice
AuthAuthorization: Bearer $HANZO_API_KEY

Reads one invoice out of the caller's org.

The org scopes the read by construction — the store is namespaced to it — so an id belonging to another tenant is not found rather than found and then filtered.

A named handler, not a closure, so zipdoc can lift this prose into the registry.

Request

1 field.

FieldInTypeRequiredDescription
idpathstringyesID is the invoice id.

Response

StatusBodyMeaning
200Invoiceok

200 body — 16 fields.

FieldInTypeAlwaysDescription
amountDueCentsbodyintegerAmountDueCents is what remains collectible.
amountPaidCentsbodyintegerAmountPaidCents is what has been collected so far.
createdAtbodystringCreatedAt is when the draft was raised, RFC3339.
currencybodystringCurrency is the ISO 4217 code.
customerEmailbodystringCustomerEmail is where it is sent.
idbodystringID is the invoice id — what the issue, collect and void ops address.
linesbodyInvoiceLine[]Lines are the charges on the invoice.
lines[].amountbodyintegerAmount is the line total in whole cents (250000 is $2,500.00).
lines[].descriptionbodystringDescription is the human-readable line, e.g.
lines[].quantitybodyintegerQuantity is the number of units, when the line is metered.
lines[].unitPricebodyintegerUnitPrice is the per-unit price in cents, when the line is metered.
numberbodystringNumber is the human-facing invoice number, e.g.
paymentRefbodystringPaymentRef is the processor reference for the collection, once paid.
statusbodystringStatus is draft, open, paid, void or uncollectible.
subtotalCentsbodyintegerSubtotalCents is the sum of the lines.
userIdbodystringUserID is the customer billed.

Failure carries the platform error shape — see Errors.

Examples

hanzo billing invoices get <id>

Billing API · All Hanzo APIs · Interactive reference

How is this guide?

On this page