Return
object type
A sales Return / RMA — the customer→merchant goods-back document (distinct from vendor RTV; the disjoint law: a billing correction is a CreditNote/DebitNote, never a Return). References the original Order (+ optionally one of its Invoices); returns WHOLE units of order lines; receive posts per-line disposition legs at the RECEIVING LF and stamps the telescoping refund money; refund RECORDS the routing (tender mechanics; store-credit issuance).
Fields
| Field | Type | Notes |
|---|---|---|
id | ID ID! | The record’s id — a UUID the platform assigned when the record was created; every reference to this record uses it. |
sysId | String String! | The group-scoped human-facing system id (RT-…). |
type | String String! | The kind of record — always Return here. |
caption | String String! | The record’s display name — what people see it called. |
status | String String! | The FSM state: requested | approved | received | refunded | closed | cancelled | rejected. |
parentId | ID ID! | The processing/receiving LogicalFacility; rootId = the org group; parentId!== rootId always. |
rootId | ID ID! | The org-group family root. |
createdAt | String String! | When the record was created, as a UTC timestamp. |
updatedAt | String String! | When the record last changed, as a UTC timestamp. |
revisionNum | Int Int! | How many times this record has been edited; the first save is 0. |
revision | ID ID! | The OCC revision token — supply it on every mutation of this record; rotates on every write. |
refCaptions | RefCaption [RefCaption!]! | The server-composed captions of this record's declared references (the referenced-caption rule) — one row per referenced id; see RefCaption. |
orderId | ID ID! | The returned Order. |
invoiceId | ID | Optional Invoice ref (receipted returns) — belongs to orderId, gated at create. |
organizationId | ID ID! | The selling Organization (copied from the Order at create — attribution). |
currency | String String! | The order currency (copied at create; refunds never cross currency). |
customer | OrderCustomer | The order's inline customer capture, copied at create (identity on the RMA — audit). |
refundTotalMinor | Int | RECEIVE-stamped: Σ line refundMinor — the total owed back (absent until received). |
refund | ReturnRefund | REFUND-stamped: the routing record (amount = refundTotalMinor; state = the FSM). |
lines | ReturnLine [ReturnLine!]! | The return lines (1..45); each refs an order line by its frozen lineNo. |