class Google::Apis::ContentV2::Inventory

Attributes

availability[RW]

The availability of the product. Corresponds to the JSON property `availability` @return [String]

installment[RW]

Number and amount of installments to pay for an item. Brazil only. Corresponds to the JSON property `installment` @return [Google::Apis::ContentV2::Installment]

kind[RW]

Identifies what kind of resource this is. Value: the fixed string “content# inventory”. Corresponds to the JSON property `kind` @return [String]

loyalty_points[RW]

Loyalty points that users receive after purchasing the item. Japan only. Corresponds to the JSON property `loyaltyPoints` @return [Google::Apis::ContentV2::LoyaltyPoints]

price[RW]

The price of the product. Corresponds to the JSON property `price` @return [Google::Apis::ContentV2::Price]

quantity[RW]

The quantity of the product. Must be equal to or greater than zero. Supported only for local products. Corresponds to the JSON property `quantity` @return [Fixnum]

sale_price[RW]

The sale price of the product. Mandatory if #sale_price_effective_date is defined. Corresponds to the JSON property `salePrice` @return [Google::Apis::ContentV2::Price]

sale_price_effective_date[RW]

A date range represented by a pair of ISO 8601 dates separated by a space, comma, or slash. Both dates might be specified as 'null' if undecided. Corresponds to the JSON property `salePriceEffectiveDate` @return [String]

sell_on_google_quantity[RW]

The quantity of the product that is reserved for sell-on-google ads. Supported only for online products. Corresponds to the JSON property `sellOnGoogleQuantity` @return [Fixnum]

Public Class Methods

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

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File generated/google/apis/content_v2/classes.rb, line 2265
def update!(**args)
  @availability = args[:availability] if args.key?(:availability)
  @installment = args[:installment] if args.key?(:installment)
  @kind = args[:kind] if args.key?(:kind)
  @loyalty_points = args[:loyalty_points] if args.key?(:loyalty_points)
  @price = args[:price] if args.key?(:price)
  @quantity = args[:quantity] if args.key?(:quantity)
  @sale_price = args[:sale_price] if args.key?(:sale_price)
  @sale_price_effective_date = args[:sale_price_effective_date] if args.key?(:sale_price_effective_date)
  @sell_on_google_quantity = args[:sell_on_google_quantity] if args.key?(:sell_on_google_quantity)
end