Docs
Dashboard

CartDiscountCreateInput

Input

Represents the input for creating a new cart discount.

#

Fields


absoluteValue
CartDiscountAbsoluteValueInput

The absolute value to use for this cart discount create input.

discountCodes
[ID!]

The discount codes to use for this cart discount create input.

displayName
String

The display name to use for this cart discount create input.

lineItemTarget
LineItemTargetInput

The line item target to use for this cart discount create input.

name
String!

The name to use for this cart discount create input.

predicate
String!

The predicate to use for this cart discount create input.

Thor predicates are boolean expressions. Cart discounts and shipping rules evaluate against cart context; product discounts evaluate against price and product context. Cart predicate language and product predicate language.
priority
Int!

The priority to use for this cart discount create input.

relativeValue
CartDiscountRelativeValueInput

The relative value to use for this cart discount create input.

requiresDiscountCode
Boolean

The requires discount code to use for this cart discount create input.

targetType
CartDiscountTargetType!

The target type to use for this cart discount create input.

Possible enum values
  • LINE_ITEM

    The discount will target one or more individual line items.

  • SHIPPING

    Targets the shipping price of the cart.

  • TOTAL

    Targets the total price of the cart.

validFrom
DateTime

The valid from to use for this cart discount create input.

validUntil
DateTime

The valid until to use for this cart discount create input.