class Google::Apis::ContentV2::OrderLegacyPromotionBenefit

Attributes

discount[RW]

The discount in the order price when the promotion is applied. Corresponds to the JSON property `discount` @return [Google::Apis::ContentV2::Price]

offer_ids[RW]

The OfferId(s) that were purchased in this order and map to this specific benefit of the promotion. Corresponds to the JSON property `offerIds` @return [Array<String>]

sub_type[RW]

Further describes the benefit of the promotion. Note that we will expand on this enumeration as we support new promotion sub-types. Acceptable values are:

  • “`buyMGetMoneyOff`” - “`buyMGetNMoneyOff`” - “`buyMGetNPercentOff`” - “`

buyMGetPercentOff`“ - ”`freeGift`“ - ”`freeGiftWithItemId`“ - ”` freeGiftWithValue`“ - ”`freeOvernightShipping`“ - ”`freeShipping`“ - ”` freeTwoDayShipping`“ - ”`moneyOff`“ - ”`percentageOff`“ - ”`rewardPoints`“ - ”` salePrice`“ Corresponds to the JSON property `subType` @return [String]

tax_impact[RW]

The impact on tax when the promotion is applied. Corresponds to the JSON property `taxImpact` @return [Google::Apis::ContentV2::Price]

type[RW]

Describes whether the promotion applies to products (e.g. 20% off) or to shipping (e.g. Free Shipping). Acceptable values are: - “`product`” - “` shipping`” Corresponds to the JSON property `type` @return [String]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/content_v2/classes.rb, line 4668
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/content_v2/classes.rb, line 4673
def update!(**args)
  @discount = args[:discount] if args.key?(:discount)
  @offer_ids = args[:offer_ids] if args.key?(:offer_ids)
  @sub_type = args[:sub_type] if args.key?(:sub_type)
  @tax_impact = args[:tax_impact] if args.key?(:tax_impact)
  @type = args[:type] if args.key?(:type)
end