Class: Google::Apis::MerchantapiReviewsV1beta::MerchantReviewAttributes

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

Overview

Attributes.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ MerchantReviewAttributes

Returns a new instance of MerchantReviewAttributes.



283
284
285
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 283

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

Instance Attribute Details

#collection_methodString

Optional. The method used to collect the review. Corresponds to the JSON property collectionMethod

Returns:

  • (String)


193
194
195
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 193

def collection_method
  @collection_method
end

#contentString

Required. This should be any freeform text provided by the user and should not be truncated. If multiple responses to different questions are provided, all responses should be included, with the minimal context for the responses to make sense. Context should not be provided if questions were left unanswered. Corresponds to the JSON property content

Returns:

  • (String)


201
202
203
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 201

def content
  @content
end

#is_anonymousBoolean Also known as: is_anonymous?

Optional. Set to true if the reviewer should remain anonymous. Corresponds to the JSON property isAnonymous

Returns:

  • (Boolean)


206
207
208
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 206

def is_anonymous
  @is_anonymous
end

#max_ratingFixnum

Optional. The maximum possible number for the rating. The value of the max rating must be greater than the value of the min rating. Corresponds to the JSON property maxRating

Returns:

  • (Fixnum)


213
214
215
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 213

def max_rating
  @max_rating
end

#merchant_display_nameString

Optional. Human-readable display name for the merchant. Corresponds to the JSON property merchantDisplayName

Returns:

  • (String)


218
219
220
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 218

def merchant_display_name
  @merchant_display_name
end

#merchant_idString

Required. Must be unique and stable across all requests. In other words, if a request today and another 90 days ago refer to the same merchant, they must have the same id. Corresponds to the JSON property merchantId

Returns:

  • (String)


225
226
227
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 225

def merchant_id
  @merchant_id
end

Optional. URL to the merchant's main website. Do not use a redirect URL for this value. In other words, the value should point directly to the merchant's site. Corresponds to the JSON property merchantLink

Returns:

  • (String)


232
233
234
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 232

def merchant_link
  @merchant_link
end

Optional. URL to the landing page that hosts the reviews for this merchant. Do not use a redirect URL. Corresponds to the JSON property merchantRatingLink

Returns:

  • (String)


238
239
240
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 238

def merchant_rating_link
  @merchant_rating_link
end

#min_ratingFixnum

Optional. The minimum possible number for the rating. This should be the worst possible rating and should not be a value for no rating. Corresponds to the JSON property minRating

Returns:

  • (Fixnum)


244
245
246
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 244

def min_rating
  @min_rating
end

#ratingFloat

Optional. The reviewer's overall rating of the merchant. Corresponds to the JSON property rating

Returns:

  • (Float)


249
250
251
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 249

def rating
  @rating
end

#review_countryString

Optional. The country where the reviewer made the order defined by ISO 3166-1 Alpha-2 Country Code. Corresponds to the JSON property reviewCountry

Returns:

  • (String)


255
256
257
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 255

def review_country
  @review_country
end

#review_languageString

Required. The language of the review defined by BCP-47 language code. Corresponds to the JSON property reviewLanguage

Returns:

  • (String)


260
261
262
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 260

def review_language
  @review_language
end

#review_timeString

Required. The timestamp indicating when the review was written. Corresponds to the JSON property reviewTime

Returns:

  • (String)


265
266
267
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 265

def review_time
  @review_time
end

#reviewer_idString

Optional. A permanent, unique identifier for the author of the review in the publisher's system. Corresponds to the JSON property reviewerId

Returns:

  • (String)


271
272
273
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 271

def reviewer_id
  @reviewer_id
end

#reviewer_usernameString

Optional. Display name of the review author. Corresponds to the JSON property reviewerUsername

Returns:

  • (String)


276
277
278
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 276

def reviewer_username
  @reviewer_username
end

#titleString

Optional. The title of the review. Corresponds to the JSON property title

Returns:

  • (String)


281
282
283
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 281

def title
  @title
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
# File 'lib/google/apis/merchantapi_reviews_v1beta/classes.rb', line 288

def update!(**args)
  @collection_method = args[:collection_method] if args.key?(:collection_method)
  @content = args[:content] if args.key?(:content)
  @is_anonymous = args[:is_anonymous] if args.key?(:is_anonymous)
  @max_rating = args[:max_rating] if args.key?(:max_rating)
  @merchant_display_name = args[:merchant_display_name] if args.key?(:merchant_display_name)
  @merchant_id = args[:merchant_id] if args.key?(:merchant_id)
  @merchant_link = args[:merchant_link] if args.key?(:merchant_link)
  @merchant_rating_link = args[:merchant_rating_link] if args.key?(:merchant_rating_link)
  @min_rating = args[:min_rating] if args.key?(:min_rating)
  @rating = args[:rating] if args.key?(:rating)
  @review_country = args[:review_country] if args.key?(:review_country)
  @review_language = args[:review_language] if args.key?(:review_language)
  @review_time = args[:review_time] if args.key?(:review_time)
  @reviewer_id = args[:reviewer_id] if args.key?(:reviewer_id)
  @reviewer_username = args[:reviewer_username] if args.key?(:reviewer_username)
  @title = args[:title] if args.key?(:title)
end