DiscountRule
A discount rule defines how a Discount is calculated when applied to a Cart.
Properties
id
stringRequiredThe discount rule's ID
created_at
DateRequiredThe date with timezone at which the resource was created.
updated_at
DateRequiredThe date with timezone at which the resource was updated.
deleted_at
null | DateRequiredThe date with timezone at which the resource was deleted.
description
stringRequiredA short description of the discount
The type of the Discount, can be fixed
for discounts that reduce the price by a fixed amount, percentage
for percentage reductions or free\_shipping
for shipping vouchers.
fixed
for discounts that reduce the price by a fixed amount, percentage
for percentage reductions or free\_shipping
for shipping vouchers.value
numberRequiredThe value that the discount represents; this will depend on the type of the discount
The scope that the discount should apply to.
The details of the discount conditions associated with the rule. They can be used to limit when the discount can be used.
metadata
Record<string, unknown>RequiredAn optional key-value map with additional details
Was this section helpful?