Class: Google::Apis::MerchantapiReviewsV1beta::MerchantService
- Inherits:
-
Core::BaseService
- Object
- Core::BaseService
- Google::Apis::MerchantapiReviewsV1beta::MerchantService
- Defined in:
- lib/google/apis/merchantapi_reviews_v1beta/service.rb
Overview
Merchant API
Programmatically manage your Merchant Center Accounts.
Constant Summary collapse
- DEFAULT_ENDPOINT_TEMPLATE =
"https://merchantapi.$UNIVERSE_DOMAIN$/"
Instance Attribute Summary collapse
-
#key ⇒ String
API key.
-
#quota_user ⇒ String
Available to use for quota purposes for server-side applications.
Instance Method Summary collapse
-
#delete_account_merchant_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::Empty
Deletes merchant review.
-
#delete_account_product_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::Empty
Deletes a product review.
-
#get_account_merchant_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::MerchantReview
Gets a merchant review.
-
#get_account_product_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ProductReview
Gets a product review.
-
#initialize ⇒ MerchantService
constructor
A new instance of MerchantService.
-
#insert_account_merchant_review(parent, merchant_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::MerchantReview
Inserts a review for your Merchant Center account.
-
#insert_account_product_review(parent, product_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ProductReview
Inserts a product review.
-
#list_account_merchant_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ListMerchantReviewsResponse
Lists merchant reviews.
-
#list_account_product_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ListProductReviewsResponse
Lists product reviews.
Constructor Details
#initialize ⇒ MerchantService
Returns a new instance of MerchantService.
47 48 49 50 51 52 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 47 def initialize super(DEFAULT_ENDPOINT_TEMPLATE, '', client_name: 'google-apis-merchantapi_reviews_v1beta', client_version: Google::Apis::MerchantapiReviewsV1beta::GEM_VERSION) @batch_path = 'batch' end |
Instance Attribute Details
#key ⇒ String
Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
40 41 42 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 40 def key @key end |
#quota_user ⇒ String
Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
45 46 47 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 45 def quota_user @quota_user end |
Instance Method Details
#delete_account_merchant_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::Empty
Deletes merchant review.
75 76 77 78 79 80 81 82 83 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 75 def delete_account_merchant_review(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'reviews/v1beta/{+name}', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::Empty::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_account_product_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::Empty
Deletes a product review.
218 219 220 221 222 223 224 225 226 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 218 def delete_account_product_review(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'reviews/v1beta/{+name}', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::Empty::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_account_merchant_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::MerchantReview
Gets a merchant review.
106 107 108 109 110 111 112 113 114 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 106 def get_account_merchant_review(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'reviews/v1beta/{+name}', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::MerchantReview::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::MerchantReview command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_account_product_review(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ProductReview
Gets a product review.
249 250 251 252 253 254 255 256 257 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 249 def get_account_product_review(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'reviews/v1beta/{+name}', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::ProductReview::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::ProductReview command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#insert_account_merchant_review(parent, merchant_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::MerchantReview
Inserts a review for your Merchant Center account. If the review already exists, then the review is replaced with the new instance.
143 144 145 146 147 148 149 150 151 152 153 154 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 143 def insert_account_merchant_review(parent, merchant_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'reviews/v1beta/{+parent}/merchantReviews:insert', ) command.request_representation = Google::Apis::MerchantapiReviewsV1beta::MerchantReview::Representation command.request_object = merchant_review_object command.response_representation = Google::Apis::MerchantapiReviewsV1beta::MerchantReview::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::MerchantReview command.params['parent'] = parent unless parent.nil? command.query['dataSource'] = data_source unless data_source.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#insert_account_product_review(parent, product_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ProductReview
Inserts a product review.
283 284 285 286 287 288 289 290 291 292 293 294 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 283 def insert_account_product_review(parent, product_review_object = nil, data_source: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'reviews/v1beta/{+parent}/productReviews:insert', ) command.request_representation = Google::Apis::MerchantapiReviewsV1beta::ProductReview::Representation command.request_object = product_review_object command.response_representation = Google::Apis::MerchantapiReviewsV1beta::ProductReview::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::ProductReview command.params['parent'] = parent unless parent.nil? command.query['dataSource'] = data_source unless data_source.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_account_merchant_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ListMerchantReviewsResponse
Lists merchant reviews.
185 186 187 188 189 190 191 192 193 194 195 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 185 def list_account_merchant_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'reviews/v1beta/{+parent}/merchantReviews', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::ListMerchantReviewsResponse::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::ListMerchantReviewsResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_account_product_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::MerchantapiReviewsV1beta::ListProductReviewsResponse
Lists product reviews.
324 325 326 327 328 329 330 331 332 333 334 |
# File 'lib/google/apis/merchantapi_reviews_v1beta/service.rb', line 324 def list_account_product_reviews(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'reviews/v1beta/{+parent}/productReviews', ) command.response_representation = Google::Apis::MerchantapiReviewsV1beta::ListProductReviewsResponse::Representation command.response_class = Google::Apis::MerchantapiReviewsV1beta::ListProductReviewsResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |