google-shopping-merchant-accounts-v1 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/shopping/merchant/accounts/v1/account_issue_service/client.rb +20 -3
  3. data/lib/google/shopping/merchant/accounts/v1/account_relationships_service/client.rb +20 -3
  4. data/lib/google/shopping/merchant/accounts/v1/account_services_service/client.rb +20 -3
  5. data/lib/google/shopping/merchant/accounts/v1/accounts_pb.rb +4 -1
  6. data/lib/google/shopping/merchant/accounts/v1/accounts_service/client.rb +32 -8
  7. data/lib/google/shopping/merchant/accounts/v1/accounts_service/rest/client.rb +12 -5
  8. data/lib/google/shopping/merchant/accounts/v1/accounts_services_pb.rb +7 -4
  9. data/lib/google/shopping/merchant/accounts/v1/accountservices_pb.rb +2 -1
  10. data/lib/google/shopping/merchant/accounts/v1/autofeed_settings_service/client.rb +20 -3
  11. data/lib/google/shopping/merchant/accounts/v1/automatic_improvements_service/client.rb +20 -3
  12. data/lib/google/shopping/merchant/accounts/v1/business_identity_service/client.rb +20 -3
  13. data/lib/google/shopping/merchant/accounts/v1/business_info_service/client.rb +20 -3
  14. data/lib/google/shopping/merchant/accounts/v1/checkout_settings_service/client.rb +20 -3
  15. data/lib/google/shopping/merchant/accounts/v1/developer_registration_service/client.rb +99 -4
  16. data/lib/google/shopping/merchant/accounts/v1/developer_registration_service/rest/client.rb +80 -1
  17. data/lib/google/shopping/merchant/accounts/v1/developer_registration_service/rest/service_stub.rb +59 -0
  18. data/lib/google/shopping/merchant/accounts/v1/developerregistration_pb.rb +2 -1
  19. data/lib/google/shopping/merchant/accounts/v1/developerregistration_services_pb.rb +2 -0
  20. data/lib/google/shopping/merchant/accounts/v1/email_preferences_service/client.rb +20 -3
  21. data/lib/google/shopping/merchant/accounts/v1/gbp_accounts_service/client.rb +20 -3
  22. data/lib/google/shopping/merchant/accounts/v1/homepage_service/client.rb +20 -3
  23. data/lib/google/shopping/merchant/accounts/v1/lfp_providers_service/client.rb +20 -3
  24. data/lib/google/shopping/merchant/accounts/v1/omnichannel_settings_service/client.rb +20 -3
  25. data/lib/google/shopping/merchant/accounts/v1/online_return_policy_service/client.rb +20 -3
  26. data/lib/google/shopping/merchant/accounts/v1/programs_service/client.rb +20 -3
  27. data/lib/google/shopping/merchant/accounts/v1/regions_service/client.rb +20 -3
  28. data/lib/google/shopping/merchant/accounts/v1/shipping_settings_service/client.rb +20 -3
  29. data/lib/google/shopping/merchant/accounts/v1/terms_of_service_agreement_state_service/client.rb +20 -3
  30. data/lib/google/shopping/merchant/accounts/v1/terms_of_service_service/client.rb +20 -3
  31. data/lib/google/shopping/merchant/accounts/v1/user_pb.rb +2 -1
  32. data/lib/google/shopping/merchant/accounts/v1/user_service/client.rb +114 -3
  33. data/lib/google/shopping/merchant/accounts/v1/user_service/rest/client.rb +87 -0
  34. data/lib/google/shopping/merchant/accounts/v1/user_service/rest/service_stub.rb +62 -0
  35. data/lib/google/shopping/merchant/accounts/v1/user_services_pb.rb +3 -0
  36. data/lib/google/shopping/merchant/accounts/v1/verificationmailsettings_pb.rb +47 -0
  37. data/lib/google/shopping/merchant/accounts/v1/version.rb +1 -1
  38. data/proto_docs/google/shopping/merchant/accounts/v1/accessright.rb +4 -2
  39. data/proto_docs/google/shopping/merchant/accounts/v1/accounts.rb +72 -0
  40. data/proto_docs/google/shopping/merchant/accounts/v1/accountservices.rb +18 -5
  41. data/proto_docs/google/shopping/merchant/accounts/v1/developerregistration.rb +12 -1
  42. data/proto_docs/google/shopping/merchant/accounts/v1/programs.rb +1 -0
  43. data/proto_docs/google/shopping/merchant/accounts/v1/user.rb +14 -2
  44. data/proto_docs/google/shopping/merchant/accounts/v1/verificationmailsettings.rb +53 -0
  45. metadata +3 -1
@@ -221,7 +221,9 @@ module Google
221
221
  # updated to have the new "API notifications" preference. If the developer
222
222
  # email provided is not associated with any user we will just add it as a
223
223
  # contact. The email preference corresponding to that contact will have the
224
- # new "API notifications" preference
224
+ # new "API notifications" preference. Make sure the email used is associated
225
+ # with a Google Account (Google Workspace account or Gmail account)
226
+ # and is not a service account as service accounts can't receive emails.
225
227
  #
226
228
  # @yield [response, operation] Access the result along with the RPC operation
227
229
  # @yieldparam response [::Google::Shopping::Merchant::Accounts::V1::DeveloperRegistration]
@@ -461,6 +463,75 @@ module Google
461
463
  raise ::Google::Cloud::Error.from_error(e)
462
464
  end
463
465
 
466
+ ##
467
+ # Retrieves the merchant account that the calling GCP is registered with.
468
+ #
469
+ # @overload get_account_for_gcp_registration(request, options = nil)
470
+ # Pass arguments to `get_account_for_gcp_registration` via a request object, either of type
471
+ # {::Google::Protobuf::Empty} or an equivalent Hash.
472
+ #
473
+ # @param request [::Google::Protobuf::Empty, ::Hash]
474
+ # A request object representing the call parameters. Required. To specify no
475
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
476
+ # @param options [::Gapic::CallOptions, ::Hash]
477
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
478
+ #
479
+ # @yield [response, operation] Access the result along with the RPC operation
480
+ # @yieldparam response [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
481
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
482
+ #
483
+ # @return [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
484
+ #
485
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
486
+ #
487
+ # @example Basic example
488
+ # require "google/shopping/merchant/accounts/v1"
489
+ #
490
+ # # Create a client object. The client can be reused for multiple calls.
491
+ # client = Google::Shopping::Merchant::Accounts::V1::DeveloperRegistrationService::Client.new
492
+ #
493
+ # # Create a request. To set request fields, pass in keyword arguments.
494
+ # request = Google::Protobuf::Empty.new
495
+ #
496
+ # # Call the get_account_for_gcp_registration method.
497
+ # result = client.get_account_for_gcp_registration request
498
+ #
499
+ # # The returned object is of type Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse.
500
+ # p result
501
+ #
502
+ def get_account_for_gcp_registration request, options = nil
503
+ raise ::ArgumentError, "request must be provided" if request.nil?
504
+
505
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Protobuf::Empty
506
+
507
+ # Converts hash and nil to an options object
508
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
509
+
510
+ # Customize the options with defaults
511
+ metadata = @config.rpcs.get_account_for_gcp_registration.metadata.to_h
512
+
513
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
514
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
515
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
516
+ gapic_version: ::Google::Shopping::Merchant::Accounts::V1::VERSION
517
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
518
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
519
+
520
+ options.apply_defaults timeout: @config.rpcs.get_account_for_gcp_registration.timeout,
521
+ metadata: metadata,
522
+ retry_policy: @config.rpcs.get_account_for_gcp_registration.retry_policy
523
+
524
+ options.apply_defaults timeout: @config.timeout,
525
+ metadata: @config.metadata,
526
+ retry_policy: @config.retry_policy
527
+
528
+ @developer_registration_service_stub.call_rpc :get_account_for_gcp_registration, request, options: options do |response, operation|
529
+ yield response, operation if block_given?
530
+ end
531
+ rescue ::GRPC::BadStatus => e
532
+ raise ::Google::Cloud::Error.from_error(e)
533
+ end
534
+
464
535
  ##
465
536
  # Configuration class for the DeveloperRegistrationService API.
466
537
  #
@@ -496,8 +567,6 @@ module Google
496
567
  # @return [::String,nil]
497
568
  # @!attribute [rw] credentials
498
569
  # Credentials to send with calls. You may provide any of the following types:
499
- # * (`String`) The path to a service account key file in JSON format
500
- # * (`Hash`) A service account key as a Hash
501
570
  # * (`Google::Auth::Credentials`) A googleauth credentials object
502
571
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
503
572
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -506,7 +575,26 @@ module Google
506
575
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
507
576
  # * (`nil`) indicating no credentials
508
577
  #
509
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
578
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
579
+ # is deprecated. Providing an unvalidated credential configuration to
580
+ # Google APIs can compromise the security of your systems and data.
581
+ #
582
+ # @example
583
+ #
584
+ # # The recommended way to provide credentials is to use the `make_creds` method
585
+ # # on the appropriate credentials class for your environment.
586
+ #
587
+ # require "googleauth"
588
+ #
589
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
590
+ # json_key_io: ::File.open("/path/to/keyfile.json")
591
+ # )
592
+ #
593
+ # client = ::Google::Shopping::Merchant::Accounts::V1::DeveloperRegistrationService::Client.new do |config|
594
+ # config.credentials = credentials
595
+ # end
596
+ #
597
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
510
598
  # external source for authentication to Google Cloud, you must validate it before
511
599
  # providing it to a Google API client library. Providing an unvalidated credential
512
600
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -642,6 +730,11 @@ module Google
642
730
  # @return [::Gapic::Config::Method]
643
731
  #
644
732
  attr_reader :unregister_gcp
733
+ ##
734
+ # RPC-specific configuration for `get_account_for_gcp_registration`
735
+ # @return [::Gapic::Config::Method]
736
+ #
737
+ attr_reader :get_account_for_gcp_registration
645
738
 
646
739
  # @private
647
740
  def initialize parent_rpcs = nil
@@ -651,6 +744,8 @@ module Google
651
744
  @get_developer_registration = ::Gapic::Config::Method.new get_developer_registration_config
652
745
  unregister_gcp_config = parent_rpcs.unregister_gcp if parent_rpcs.respond_to? :unregister_gcp
653
746
  @unregister_gcp = ::Gapic::Config::Method.new unregister_gcp_config
747
+ get_account_for_gcp_registration_config = parent_rpcs.get_account_for_gcp_registration if parent_rpcs.respond_to? :get_account_for_gcp_registration
748
+ @get_account_for_gcp_registration = ::Gapic::Config::Method.new get_account_for_gcp_registration_config
654
749
 
655
750
  yield self if block_given?
656
751
  end
@@ -214,7 +214,9 @@ module Google
214
214
  # updated to have the new "API notifications" preference. If the developer
215
215
  # email provided is not associated with any user we will just add it as a
216
216
  # contact. The email preference corresponding to that contact will have the
217
- # new "API notifications" preference
217
+ # new "API notifications" preference. Make sure the email used is associated
218
+ # with a Google Account (Google Workspace account or Gmail account)
219
+ # and is not a service account as service accounts can't receive emails.
218
220
  # @yield [result, operation] Access the result along with the TransportOperation object
219
221
  # @yieldparam result [::Google::Shopping::Merchant::Accounts::V1::DeveloperRegistration]
220
222
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -433,6 +435,76 @@ module Google
433
435
  raise ::Google::Cloud::Error.from_error(e)
434
436
  end
435
437
 
438
+ ##
439
+ # Retrieves the merchant account that the calling GCP is registered with.
440
+ #
441
+ # @overload get_account_for_gcp_registration(request, options = nil)
442
+ # Pass arguments to `get_account_for_gcp_registration` via a request object, either of type
443
+ # {::Google::Protobuf::Empty} or an equivalent Hash.
444
+ #
445
+ # @param request [::Google::Protobuf::Empty, ::Hash]
446
+ # A request object representing the call parameters. Required. To specify no
447
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
448
+ # @param options [::Gapic::CallOptions, ::Hash]
449
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
450
+ # @yield [result, operation] Access the result along with the TransportOperation object
451
+ # @yieldparam result [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
452
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
453
+ #
454
+ # @return [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
455
+ #
456
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
457
+ #
458
+ # @example Basic example
459
+ # require "google/shopping/merchant/accounts/v1"
460
+ #
461
+ # # Create a client object. The client can be reused for multiple calls.
462
+ # client = Google::Shopping::Merchant::Accounts::V1::DeveloperRegistrationService::Rest::Client.new
463
+ #
464
+ # # Create a request. To set request fields, pass in keyword arguments.
465
+ # request = Google::Protobuf::Empty.new
466
+ #
467
+ # # Call the get_account_for_gcp_registration method.
468
+ # result = client.get_account_for_gcp_registration request
469
+ #
470
+ # # The returned object is of type Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse.
471
+ # p result
472
+ #
473
+ def get_account_for_gcp_registration request, options = nil
474
+ raise ::ArgumentError, "request must be provided" if request.nil?
475
+
476
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Protobuf::Empty
477
+
478
+ # Converts hash and nil to an options object
479
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
480
+
481
+ # Customize the options with defaults
482
+ call_metadata = @config.rpcs.get_account_for_gcp_registration.metadata.to_h
483
+
484
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
485
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
486
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
487
+ gapic_version: ::Google::Shopping::Merchant::Accounts::V1::VERSION,
488
+ transports_version_send: [:rest]
489
+
490
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
491
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
492
+
493
+ options.apply_defaults timeout: @config.rpcs.get_account_for_gcp_registration.timeout,
494
+ metadata: call_metadata,
495
+ retry_policy: @config.rpcs.get_account_for_gcp_registration.retry_policy
496
+
497
+ options.apply_defaults timeout: @config.timeout,
498
+ metadata: @config.metadata,
499
+ retry_policy: @config.retry_policy
500
+
501
+ @developer_registration_service_stub.get_account_for_gcp_registration request, options do |result, operation|
502
+ yield result, operation if block_given?
503
+ end
504
+ rescue ::Gapic::Rest::Error => e
505
+ raise ::Google::Cloud::Error.from_error(e)
506
+ end
507
+
436
508
  ##
437
509
  # Configuration class for the DeveloperRegistrationService REST API.
438
510
  #
@@ -594,6 +666,11 @@ module Google
594
666
  # @return [::Gapic::Config::Method]
595
667
  #
596
668
  attr_reader :unregister_gcp
669
+ ##
670
+ # RPC-specific configuration for `get_account_for_gcp_registration`
671
+ # @return [::Gapic::Config::Method]
672
+ #
673
+ attr_reader :get_account_for_gcp_registration
597
674
 
598
675
  # @private
599
676
  def initialize parent_rpcs = nil
@@ -603,6 +680,8 @@ module Google
603
680
  @get_developer_registration = ::Gapic::Config::Method.new get_developer_registration_config
604
681
  unregister_gcp_config = parent_rpcs.unregister_gcp if parent_rpcs.respond_to? :unregister_gcp
605
682
  @unregister_gcp = ::Gapic::Config::Method.new unregister_gcp_config
683
+ get_account_for_gcp_registration_config = parent_rpcs.get_account_for_gcp_registration if parent_rpcs.respond_to? :get_account_for_gcp_registration
684
+ @get_account_for_gcp_registration = ::Gapic::Config::Method.new get_account_for_gcp_registration_config
606
685
 
607
686
  yield self if block_given?
608
687
  end
@@ -194,6 +194,46 @@ module Google
194
194
  end
195
195
  end
196
196
 
197
+ ##
198
+ # Baseline implementation for the get_account_for_gcp_registration REST call
199
+ #
200
+ # @param request_pb [::Google::Protobuf::Empty]
201
+ # A request object representing the call parameters. Required.
202
+ # @param options [::Gapic::CallOptions]
203
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
204
+ #
205
+ # @yield [result, operation] Access the result along with the TransportOperation object
206
+ # @yieldparam result [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
207
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
208
+ #
209
+ # @return [::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse]
210
+ # A result object deserialized from the server's reply
211
+ def get_account_for_gcp_registration request_pb, options = nil
212
+ raise ::ArgumentError, "request must be provided" if request_pb.nil?
213
+
214
+ verb, uri, query_string_params, body = ServiceStub.transcode_get_account_for_gcp_registration_request request_pb
215
+ query_string_params = if query_string_params.any?
216
+ query_string_params.to_h { |p| p.split "=", 2 }
217
+ else
218
+ {}
219
+ end
220
+
221
+ response = @client_stub.make_http_request(
222
+ verb,
223
+ uri: uri,
224
+ body: body || "",
225
+ params: query_string_params,
226
+ method_name: "get_account_for_gcp_registration",
227
+ options: options
228
+ )
229
+ operation = ::Gapic::Rest::TransportOperation.new response
230
+ result = ::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse.decode_json response.body, ignore_unknown_fields: true
231
+ catch :response do
232
+ yield result, operation if block_given?
233
+ result
234
+ end
235
+ end
236
+
197
237
  ##
198
238
  # @private
199
239
  #
@@ -258,6 +298,25 @@ module Google
258
298
  )
259
299
  transcoder.transcode request_pb
260
300
  end
301
+
302
+ ##
303
+ # @private
304
+ #
305
+ # GRPC transcoding helper method for the get_account_for_gcp_registration REST call
306
+ #
307
+ # @param request_pb [::Google::Protobuf::Empty]
308
+ # A request object representing the call parameters. Required.
309
+ # @return [Array(String, [String, nil], Hash{String => String})]
310
+ # Uri, Body, Query string parameters
311
+ def self.transcode_get_account_for_gcp_registration_request request_pb
312
+ transcoder = Gapic::Rest::GrpcTranscoder.new
313
+ .with_bindings(
314
+ uri_method: :get,
315
+ uri_template: "/accounts/v1/accounts:getAccountForGcpRegistration",
316
+ matches: []
317
+ )
318
+ transcoder.transcode request_pb
319
+ end
261
320
  end
262
321
  end
263
322
  end
@@ -11,7 +11,7 @@ require 'google/api/resource_pb'
11
11
  require 'google/protobuf/empty_pb'
12
12
 
13
13
 
14
- descriptor_data = "\n@google/shopping/merchant/accounts/v1/developerregistration.proto\x12$google.shopping.merchant.accounts.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x1bgoogle/protobuf/empty.proto\"\xd1\x01\n\x15\x44\x65veloperRegistration\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x14\n\x07gcp_ids\x18\x02 \x03(\tB\x03\xe0\x41\x03:\x8e\x01\xea\x41\x8a\x01\n0merchantapi.googleapis.com/DeveloperRegistration\x12(accounts/{account}/developerRegistration*\x15\x64\x65veloperRegistration2\x15\x64\x65veloperRegistration\"z\n\x12RegisterGcpRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration\x12\x1c\n\x0f\x64\x65veloper_email\x18\x02 \x01(\tB\x03\xe0\x41\x05\"^\n\x14UnregisterGcpRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration\"i\n\x1fGetDeveloperRegistrationRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration2\xd6\x05\n\x1c\x44\x65veloperRegistrationService\x12\xd1\x01\n\x0bRegisterGcp\x12\x38.google.shopping.merchant.accounts.v1.RegisterGcpRequest\x1a;.google.shopping.merchant.accounts.v1.DeveloperRegistration\"K\x82\xd3\xe4\x93\x02\x45\"@/accounts/v1/{name=accounts/*/developerRegistration}:registerGcp:\x01*\x12\xe3\x01\n\x18GetDeveloperRegistration\x12\x45.google.shopping.merchant.accounts.v1.GetDeveloperRegistrationRequest\x1a;.google.shopping.merchant.accounts.v1.DeveloperRegistration\"C\xda\x41\x04name\x82\xd3\xe4\x93\x02\x36\x12\x34/accounts/v1/{name=accounts/*/developerRegistration}\x12\xb2\x01\n\rUnregisterGcp\x12:.google.shopping.merchant.accounts.v1.UnregisterGcpRequest\x1a\x16.google.protobuf.Empty\"M\x82\xd3\xe4\x93\x02G\"B/accounts/v1/{name=accounts/*/developerRegistration}:unregisterGcp:\x01*\x1aG\xca\x41\x1amerchantapi.googleapis.com\xd2\x41\'https://www.googleapis.com/auth/contentB\x8d\x02\n(com.google.shopping.merchant.accounts.v1B\x1a\x44\x65veloperRegistrationProtoP\x01ZJcloud.google.com/go/shopping/merchant/accounts/apiv1/accountspb;accountspb\xaa\x02$Google.Shopping.Merchant.Accounts.V1\xca\x02$Google\\Shopping\\Merchant\\Accounts\\V1\xea\x02(Google::Shopping::Merchant::Accounts::V1b\x06proto3"
14
+ descriptor_data = "\n@google/shopping/merchant/accounts/v1/developerregistration.proto\x12$google.shopping.merchant.accounts.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x1bgoogle/protobuf/empty.proto\"\xd1\x01\n\x15\x44\x65veloperRegistration\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x14\n\x07gcp_ids\x18\x02 \x03(\tB\x03\xe0\x41\x03:\x8e\x01\xea\x41\x8a\x01\n0merchantapi.googleapis.com/DeveloperRegistration\x12(accounts/{account}/developerRegistration*\x15\x64\x65veloperRegistration2\x15\x64\x65veloperRegistration\"z\n\x12RegisterGcpRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration\x12\x1c\n\x0f\x64\x65veloper_email\x18\x02 \x01(\tB\x03\xe0\x41\x05\"^\n\x14UnregisterGcpRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration\"i\n\x1fGetDeveloperRegistrationRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0merchantapi.googleapis.com/DeveloperRegistration\"4\n$GetAccountForGcpRegistrationResponse\x12\x0c\n\x04name\x18\x01 \x01(\t2\x97\x07\n\x1c\x44\x65veloperRegistrationService\x12\xd1\x01\n\x0bRegisterGcp\x12\x38.google.shopping.merchant.accounts.v1.RegisterGcpRequest\x1a;.google.shopping.merchant.accounts.v1.DeveloperRegistration\"K\x82\xd3\xe4\x93\x02\x45\"@/accounts/v1/{name=accounts/*/developerRegistration}:registerGcp:\x01*\x12\xe3\x01\n\x18GetDeveloperRegistration\x12\x45.google.shopping.merchant.accounts.v1.GetDeveloperRegistrationRequest\x1a;.google.shopping.merchant.accounts.v1.DeveloperRegistration\"C\xda\x41\x04name\x82\xd3\xe4\x93\x02\x36\x12\x34/accounts/v1/{name=accounts/*/developerRegistration}\x12\xb2\x01\n\rUnregisterGcp\x12:.google.shopping.merchant.accounts.v1.UnregisterGcpRequest\x1a\x16.google.protobuf.Empty\"M\x82\xd3\xe4\x93\x02G\"B/accounts/v1/{name=accounts/*/developerRegistration}:unregisterGcp:\x01*\x12\xbe\x01\n\x1cGetAccountForGcpRegistration\x12\x16.google.protobuf.Empty\x1aJ.google.shopping.merchant.accounts.v1.GetAccountForGcpRegistrationResponse\":\x82\xd3\xe4\x93\x02\x34\x12\x32/accounts/v1/accounts:getAccountForGcpRegistration\x1aG\xca\x41\x1amerchantapi.googleapis.com\xd2\x41\'https://www.googleapis.com/auth/contentB\x8d\x02\n(com.google.shopping.merchant.accounts.v1B\x1a\x44\x65veloperRegistrationProtoP\x01ZJcloud.google.com/go/shopping/merchant/accounts/apiv1/accountspb;accountspb\xaa\x02$Google.Shopping.Merchant.Accounts.V1\xca\x02$Google\\Shopping\\Merchant\\Accounts\\V1\xea\x02(Google::Shopping::Merchant::Accounts::V1b\x06proto3"
15
15
 
16
16
  pool = Google::Protobuf::DescriptorPool.generated_pool
17
17
 
@@ -46,6 +46,7 @@ module Google
46
46
  RegisterGcpRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.shopping.merchant.accounts.v1.RegisterGcpRequest").msgclass
47
47
  UnregisterGcpRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.shopping.merchant.accounts.v1.UnregisterGcpRequest").msgclass
48
48
  GetDeveloperRegistrationRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.shopping.merchant.accounts.v1.GetDeveloperRegistrationRequest").msgclass
49
+ GetAccountForGcpRegistrationResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.shopping.merchant.accounts.v1.GetAccountForGcpRegistrationResponse").msgclass
49
50
  end
50
51
  end
51
52
  end
@@ -45,6 +45,8 @@ module Google
45
45
  # GCP will still be able to access the API for at most 1 day from the
46
46
  # unregister succussful call.
47
47
  rpc :UnregisterGcp, ::Google::Shopping::Merchant::Accounts::V1::UnregisterGcpRequest, ::Google::Protobuf::Empty
48
+ # Retrieves the merchant account that the calling GCP is registered with.
49
+ rpc :GetAccountForGcpRegistration, ::Google::Protobuf::Empty, ::Google::Shopping::Merchant::Accounts::V1::GetAccountForGcpRegistrationResponse
48
50
  end
49
51
 
50
52
  Stub = Service.rpc_stub_class
@@ -417,8 +417,6 @@ module Google
417
417
  # @return [::String,nil]
418
418
  # @!attribute [rw] credentials
419
419
  # Credentials to send with calls. You may provide any of the following types:
420
- # * (`String`) The path to a service account key file in JSON format
421
- # * (`Hash`) A service account key as a Hash
422
420
  # * (`Google::Auth::Credentials`) A googleauth credentials object
423
421
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
424
422
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -427,7 +425,26 @@ module Google
427
425
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
428
426
  # * (`nil`) indicating no credentials
429
427
  #
430
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
428
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
429
+ # is deprecated. Providing an unvalidated credential configuration to
430
+ # Google APIs can compromise the security of your systems and data.
431
+ #
432
+ # @example
433
+ #
434
+ # # The recommended way to provide credentials is to use the `make_creds` method
435
+ # # on the appropriate credentials class for your environment.
436
+ #
437
+ # require "googleauth"
438
+ #
439
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
440
+ # json_key_io: ::File.open("/path/to/keyfile.json")
441
+ # )
442
+ #
443
+ # client = ::Google::Shopping::Merchant::Accounts::V1::EmailPreferencesService::Client.new do |config|
444
+ # config.credentials = credentials
445
+ # end
446
+ #
447
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
431
448
  # external source for authentication to Google Cloud, you must validate it before
432
449
  # providing it to a Google API client library. Providing an unvalidated credential
433
450
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -423,8 +423,6 @@ module Google
423
423
  # @return [::String,nil]
424
424
  # @!attribute [rw] credentials
425
425
  # Credentials to send with calls. You may provide any of the following types:
426
- # * (`String`) The path to a service account key file in JSON format
427
- # * (`Hash`) A service account key as a Hash
428
426
  # * (`Google::Auth::Credentials`) A googleauth credentials object
429
427
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
430
428
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -433,7 +431,26 @@ module Google
433
431
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
434
432
  # * (`nil`) indicating no credentials
435
433
  #
436
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
434
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
435
+ # is deprecated. Providing an unvalidated credential configuration to
436
+ # Google APIs can compromise the security of your systems and data.
437
+ #
438
+ # @example
439
+ #
440
+ # # The recommended way to provide credentials is to use the `make_creds` method
441
+ # # on the appropriate credentials class for your environment.
442
+ #
443
+ # require "googleauth"
444
+ #
445
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
446
+ # json_key_io: ::File.open("/path/to/keyfile.json")
447
+ # )
448
+ #
449
+ # client = ::Google::Shopping::Merchant::Accounts::V1::GbpAccountsService::Client.new do |config|
450
+ # config.credentials = credentials
451
+ # end
452
+ #
453
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
437
454
  # external source for authentication to Google Cloud, you must validate it before
438
455
  # providing it to a Google API client library. Providing an unvalidated credential
439
456
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -598,8 +598,6 @@ module Google
598
598
  # @return [::String,nil]
599
599
  # @!attribute [rw] credentials
600
600
  # Credentials to send with calls. You may provide any of the following types:
601
- # * (`String`) The path to a service account key file in JSON format
602
- # * (`Hash`) A service account key as a Hash
603
601
  # * (`Google::Auth::Credentials`) A googleauth credentials object
604
602
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
605
603
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -608,7 +606,26 @@ module Google
608
606
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
609
607
  # * (`nil`) indicating no credentials
610
608
  #
611
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
609
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
610
+ # is deprecated. Providing an unvalidated credential configuration to
611
+ # Google APIs can compromise the security of your systems and data.
612
+ #
613
+ # @example
614
+ #
615
+ # # The recommended way to provide credentials is to use the `make_creds` method
616
+ # # on the appropriate credentials class for your environment.
617
+ #
618
+ # require "googleauth"
619
+ #
620
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
621
+ # json_key_io: ::File.open("/path/to/keyfile.json")
622
+ # )
623
+ #
624
+ # client = ::Google::Shopping::Merchant::Accounts::V1::HomepageService::Client.new do |config|
625
+ # config.credentials = credentials
626
+ # end
627
+ #
628
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
612
629
  # external source for authentication to Google Cloud, you must validate it before
613
630
  # providing it to a Google API client library. Providing an unvalidated credential
614
631
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -422,8 +422,6 @@ module Google
422
422
  # @return [::String,nil]
423
423
  # @!attribute [rw] credentials
424
424
  # Credentials to send with calls. You may provide any of the following types:
425
- # * (`String`) The path to a service account key file in JSON format
426
- # * (`Hash`) A service account key as a Hash
427
425
  # * (`Google::Auth::Credentials`) A googleauth credentials object
428
426
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
429
427
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -432,7 +430,26 @@ module Google
432
430
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
433
431
  # * (`nil`) indicating no credentials
434
432
  #
435
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
433
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
434
+ # is deprecated. Providing an unvalidated credential configuration to
435
+ # Google APIs can compromise the security of your systems and data.
436
+ #
437
+ # @example
438
+ #
439
+ # # The recommended way to provide credentials is to use the `make_creds` method
440
+ # # on the appropriate credentials class for your environment.
441
+ #
442
+ # require "googleauth"
443
+ #
444
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
445
+ # json_key_io: ::File.open("/path/to/keyfile.json")
446
+ # )
447
+ #
448
+ # client = ::Google::Shopping::Merchant::Accounts::V1::LfpProvidersService::Client.new do |config|
449
+ # config.credentials = credentials
450
+ # end
451
+ #
452
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
436
453
  # external source for authentication to Google Cloud, you must validate it before
437
454
  # providing it to a Google API client library. Providing an unvalidated credential
438
455
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -692,8 +692,6 @@ module Google
692
692
  # @return [::String,nil]
693
693
  # @!attribute [rw] credentials
694
694
  # Credentials to send with calls. You may provide any of the following types:
695
- # * (`String`) The path to a service account key file in JSON format
696
- # * (`Hash`) A service account key as a Hash
697
695
  # * (`Google::Auth::Credentials`) A googleauth credentials object
698
696
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
699
697
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -702,7 +700,26 @@ module Google
702
700
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
703
701
  # * (`nil`) indicating no credentials
704
702
  #
705
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
703
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
704
+ # is deprecated. Providing an unvalidated credential configuration to
705
+ # Google APIs can compromise the security of your systems and data.
706
+ #
707
+ # @example
708
+ #
709
+ # # The recommended way to provide credentials is to use the `make_creds` method
710
+ # # on the appropriate credentials class for your environment.
711
+ #
712
+ # require "googleauth"
713
+ #
714
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
715
+ # json_key_io: ::File.open("/path/to/keyfile.json")
716
+ # )
717
+ #
718
+ # client = ::Google::Shopping::Merchant::Accounts::V1::OmnichannelSettingsService::Client.new do |config|
719
+ # config.credentials = credentials
720
+ # end
721
+ #
722
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
706
723
  # external source for authentication to Google Cloud, you must validate it before
707
724
  # providing it to a Google API client library. Providing an unvalidated credential
708
725
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -595,8 +595,6 @@ module Google
595
595
  # @return [::String,nil]
596
596
  # @!attribute [rw] credentials
597
597
  # Credentials to send with calls. You may provide any of the following types:
598
- # * (`String`) The path to a service account key file in JSON format
599
- # * (`Hash`) A service account key as a Hash
600
598
  # * (`Google::Auth::Credentials`) A googleauth credentials object
601
599
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
602
600
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -605,7 +603,26 @@ module Google
605
603
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
606
604
  # * (`nil`) indicating no credentials
607
605
  #
608
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
606
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
607
+ # is deprecated. Providing an unvalidated credential configuration to
608
+ # Google APIs can compromise the security of your systems and data.
609
+ #
610
+ # @example
611
+ #
612
+ # # The recommended way to provide credentials is to use the `make_creds` method
613
+ # # on the appropriate credentials class for your environment.
614
+ #
615
+ # require "googleauth"
616
+ #
617
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
618
+ # json_key_io: ::File.open("/path/to/keyfile.json")
619
+ # )
620
+ #
621
+ # client = ::Google::Shopping::Merchant::Accounts::V1::OnlineReturnPolicyService::Client.new do |config|
622
+ # config.credentials = credentials
623
+ # end
624
+ #
625
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
609
626
  # external source for authentication to Google Cloud, you must validate it before
610
627
  # providing it to a Google API client library. Providing an unvalidated credential
611
628
  # configuration to Google APIs can compromise the security of your systems and data.
@@ -594,8 +594,6 @@ module Google
594
594
  # @return [::String,nil]
595
595
  # @!attribute [rw] credentials
596
596
  # Credentials to send with calls. You may provide any of the following types:
597
- # * (`String`) The path to a service account key file in JSON format
598
- # * (`Hash`) A service account key as a Hash
599
597
  # * (`Google::Auth::Credentials`) A googleauth credentials object
600
598
  # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
601
599
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
@@ -604,7 +602,26 @@ module Google
604
602
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
605
603
  # * (`nil`) indicating no credentials
606
604
  #
607
- # Warning: If you accept a credential configuration (JSON file or Hash) from an
605
+ # @note Warning: Passing a `String` to a keyfile path or a `Hash` of credentials
606
+ # is deprecated. Providing an unvalidated credential configuration to
607
+ # Google APIs can compromise the security of your systems and data.
608
+ #
609
+ # @example
610
+ #
611
+ # # The recommended way to provide credentials is to use the `make_creds` method
612
+ # # on the appropriate credentials class for your environment.
613
+ #
614
+ # require "googleauth"
615
+ #
616
+ # credentials = ::Google::Auth::ServiceAccountCredentials.make_creds(
617
+ # json_key_io: ::File.open("/path/to/keyfile.json")
618
+ # )
619
+ #
620
+ # client = ::Google::Shopping::Merchant::Accounts::V1::ProgramsService::Client.new do |config|
621
+ # config.credentials = credentials
622
+ # end
623
+ #
624
+ # @note Warning: If you accept a credential configuration (JSON file or Hash) from an
608
625
  # external source for authentication to Google Cloud, you must validate it before
609
626
  # providing it to a Google API client library. Providing an unvalidated credential
610
627
  # configuration to Google APIs can compromise the security of your systems and data.