PromotionRule
Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount.
Added in Saleor 3.17type PromotionRule implements Node {
id: ID!
name: String
description: JSON
promotion: Promotion
channels: [Channel!]
rewardValueType: RewardValueTypeEnum
cataloguePredicate: JSON
rewardValue: PositiveDecimal
translation(languageCode: LanguageCodeEnum!): PromotionRuleTranslation
}
Fields
PromotionRule.id
● ID!
non-null scalar
PromotionRule.name
● String
scalar
Name of the promotion rule.
PromotionRule.description
● JSON
scalar
Description of the promotion rule.
PromotionRule.promotion
● Promotion
object
Promotion to which the rule belongs.
PromotionRule.channels
● [Channel!]
list object
List of channels where the rule applies.
PromotionRule.rewardValueType
● RewardValueTypeEnum
enum
The type of reward value of the promotion rule.
PromotionRule.cataloguePredicate
● JSON
scalar
The catalogue predicate that must be met to apply the rule reward.
PromotionRule.rewardValue
● PositiveDecimal
scalar
The reward value of the promotion rule. Defines the discount value applied when the rule conditions are met.
PromotionRule.translation
● PromotionRuleTranslation
object
Returns translated promotion rule fields for the given language code.
PromotionRule.translation.languageCode
●LanguageCodeEnum!
non-null enumA language code to return the translation for promotion rule.
Interfaces
Node
interface
An object with an ID
Member of
Promotion
object ● PromotionRuleCreate
object ● PromotionRuleCreated
object ● PromotionRuleDelete
object ● PromotionRuleDeleted
object ● PromotionRuleTranslate
object ● PromotionRuleUpdate
object ● PromotionRuleUpdated
object