AlmondTill/G3N API

NewOrgCustomerInput

input type

Create-input for an OrgCustomer. The tenant (org group) is derived SERVER-SIDE from the principal; organizationId (the parent org) and corporateCustomerId are tenant-scoped server-side and must be active (STRICT); ≤1 live selection per (org × cc) via the pair marker (CONFLICT/IDENTITY_TAKEN names a live holder; a doomed one is taken over). Every terms field is optional (the enablement stays creatable thin); creditLimit/orderMinimum must match the org's defaultCurrency (an org with NO defaultCurrency cannot store OrgCustomer money — CONFLICT/REF_STATE naming the absence, the order-create precedent); customerPriceGroupId gates in-tenant + ACTIVE; priceListId gates in-tenant + ACTIVE + the scope law (a scoped list must name THIS OrgCustomer); billTo/shipTo gate non-doomed + host-membership. ⚠ the AR custody fields (arBalanceMinor/arCurrency) are SYSTEM-maintained and NOT creatable.

Fields

FieldTypeRequiredNotes
captionStringnoOptional: when omitted the per-type default applies — the merchant code when given, else 'Org Customer'; when supplied it must be non-blank.
organizationIdID ID!yesThe parent Organization id — rides the header.
corporateCustomerIdID ID!yesThe group CorporateCustomer this enablement names — immutable after birth.
accountNumberStringnoNo further notes.
paymentTermsStringnoThe canned payment-terms token (net-30 · 2-10-net-30 · cod · prepaid).
creditLimitMoneyEntryInputnoMust match the org's defaultCurrency (the sell-side currency law).
orderMinimumMoneyEntryInputnoSame currency law.
customerPriceGroupIdIDnoNo further notes.
priceListIdIDnoThe contract/book carrier.
billToContactIdIDnoNo further notes.
shipToContactIdIDnoNo further notes.
codeStringnoNo further notes.

Used by