Class: Google::Apis::CssV1::CssProductInput

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/css_v1/classes.rb,
lib/google/apis/css_v1/representations.rb,
lib/google/apis/css_v1/representations.rb

Overview

This resource represents input data you submit for a CSS Product, not the processed CSS Product that you see in CSS Center, in Shopping Ads, or across Google surfaces.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ CssProductInput

Returns a new instance of CssProductInput.



639
640
641
# File 'lib/google/apis/css_v1/classes.rb', line 639

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#attributesGoogle::Apis::CssV1::Attributes

Attributes for CSS Product. Corresponds to the JSON property attributes



581
582
583
# File 'lib/google/apis/css_v1/classes.rb', line 581

def attributes
  @attributes
end

#content_languageString

Required. The two-letter ISO 639-1 language code for the CSS Product. Corresponds to the JSON property contentLanguage

Returns:

  • (String)


587
588
589
# File 'lib/google/apis/css_v1/classes.rb', line 587

def content_language
  @content_language
end

#custom_attributesArray<Google::Apis::CssV1::CustomAttribute>

A list of custom (CSS-provided) attributes. It can also be used for submitting any attribute of the feed specification in its generic form (for example: " name": "size type", "value": "regular"). This is useful for submitting attributes not explicitly exposed by the API, such as additional attributes used for Buy on Google. Corresponds to the JSON property customAttributes



596
597
598
# File 'lib/google/apis/css_v1/classes.rb', line 596

def custom_attributes
  @custom_attributes
end

#feed_labelString

Required. The feed label for the CSS Product. Feed Label is synonymous to " target country" and hence should always be a valid region code. For example: ' DE' for Germany, 'FR' for France. Corresponds to the JSON property feedLabel

Returns:

  • (String)


604
605
606
# File 'lib/google/apis/css_v1/classes.rb', line 604

def feed_label
  @feed_label
end

#final_nameString

Output only. The name of the processed CSS Product. Format: accounts/account /cssProducts/css_product`" Corresponds to the JSON propertyfinalName`

Returns:

  • (String)


610
611
612
# File 'lib/google/apis/css_v1/classes.rb', line 610

def final_name
  @final_name
end

#freshness_timeString

Represents the existing version (freshness) of the CSS Product, which can be used to preserve the right order when multiple updates are done at the same time. This field must not be set to the future time. If set, the update is prevented if a newer version of the item already exists in our system (that is the last update time of the existing CSS products is later than the freshness time set in the update). If the update happens, the last update time is then set to this freshness time. If not set, the update will not be prevented and the last update time will default to when this request was received by the CSS API. If the operation is prevented, the aborted exception will be thrown. Corresponds to the JSON property freshnessTime

Returns:

  • (String)


623
624
625
# File 'lib/google/apis/css_v1/classes.rb', line 623

def freshness_time
  @freshness_time
end

#nameString

The name of the CSS Product input. Format: accounts/account/ cssProductInputs/css_product_input` Corresponds to the JSON propertyname`

Returns:

  • (String)


629
630
631
# File 'lib/google/apis/css_v1/classes.rb', line 629

def name
  @name
end

#raw_provided_idString

Required. Your unique identifier for the CSS Product. This is the same for the CSS Product input and processed CSS Product. We only allow ids with alphanumerics, underscores and dashes. See the products feed specification for details. Corresponds to the JSON property rawProvidedId

Returns:

  • (String)


637
638
639
# File 'lib/google/apis/css_v1/classes.rb', line 637

def raw_provided_id
  @raw_provided_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



644
645
646
647
648
649
650
651
652
653
# File 'lib/google/apis/css_v1/classes.rb', line 644

def update!(**args)
  @attributes = args[:attributes] if args.key?(:attributes)
  @content_language = args[:content_language] if args.key?(:content_language)
  @custom_attributes = args[:custom_attributes] if args.key?(:custom_attributes)
  @feed_label = args[:feed_label] if args.key?(:feed_label)
  @final_name = args[:final_name] if args.key?(:final_name)
  @freshness_time = args[:freshness_time] if args.key?(:freshness_time)
  @name = args[:name] if args.key?(:name)
  @raw_provided_id = args[:raw_provided_id] if args.key?(:raw_provided_id)
end