Skip to main content

Update Account Settings

PUT 

/api/admin/portal/accounts/:customer/settings

Update an account's payment term, minimum order value, discount, backorder policy, availability display, approval policy and catalog. Only supplied keys are changed.

Not yet available to API tokens

This endpoint currently requires session authentication; Personal Access Token scope support is in progress.

payment_term_id must reference an existing payment term; it is what drives invoice due dates. Send null to fall back to the account default.

credit_limit and credit_hold are NOT accepted here — they belong to the customer record and are set on the customer, so that one credit limit covers everything the customer owes. Sending them has no effect.

allow_backorder is a tri-state: null inherits the portal-wide default (see Update Portal Settings), true always allows backorders for this account, false never does. An individual product that sets its own backorder rule overrides both.

order_discount_tiers_json is the account's order-value discount ladder — [{"min_subtotal": 1000, "percent": 3}, {"min_subtotal": 5000, "percent": 5}] reads as "3% over 1,000, 5% over 5,000". At most 10 tiers; each threshold must be distinct and each percentage must exceed the one below it, or the write is rejected with 422. Send null to remove the ladder.

It is separate from discount_percent, which is a flat percentage off the tier/list price applied per line while pricing. The two compound: lines are priced with the flat discount, then the ladder applies to the resulting subtotal as an order-level discount on the created order.

min_first_order_value (number >= 0, nullable): the account's opening-order minimum, which applies while the account has never placed an order (no non-cancelled sales order), in place of min_order_value when higher. Null inherits the tenant default from the portal settings.

portal_catalog_ids (array of catalog ids, nullable): REPLACES the account's catalog set — it sees their union; [] or null = none, so it follows the Default catalog. Catalogs that stay keep their per-account override. The legacy single portal_catalog_id is still accepted as a one-item list (null = none); sending both is a 422.

portal_catalog_discount_overrides (array, optional): [{"portal_catalog_id": 4, "order_discount_tiers_json": [...]}] — this account's own ladder for one of ITS catalogs. A ladder replaces the catalog's ladder for this account, [] switches the catalog's discount off for this account (its lines fall back to the account-level ladder), null goes back to the catalog's. Ladder rules as above. Each catalog must be assigned to the account after portal_catalog_ids is applied, else 422 and nothing in the request is written.

Per-catalog order-value discounts. A catalog's ladder counts ONLY the cart lines attributed to that catalog and its percentage comes off those lines only; net-priced products (portal_exclude_from_order_discount) count toward the threshold but are not discounted. Each cart line is attributed to ONE of the account's catalogs: a catalog that names the product in an include_product rule beats one that reaches it by brand/category (or includes everything), then the lowest catalog id wins. The account-level ladder (order_discount_tiers_json) still measures the WHOLE cart, but only discounts lines no catalog ladder governs — a line never takes two order-value discounts.

product_pricing_tier_id (nullable, must exist; null = the tenant's default tier) sets the account's pricing tier — the dealer hub edits it here. Every key is optional and only supplied keys are written; the catalog set (portal_catalog_ids + portal_catalog_discount_overrides) is replaced only when sent.

Request​

Responses​

OK

Response Headers
    Content-Type