Raises a manual invoice against a client, with line items.
Required:
ClientId, and at least one line item with ItemId and
Quantity.
Optional:StatusId (defaults to Draft), InvoiceDate (defaults to
today), DueDate (defaults to InvoiceDate), Reference,
RecipientEmails. Per line: UnitPrice, UnitCost, TaxId,
CoaCode, Description, BillableStatusId and DiscountPercent each
fall back to the referenced item’s own value when omitted.
StatusId is 1 (Draft) or 5 (Approved). Approving on create also pushes
the invoice to the connected accounting system. An Approved invoice whose total comes to
exactly 0 is created as Paid instead - check Status on the response rather
than assuming it matches what you sent.
The response is just the created invoice’s Id - the same shape Create Ticket
and Create Time Entry return.
Authorizations
Your Gorelo API key. See Generate API key. If your data is hosted in Australia, click the base URL at the top of this page and select https://api.aue.gorelo.io.
Body
The invoice to create.
Raises a manual invoice against a client, with line items.
Status to create the invoice in: 1 = Draft (default) or 5 = Approved. Any other value is rejected. Approving on create pushes the invoice to the connected accounting system, the same as approving it in the app. An Approved invoice whose computed total is exactly 0 is recorded as Paid instead.
1
Line items for this invoice. At least one is required. Lines carry no task/ticket/time-entry linkage - that belongs to contract-generated invoices, out of scope for a manual one. A line whose ItemId is a bundle is billed as one line and stored as the bundle's parts, the same way the app stores it; the caller never sends the parts.
Response
OK
100, 101, 102, 103, 200, 201, 202, 203, 204, 205, 206, 207, 208, 226, 300, 301, 302, 303, 304, 305, 306, 307, 308, 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, 416, 417, 421, 422, 423, 424, 426, 428, 429, 431, 451, 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, 511