Class: Google::Apis::ContentV2::Inventory
- Inherits:
-
Object
- Object
- Google::Apis::ContentV2::Inventory
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/content_v2/classes.rb,
lib/google/apis/content_v2/representations.rb,
lib/google/apis/content_v2/representations.rb
Instance Attribute Summary collapse
-
#availability ⇒ String
The availability of the product.
-
#custom_label0 ⇒ String
Custom label 0 for custom grouping of items in a Shopping campaign.
-
#custom_label1 ⇒ String
Custom label 1 for custom grouping of items in a Shopping campaign.
-
#custom_label2 ⇒ String
Custom label 2 for custom grouping of items in a Shopping campaign.
-
#custom_label3 ⇒ String
Custom label 3 for custom grouping of items in a Shopping campaign.
-
#custom_label4 ⇒ String
Custom label 3 for custom grouping of items in a Shopping campaign.
-
#installment ⇒ Google::Apis::ContentV2::Installment
Number and amount of installments to pay for an item.
-
#instore_product_location ⇒ String
The instore product location.
-
#kind ⇒ String
Identifies what kind of resource this is.
-
#loyalty_points ⇒ Google::Apis::ContentV2::LoyaltyPoints
Loyalty points that users receive after purchasing the item.
-
#pickup ⇒ Google::Apis::ContentV2::InventoryPickup
Store pickup information.
-
#price ⇒ Google::Apis::ContentV2::Price
The price of the product.
-
#quantity ⇒ Fixnum
The quantity of the product.
-
#sale_price ⇒ Google::Apis::ContentV2::Price
The sale price of the product.
-
#sale_price_effective_date ⇒ String
A date range represented by a pair of ISO 8601 dates separated by a space, comma, or slash.
-
#sell_on_google_quantity ⇒ Fixnum
The quantity of the product that is available for selling on Google.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Inventory
constructor
A new instance of Inventory.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Inventory
Returns a new instance of Inventory.
3007 3008 3009 |
# File 'lib/google/apis/content_v2/classes.rb', line 3007 def initialize(**args) update!(**args) end |
Instance Attribute Details
#availability ⇒ String
The availability of the product. Acceptable values are: - "in stock" - "out
of stock" - "preorder"
Corresponds to the JSON property availability
2917 2918 2919 |
# File 'lib/google/apis/content_v2/classes.rb', line 2917 def availability @availability end |
#custom_label0 ⇒ String
Custom label 0 for custom grouping of items in a Shopping campaign. Only
supported for online products.
Corresponds to the JSON property customLabel0
2923 2924 2925 |
# File 'lib/google/apis/content_v2/classes.rb', line 2923 def custom_label0 @custom_label0 end |
#custom_label1 ⇒ String
Custom label 1 for custom grouping of items in a Shopping campaign. Only
supported for online products.
Corresponds to the JSON property customLabel1
2929 2930 2931 |
# File 'lib/google/apis/content_v2/classes.rb', line 2929 def custom_label1 @custom_label1 end |
#custom_label2 ⇒ String
Custom label 2 for custom grouping of items in a Shopping campaign. Only
supported for online products.
Corresponds to the JSON property customLabel2
2935 2936 2937 |
# File 'lib/google/apis/content_v2/classes.rb', line 2935 def custom_label2 @custom_label2 end |
#custom_label3 ⇒ String
Custom label 3 for custom grouping of items in a Shopping campaign. Only
supported for online products.
Corresponds to the JSON property customLabel3
2941 2942 2943 |
# File 'lib/google/apis/content_v2/classes.rb', line 2941 def custom_label3 @custom_label3 end |
#custom_label4 ⇒ String
Custom label 3 for custom grouping of items in a Shopping campaign. Only
supported for online products.
Corresponds to the JSON property customLabel4
2947 2948 2949 |
# File 'lib/google/apis/content_v2/classes.rb', line 2947 def custom_label4 @custom_label4 end |
#installment ⇒ Google::Apis::ContentV2::Installment
Number and amount of installments to pay for an item. Brazil only.
Corresponds to the JSON property installment
2952 2953 2954 |
# File 'lib/google/apis/content_v2/classes.rb', line 2952 def installment @installment end |
#instore_product_location ⇒ String
The instore product location. Supported only for local products.
Corresponds to the JSON property instoreProductLocation
2957 2958 2959 |
# File 'lib/google/apis/content_v2/classes.rb', line 2957 def instore_product_location @instore_product_location end |
#kind ⇒ String
Identifies what kind of resource this is. Value: the fixed string "content#
inventory"
Corresponds to the JSON property kind
2963 2964 2965 |
# File 'lib/google/apis/content_v2/classes.rb', line 2963 def kind @kind end |
#loyalty_points ⇒ Google::Apis::ContentV2::LoyaltyPoints
Loyalty points that users receive after purchasing the item. Japan only.
Corresponds to the JSON property loyaltyPoints
2968 2969 2970 |
# File 'lib/google/apis/content_v2/classes.rb', line 2968 def loyalty_points @loyalty_points end |
#pickup ⇒ Google::Apis::ContentV2::InventoryPickup
Store pickup information. Only supported for local inventory. Not setting
pickup means "don't update" while setting it to the empty value (```in JSON)
means "delete". Otherwise,pickupMethodandpickupSlamust be set
together, unlesspickupMethodis "not supported".
Corresponds to the JSON propertypickup`
2976 2977 2978 |
# File 'lib/google/apis/content_v2/classes.rb', line 2976 def pickup @pickup end |
#price ⇒ Google::Apis::ContentV2::Price
The price of the product.
Corresponds to the JSON property price
2981 2982 2983 |
# File 'lib/google/apis/content_v2/classes.rb', line 2981 def price @price end |
#quantity ⇒ Fixnum
The quantity of the product. Must be equal to or greater than zero. Supported
only for local products.
Corresponds to the JSON property quantity
2987 2988 2989 |
# File 'lib/google/apis/content_v2/classes.rb', line 2987 def quantity @quantity end |
#sale_price ⇒ Google::Apis::ContentV2::Price
The sale price of the product. Mandatory if sale_price_effective_date is
defined.
Corresponds to the JSON property salePrice
2993 2994 2995 |
# File 'lib/google/apis/content_v2/classes.rb', line 2993 def sale_price @sale_price end |
#sale_price_effective_date ⇒ String
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
2999 3000 3001 |
# File 'lib/google/apis/content_v2/classes.rb', line 2999 def sale_price_effective_date @sale_price_effective_date end |
#sell_on_google_quantity ⇒ Fixnum
The quantity of the product that is available for selling on Google. Supported
only for online products.
Corresponds to the JSON property sellOnGoogleQuantity
3005 3006 3007 |
# File 'lib/google/apis/content_v2/classes.rb', line 3005 def sell_on_google_quantity @sell_on_google_quantity end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 |
# File 'lib/google/apis/content_v2/classes.rb', line 3012 def update!(**args) @availability = args[:availability] if args.key?(:availability) @custom_label0 = args[:custom_label0] if args.key?(:custom_label0) @custom_label1 = args[:custom_label1] if args.key?(:custom_label1) @custom_label2 = args[:custom_label2] if args.key?(:custom_label2) @custom_label3 = args[:custom_label3] if args.key?(:custom_label3) @custom_label4 = args[:custom_label4] if args.key?(:custom_label4) @installment = args[:installment] if args.key?(:installment) @instore_product_location = args[:instore_product_location] if args.key?(:instore_product_location) @kind = args[:kind] if args.key?(:kind) @loyalty_points = args[:loyalty_points] if args.key?(:loyalty_points) @pickup = args[:pickup] if args.key?(:pickup) @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 |