Class: Google::Apis::MerchantapiLfpV1beta::LfpInventory
- Inherits:
-
Object
- Object
- Google::Apis::MerchantapiLfpV1beta::LfpInventory
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/merchantapi_lfp_v1beta/classes.rb,
lib/google/apis/merchantapi_lfp_v1beta/representations.rb,
lib/google/apis/merchantapi_lfp_v1beta/representations.rb
Overview
Local Inventory for the merchant.
Instance Attribute Summary collapse
-
#availability ⇒ String
Required.
-
#collection_time ⇒ String
Optional.
-
#content_language ⇒ String
Required.
-
#feed_label ⇒ String
Optional.
-
#gtin ⇒ String
Optional.
-
#name ⇒ String
Output only.
-
#offer_id ⇒ String
Required.
-
#pickup_method ⇒ String
Optional.
-
#pickup_sla ⇒ String
Optional.
-
#price ⇒ Google::Apis::MerchantapiLfpV1beta::Price
The price represented as a number and currency.
-
#quantity ⇒ Fixnum
Optional.
-
#region_code ⇒ String
Required.
-
#store_code ⇒ String
Required.
-
#target_account ⇒ Fixnum
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ LfpInventory
constructor
A new instance of LfpInventory.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ LfpInventory
Returns a new instance of LfpInventory.
133 134 135 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 133 def initialize(**args) update!(**args) end |
Instance Attribute Details
#availability ⇒ String
Required. Availability of the product at this store. For accepted attribute
values, see the local product inventory data specification
Corresponds to the JSON property availability
50 51 52 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 50 def availability @availability end |
#collection_time ⇒ String
Optional. The time when the inventory is collected. If not set, it will be set
to the time when the inventory is submitted.
Corresponds to the JSON property collectionTime
56 57 58 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 56 def collection_time @collection_time end |
#content_language ⇒ String
Required. The two-letter ISO 639-1 language code for the item.
Corresponds to the JSON property contentLanguage
61 62 63 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 61 def content_language @content_language end |
#feed_label ⇒ String
Optional. The feed label for the product. If this is not set, it will
default to regionCode
.
Corresponds to the JSON property feedLabel
68 69 70 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 68 def feed_label @feed_label end |
#gtin ⇒ String
Optional. The Global Trade Item Number of the product.
Corresponds to the JSON property gtin
73 74 75 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 73 def gtin @gtin end |
#name ⇒ String
Output only. Identifier. The name for the LfpInventory
resource. Format:
accounts/
account/lfpInventories/
target_merchant~
store_code~
offer`
Corresponds to the JSON property
name`
79 80 81 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 79 def name @name end |
#offer_id ⇒ String
Required. Immutable. A unique identifier for the product. If both inventories
and sales are submitted for a merchant, this id should match for the same
product. Note: if the merchant sells the same product new and used, they
should have different IDs.
Corresponds to the JSON property offerId
87 88 89 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 87 def offer_id @offer_id end |
#pickup_method ⇒ String
Optional. Supported pickup method for this offer. Unless the value is "not
supported", this field must be submitted together with pickupSla
. For
accepted attribute values, see the local product inventory data specification.
Corresponds to the JSON property pickupMethod
95 96 97 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 95 def pickup_method @pickup_method end |
#pickup_sla ⇒ String
Optional. Expected date that an order will be ready for pickup relative to the
order date. Must be submitted together with pickupMethod
. For accepted
attribute values, see the local product inventory data specification.
Corresponds to the JSON property pickupSla
103 104 105 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 103 def pickup_sla @pickup_sla end |
#price ⇒ Google::Apis::MerchantapiLfpV1beta::Price
The price represented as a number and currency.
Corresponds to the JSON property price
108 109 110 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 108 def price @price end |
#quantity ⇒ Fixnum
Optional. Quantity of the product available at this store. Must be greater
than or equal to zero.
Corresponds to the JSON property quantity
114 115 116 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 114 def quantity @quantity end |
#region_code ⇒ String
Required. The CLDR territory code for the country where the product is sold.
Corresponds to the JSON property regionCode
120 121 122 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 120 def region_code @region_code end |
#store_code ⇒ String
Required. The identifier of the merchant's store. Either the store code
inserted through InsertLfpStore
or the store code in the Business Profile.
Corresponds to the JSON property storeCode
126 127 128 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 126 def store_code @store_code end |
#target_account ⇒ Fixnum
Required. The Merchant Center ID of the merchant to submit the inventory for.
Corresponds to the JSON property targetAccount
131 132 133 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 131 def target_account @target_account end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 |
# File 'lib/google/apis/merchantapi_lfp_v1beta/classes.rb', line 138 def update!(**args) @availability = args[:availability] if args.key?(:availability) @collection_time = args[:collection_time] if args.key?(:collection_time) @content_language = args[:content_language] if args.key?(:content_language) @feed_label = args[:feed_label] if args.key?(:feed_label) @gtin = args[:gtin] if args.key?(:gtin) @name = args[:name] if args.key?(:name) @offer_id = args[:offer_id] if args.key?(:offer_id) @pickup_method = args[:pickup_method] if args.key?(:pickup_method) @pickup_sla = args[:pickup_sla] if args.key?(:pickup_sla) @price = args[:price] if args.key?(:price) @quantity = args[:quantity] if args.key?(:quantity) @region_code = args[:region_code] if args.key?(:region_code) @store_code = args[:store_code] if args.key?(:store_code) @target_account = args[:target_account] if args.key?(:target_account) end |