Enable or disable a promotion
Use this endpoint to change promotion status by enabling or disabling a promotion. Note that you can’t change the status of a promotion that’s currently ACTIVE. You can enable the promotions that are currently disabled and disable the promotions that haven’t expired yet.
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Headers
A header used by fabric to identify the tenant making the request. You must include tenant id in the authentication header for an API request to access any of fabric’s endpoints. You can retrieve the tenant id , which is also called account id, from Copilot. This header is required.
24
x-fabric-channel-id identifies the sales channel where the API request is being made; primarily for multichannel use cases. The channel ids are 12 corresponding to US and 13 corresponding to Canada. The default channel id is 12. This field is required.
A unique identifier obtained from Copilot for the System app in the fabric ecosystem, essential for OpenID Connect authentication flows.
A unique request ID.
Path Parameters
Promotion ID to toggle the promotion
Body
Toggle data request
True: promotion will be enabled<br>False: promotion be disabled
Response
Toggled promotion detail
A 24-character system-generated promotion ID.
The name of the promotion.
Promotion status
ACTIVE
, SCHEDULED
, DISABLED
, EXPIRED
The start time of the promotion, in UTC format.
The end time of the promotion, in UTC format.
Promotion types. The options are:<br>Product: Also referred to as SKU promotion. Promotion or discount is applied on SKUs based on the value mentioned in the discount
object of the request body.<br>CART: Also referred to as cart promotion. Promotion or discount is applied on the minimum order amount of the cart based on the ORDER_VALUE
mentioned in the condition
object of the request body.<br>QUANTITY: Quantity promotion provides discounts on items based on the quantity requirement set in the promotion.<br>SHIPPING: Shipping promotion provides discounts on the shipping cost.<br>BUYGET: BuyGet promotion specifies the Buy conditions and corresponding Get discounts.<br>SPEND_GET: SpendGet promotion specifies the total order value required to qualify for discounts and the discounts applicable based on the order value.
PRODUCT
, CART
, QUANTITY
, SHIPPING
, BUYGET
, SPEND_GET
Record's creation time
Record's last updated time
Promotion execution order. Promotion types are assigned a default execution order. First, level 1 promotions will be evaluated. The result of level 1 will be used as a base price for level 2. Similarly, the result of level 2 will be used as a base price for level 3.
0 < x < 5
Defines the rules for how a promotion can be combined with other promotions. This field determines whether a specific promotion can be applied in conjunction with other active promotions during a transaction or if it must be used exclusively. If configured, stackingType
will have precedence over the isStackable
and isAlwaysApplied
Possible values: - STACKABLE
: This promotion can be combined with other stackable promotions, allowing multiple
discounts to be applied together. The order in which stackable promotions are applied
is determined by the level
field, with promotions having a higher priority (lower numeric value)
being applied before those with a lower priority.
EXCLUSIVE
: This promotion can't be combined with any other promotions. Thelevel
field is used to determine which exclusive promotion will be evaluated and applied first. Once an exclusive promotion is applied, no other promotions can be used in the same transaction.TYPE_EXCLUSIVE
: This promotion can't be combined with other promotions of the same type. Thelevel
field is used to determine which promotion within the same type will be evaluated and applied first.UNIVERSAL
: This promotion can be combined with any other promotions without restrictions. Universal promotions will be evaluated last.
STACKABLE
, EXCLUSIVE
, TYPE_EXCLUSIVE
, UNIVERSAL
true: Promotion can be applied on top of other promotions<br>false: Promotion can't be applied with any other promotions
A flag indicating whether the promotion is always applied regardless of any exclusive promotions on the same item. Set to true
if the promotion is always applied and set to false
if the promotion isn't applied on the item by default.
A placeholder for additional attributes related to promotions, in name-values pairs.
Message description for the promotion
Was this page helpful?