ApprovalRequest
object type
An ApprovalRequest — the real-time, human-approver, in-session authorization of one POS action exceeding the requester's authority (distinct from the async ChangeRequest). The blocked action stays blocked until resolved; short TTL. The request binds a fingerprint (action, targetId[, valueMinor]) + the requester: on approval, retrying the identical gated call finds + consumes the approval by fingerprint. Never self-approve (AUTHZ/SELF_APPROVAL); an under-ranked approver is AUTHZ/INSUFFICIENT.
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 human-readable id, shaped like AR-… — stable for the record’s life. |
type | String String! | The kind of record — always ApprovalRequest here. |
caption | String String! | The record’s display name — what people see it called. |
status | String String! | The record’s current state — one of pending, approved, denied, expired or cancelled. |
parentId | ID ID! | deterministic parent: the open TillSession when the action runs in a till session, else the LF; rootId = the org group regardless. |
rootId | ID ID! | The id of your organization group — every record of yours carries the same one. |
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 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. |
refCaptions | RefCaption [RefCaption!]! | The captions of the records this one refers to, composed for you — one row per referenced id; see RefCaption. |
action | String String! | The gated action: discount.apply · price.override · void.line · void.transaction · return.approve · sale.restricted_item · no_sale · oversell · refund.routing_exception · credit.over_limit · order.below_minimum. Live: discount.apply · void.transaction · return.approve · no_sale · refund.routing_exception · credit.over_limit · order.below_minimum; the rest refuse VALIDATION/UNSUPPORTED naming their arrival. |
targetType | String String! | The target construct type — derived from the action, stored for the fingerprint. |
targetId | ID ID! | The blocked action's target construct. |
valueMinor | Int | The bound value when the action carries one — discount.apply binds the discount Σ, exact-matched at consumption; absent for whole-target actions. |
requestedBy | ID ID! | The requesting User. |
requiredTier | RoleTemplateKey RoleTemplateKey! | The required approver tier; the approver's resolved tier rank must be ≥ this tier's rank (AUTHZ/INSUFFICIENT below it). |
reason | String String! | Why the requester needs the override. |
expiresAt | String String! | The live-window end (createdAt + the 900s TTL, ISO-8601): approve/deny/consume past it refuse CONFLICT/EXPIRED and the request lazily expires. |
decidedBy | ID | Decision-stamped: the approving/denying User. |
decidedAt | String | Decision-stamped: the decision instant (ISO-8601). |
decisionReason | String | Decision-stamped: the approver/denier's stated reason (optional — the transition template). |