CommissionConfig
object type
A CommissionConfig — ONE cell of the multi-axis commission matrix (the ReplenishmentConfig SIBLING): the AXES scope WHERE it applies (each SINGULAR, absent = all, IMMUTABLE at birth — re-target = create + doom): Agent (a Role the agent holds at the sale's org ⊕ a specific User) · Merchandise (Division ⊕ Category-SUBTREE ⊕ Style — a style outranks any category depth) · Location (Organization ⊕ LogicalFacility — **the Location axis IS the org scoping; this construct is NOT org-selected**) · Channel. The SPARSE parameters (≥1 required): rate (percent_net = the line's FINAL post-position-5 discounted net · percent_margin = max(net − landed COGS, 0), COGS-absent ⇒ 0 · fixed_per_unit — a currency-mismatched fixed rate is NON-matching) + enabled (false at the winning cell SUPPRESSES the entry). At PLACE, per (line × attributed agent): candidates = ACTIVE cells matching EVERY axis; the winner PER PARAMETER is the most specific (set-axis count, tie-break Agent ≻ Merchandise ≻ Location ≻ Channel). appliesToAllSalesInScope=true + Agent=Role is the manager-on-all override: EVERY active holder of the Role at the sale's org earns additively (entryClass manager_on_all; bounded ≤ 32 holders — the write refuses over, the place mint SKIPS over [the sale never blocks]). the collision rule: an ACTIVE same-normalized-tuple sibling with an intersecting SET-parameter set refuses CONFLICT/IDENTITY_TAKEN naming the holder(s) + the intersection (create, param-GROWING edits, reactivate; same-tuple DISJOINT-parameter cells are LEGAL — the flag rides IN the tuple, so flagged/unflagged never compete). At most 128 ACTIVE per org group (the per-place resolution bound). NOT searchable (the config non-joiner stance — configs are axis-addressed, not name-found); NO UNIQ marker.
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 (CG-…). |
type | String String! | The kind of record — always CommissionConfig here. |
caption | String String! | The record’s display name — what people see it called. |
status | String String! | The FSM state: active | inactive | doomed. |
parentId | ID ID! | The parent org group; for a CommissionConfig parentId === rootId. |
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. |
appliesToAllSalesInScope | Boolean | The manager-on-all flag: every active holder earns on every in-scope line, additively. |
agentRoleId | ID | Agent axis (Role arm — roles are per-organization: matches agents holding it at the SALE’s org). SINGULAR with agentUserId; absent both = all agents. |
agentUserId | ID | Agent axis (User arm — the most specific agent level). SINGULAR with agentRoleId. |
divisionId | ID | Merchandise axis (Division arm). SINGULAR with categoryId/styleId; absent all three = all merchandise. |
categoryId | ID | Merchandise axis (Category arm — SUBTREE semantics; deeper beats shallower). |
styleId | ID | Merchandise axis (Style arm — the per-style override; outranks ANY category depth). |
organizationId | ID | Location axis (Organization arm) — THE org scoping. SINGULAR with logicalFacilityId. |
logicalFacilityId | ID | Location axis (LogicalFacility arm — the most specific location level). |
channel | OrderChannel | Channel axis — the LIVE selling channels; absent = both. |
rate | CommissionRate | The earning formula (SPARSE — the most-specific SET cell wins the parameter; unresolved anywhere = NO entry, commission is config-opt-in). |
enabled | Boolean | The per-cell master switch (SPARSE) — false at the winning cell suppresses the entry. |