AlmondTill/G3N API

Invoice

object type

A sales Invoice — the billing/revenue-recognition document generated from an Order: an immutable line snapshot at issue (captured prices/discounts/tax copy, telescoping-prorated exactly for the 1..N partial model — a full invoicing sums to the order figures exactly). One order → one-or-many invoices. Born issued by the bespoke issueInvoice op; corrections are NEW CreditNote/DebitNote documents, never an edit — no update surface exists. The GAAP recognition trail is reports-only; the three rollup vectors are animated derived read-models.

Fields

FieldTypeNotes
idID ID!The record’s id — a UUID the platform assigned when the record was created; every reference to this record uses it.
sysIdString String!The human-readable id, shaped like IN-… — stable for the record’s life.
typeString String!The kind of record — always Invoice here.
captionString String!The record’s display name — what people see it called.
statusString String!The record’s current state — one of issued, closed or voided.
parentIdID ID!The order's parent — the LF or org; for an Invoice parentId!== rootId.
rootIdID ID!The id of your organization group — every record of yours carries the same one.
createdAtString String!When the record was created, as a UTC timestamp.
updatedAtString String!When the record last changed, as a UTC timestamp.
revisionNumInt Int!How many times this record has been edited; the first save is 0.
revisionID ID!The id of the record’s current edit — send it back with a change so an edit made in the meantime is refused instead of overwritten.
refCaptionsRefCaption [RefCaption!]!The captions of the records this one refers to, composed for you — one row per referenced id; see RefCaption.
orderIdID ID!The invoiced Order.
organizationIdID ID!The selling Organization (copied from the Order at issue — attribution).
currencyString String!The order currency.
taxModeInvoiceTaxMode InvoiceTaxMode!The pricing mode captured at issue — exclusive (sales_tax adds on top) or inclusive (vat_gst inside the captured prices); the note recompute reads this.
customerOrderCustomerThe order's inline customer capture, copied at issue.
taxJurisdictionIdIDThe order's captured origin jurisdiction, copied at issue.
paymentStateString String!The payment rollup, animated: unpaid → partial → paid — FIFO-by-issue money coverage derived from the Order’s net tenders (closed invoices pin first; a refund walks an issued invoice back honestly — the newest invoice regresses first).
fulfillmentStateString String!The fulfillment rollup, animated: unfulfilled → partial → fulfilled — per-line FIFO delivery allocation over the Order’s fulfilledQty stamps.
recognitionStateString String!The recognition rollup, animated: deferred → partial → recognized — the deposits-until-delivery conversion; mirrors the fulfillment allocation until fiscal/service chunks diverge them. recognized + paid flips the invoice closed.
subtotalMinorInt Int!Σ snapshot-line bases in minor units (exact telescoping shares).
discountTotalMinorInt Int!Σ snapshot-line discount shares (line + order-level), minor units.
taxTotalMinorInt Int!Σ snapshot-line tax in minor units (inside the captured figures under inclusive taxMode — disclosed, not double-counted).
totalMinorInt Int!The invoiced total in minor units (mode-aware line totals summed).
linesInvoiceLine [InvoiceLine!]!The immutable snapshot lines (1..45); the notedBaseDeltaMinor rollups are the ONE post-issue stamp lane.

Used by