Discount Rule Object


Manage Discount Rules.

Properties
idstringRead-onlyformat GUID

Discount rule ID.


revisionintegerRead-onlyformat int64

Revision number, which increments by 1 each time the discount rule is updated. To prevent conflicting changes, the current revision must be passed when updating the discount rule.


createdDatestringRead-onlyformat date-time

Date and time the discount rule was created.


updatedDatestringRead-onlyformat date-time

Date and time the discount rule was last updated.


activeboolean

Whether the discount rule is active.

Default: true


namestringminLength 1maxLength 50

Discount rule name.


triggerTrigger

Discount rule trigger. A set of conditions that must be met for the discounts to be applied. Not passing a trigger will cause the discount to always apply.


activeTimeInfoActiveTimeInfo

Time frame in which the discount rule is active.


discountsDiscounts

List of discounts that are applied when one or more triggers are met.

Notes:

  • Currently, only 1 discount can be defined per discount rule.
  • A discount rule can be applied on multiple items per cart.
  • A discount rule can only be applied once per item.

statusstringRead-only

Discount rule status.


usageCountintegerRead-only

Number of times the discount rule was used.

Did this help?