Save what a modifier takes on one item

Changed on

Sets what the modifier takes on this item in place of its own effect, replacing what it took here: adds or removes a product of the organization by a quantity above zero, an integer string of thousandths of the product's base unit per unit of the modifier, replaces replacedStockItemId with a product and a null quantity, or none with neither, so it takes nothing here. stock null clears it, so the modifier takes its own effect on the item again. New order lines take it; lines already held keep what they recorded. NOT_FOUND for an item that does not exist, as modifierNotFound for a modifier the item does not offer, live, in a set or loose, and as stockNotFound for a product the organization does not hold; BAD_REQUEST as replacementUnitMismatch for a replaced product counted in another base unit. Refused with FORBIDDEN as inventoryDisabled while the inventory flag is off. Refused with FORBIDDEN as paywallLocked when the caller is an Owner or Manager of a business the merchant Paywall locks: one with no verified subscription that has taken 5 orders while the Paywall's rollout reaches it, an order counting from its first saved line, whether or not it is paid or completed, until it is archived or cancelled before activation. Nothing is read or written; a verified subscription lifts the lock.

post/api/public/v1/inventoryModifiers/saveItemEffect

Request

  • Base URL
    https://app.fortuneos.ai
  • Auth
    none declared

Request body

object required
catalogItemId, string required
modifierId, string required
stock, object nullable required

Changes

    • info

      added the new optional request property stock/anyOf[subschema #1]/replacedStockItemId

    • info

      added the new replaces enum value to the request property stock/anyOf[subschema #1]/effect

    • info

      endpoint added