google-cloud-retail-v2 0.3.2 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/retail/v2.rb +2 -0
  3. data/lib/google/cloud/retail/v2/catalog_pb.rb +2 -0
  4. data/lib/google/cloud/retail/v2/catalog_service/client.rb +203 -4
  5. data/lib/google/cloud/retail/v2/catalog_service/paths.rb +21 -0
  6. data/lib/google/cloud/retail/v2/catalog_service_pb.rb +16 -0
  7. data/lib/google/cloud/retail/v2/catalog_service_services_pb.rb +46 -0
  8. data/lib/google/cloud/retail/v2/common_pb.rb +46 -0
  9. data/lib/google/cloud/retail/v2/completion_service.rb +54 -0
  10. data/lib/google/cloud/retail/v2/completion_service/client.rb +546 -0
  11. data/lib/google/cloud/retail/v2/completion_service/credentials.rb +51 -0
  12. data/lib/google/cloud/retail/v2/completion_service/operations.rb +655 -0
  13. data/lib/google/cloud/retail/v2/completion_service/paths.rb +52 -0
  14. data/lib/google/cloud/retail/v2/completion_service_pb.rb +50 -0
  15. data/lib/google/cloud/retail/v2/completion_service_services_pb.rb +61 -0
  16. data/lib/google/cloud/retail/v2/import_config_pb.rb +32 -0
  17. data/lib/google/cloud/retail/v2/prediction_service/client.rb +34 -33
  18. data/lib/google/cloud/retail/v2/product_pb.rb +21 -0
  19. data/lib/google/cloud/retail/v2/product_service/client.rb +632 -4
  20. data/lib/google/cloud/retail/v2/product_service_pb.rb +56 -0
  21. data/lib/google/cloud/retail/v2/product_service_services_pb.rb +75 -0
  22. data/lib/google/cloud/retail/v2/search_service.rb +53 -0
  23. data/lib/google/cloud/retail/v2/search_service/client.rb +541 -0
  24. data/lib/google/cloud/retail/v2/search_service/credentials.rb +51 -0
  25. data/lib/google/cloud/retail/v2/search_service/paths.rb +54 -0
  26. data/lib/google/cloud/retail/v2/search_service_pb.rb +131 -0
  27. data/lib/google/cloud/retail/v2/search_service_services_pb.rb +53 -0
  28. data/lib/google/cloud/retail/v2/user_event_pb.rb +11 -0
  29. data/lib/google/cloud/retail/v2/user_event_service/client.rb +1 -1
  30. data/lib/google/cloud/retail/v2/user_event_service/paths.rb +19 -0
  31. data/lib/google/cloud/retail/v2/version.rb +1 -1
  32. data/proto_docs/google/cloud/retail/v2/catalog.rb +6 -6
  33. data/proto_docs/google/cloud/retail/v2/catalog_service.rb +53 -4
  34. data/proto_docs/google/cloud/retail/v2/common.rb +272 -4
  35. data/proto_docs/google/cloud/retail/v2/completion_service.rb +162 -0
  36. data/proto_docs/google/cloud/retail/v2/import_config.rb +122 -6
  37. data/proto_docs/google/cloud/retail/v2/prediction_service.rb +32 -31
  38. data/proto_docs/google/cloud/retail/v2/product.rb +266 -10
  39. data/proto_docs/google/cloud/retail/v2/product_service.rb +362 -2
  40. data/proto_docs/google/cloud/retail/v2/purge_config.rb +1 -1
  41. data/proto_docs/google/cloud/retail/v2/search_service.rb +820 -0
  42. data/proto_docs/google/cloud/retail/v2/user_event.rb +95 -3
  43. data/proto_docs/google/type/date.rb +53 -0
  44. metadata +18 -2
@@ -0,0 +1,51 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "googleauth"
20
+
21
+ module Google
22
+ module Cloud
23
+ module Retail
24
+ module V2
25
+ module SearchService
26
+ # Credentials for the SearchService API.
27
+ class Credentials < ::Google::Auth::Credentials
28
+ self.scope = [
29
+ "https://www.googleapis.com/auth/cloud-platform"
30
+ ]
31
+ self.env_vars = [
32
+ "RETAIL_CREDENTIALS",
33
+ "RETAIL_KEYFILE",
34
+ "GOOGLE_CLOUD_CREDENTIALS",
35
+ "GOOGLE_CLOUD_KEYFILE",
36
+ "GCLOUD_KEYFILE",
37
+ "RETAIL_CREDENTIALS_JSON",
38
+ "RETAIL_KEYFILE_JSON",
39
+ "GOOGLE_CLOUD_CREDENTIALS_JSON",
40
+ "GOOGLE_CLOUD_KEYFILE_JSON",
41
+ "GCLOUD_KEYFILE_JSON"
42
+ ]
43
+ self.paths = [
44
+ "~/.config/google_cloud/application_default_credentials.json"
45
+ ]
46
+ end
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,54 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module Retail
23
+ module V2
24
+ module SearchService
25
+ # Path helper methods for the SearchService API.
26
+ module Paths
27
+ ##
28
+ # Create a fully-qualified Branch resource string.
29
+ #
30
+ # The resource will be in the following format:
31
+ #
32
+ # `projects/{project}/locations/{location}/catalogs/{catalog}/branches/{branch}`
33
+ #
34
+ # @param project [String]
35
+ # @param location [String]
36
+ # @param catalog [String]
37
+ # @param branch [String]
38
+ #
39
+ # @return [::String]
40
+ def branch_path project:, location:, catalog:, branch:
41
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
42
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
43
+ raise ::ArgumentError, "catalog cannot contain /" if catalog.to_s.include? "/"
44
+
45
+ "projects/#{project}/locations/#{location}/catalogs/#{catalog}/branches/#{branch}"
46
+ end
47
+
48
+ extend self
49
+ end
50
+ end
51
+ end
52
+ end
53
+ end
54
+ end
@@ -0,0 +1,131 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/cloud/retail/v2/search_service.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/annotations_pb'
7
+ require 'google/api/client_pb'
8
+ require 'google/api/field_behavior_pb'
9
+ require 'google/api/resource_pb'
10
+ require 'google/cloud/retail/v2/common_pb'
11
+ require 'google/cloud/retail/v2/product_pb'
12
+ require 'google/protobuf/field_mask_pb'
13
+ require 'google/protobuf/struct_pb'
14
+ require 'google/protobuf/timestamp_pb'
15
+ require 'google/protobuf/wrappers_pb'
16
+ Google::Protobuf::DescriptorPool.generated_pool.build do
17
+ add_file("google/cloud/retail/v2/search_service.proto", :syntax => :proto3) do
18
+ add_message "google.cloud.retail.v2.SearchRequest" do
19
+ optional :placement, :string, 1
20
+ optional :branch, :string, 2
21
+ optional :query, :string, 3
22
+ optional :visitor_id, :string, 4
23
+ optional :user_info, :message, 5, "google.cloud.retail.v2.UserInfo"
24
+ optional :page_size, :int32, 7
25
+ optional :page_token, :string, 8
26
+ optional :offset, :int32, 9
27
+ optional :filter, :string, 10
28
+ optional :canonical_filter, :string, 28
29
+ optional :order_by, :string, 11
30
+ repeated :facet_specs, :message, 12, "google.cloud.retail.v2.SearchRequest.FacetSpec"
31
+ optional :dynamic_facet_spec, :message, 21, "google.cloud.retail.v2.SearchRequest.DynamicFacetSpec"
32
+ optional :boost_spec, :message, 13, "google.cloud.retail.v2.SearchRequest.BoostSpec"
33
+ optional :query_expansion_spec, :message, 14, "google.cloud.retail.v2.SearchRequest.QueryExpansionSpec"
34
+ repeated :variant_rollup_keys, :string, 17
35
+ repeated :page_categories, :string, 23
36
+ end
37
+ add_message "google.cloud.retail.v2.SearchRequest.FacetSpec" do
38
+ optional :facet_key, :message, 1, "google.cloud.retail.v2.SearchRequest.FacetSpec.FacetKey"
39
+ optional :limit, :int32, 2
40
+ repeated :excluded_filter_keys, :string, 3
41
+ optional :enable_dynamic_position, :bool, 4
42
+ end
43
+ add_message "google.cloud.retail.v2.SearchRequest.FacetSpec.FacetKey" do
44
+ optional :key, :string, 1
45
+ repeated :intervals, :message, 2, "google.cloud.retail.v2.Interval"
46
+ repeated :restricted_values, :string, 3
47
+ repeated :prefixes, :string, 8
48
+ repeated :contains, :string, 9
49
+ optional :order_by, :string, 4
50
+ optional :query, :string, 5
51
+ end
52
+ add_message "google.cloud.retail.v2.SearchRequest.DynamicFacetSpec" do
53
+ optional :mode, :enum, 1, "google.cloud.retail.v2.SearchRequest.DynamicFacetSpec.Mode"
54
+ end
55
+ add_enum "google.cloud.retail.v2.SearchRequest.DynamicFacetSpec.Mode" do
56
+ value :MODE_UNSPECIFIED, 0
57
+ value :DISABLED, 1
58
+ value :ENABLED, 2
59
+ end
60
+ add_message "google.cloud.retail.v2.SearchRequest.BoostSpec" do
61
+ repeated :condition_boost_specs, :message, 1, "google.cloud.retail.v2.SearchRequest.BoostSpec.ConditionBoostSpec"
62
+ end
63
+ add_message "google.cloud.retail.v2.SearchRequest.BoostSpec.ConditionBoostSpec" do
64
+ optional :condition, :string, 1
65
+ optional :boost, :float, 2
66
+ end
67
+ add_message "google.cloud.retail.v2.SearchRequest.QueryExpansionSpec" do
68
+ optional :condition, :enum, 1, "google.cloud.retail.v2.SearchRequest.QueryExpansionSpec.Condition"
69
+ end
70
+ add_enum "google.cloud.retail.v2.SearchRequest.QueryExpansionSpec.Condition" do
71
+ value :CONDITION_UNSPECIFIED, 0
72
+ value :DISABLED, 1
73
+ value :AUTO, 3
74
+ end
75
+ add_message "google.cloud.retail.v2.SearchResponse" do
76
+ repeated :results, :message, 1, "google.cloud.retail.v2.SearchResponse.SearchResult"
77
+ repeated :facets, :message, 2, "google.cloud.retail.v2.SearchResponse.Facet"
78
+ optional :total_size, :int32, 3
79
+ optional :corrected_query, :string, 4
80
+ optional :attribution_token, :string, 5
81
+ optional :next_page_token, :string, 6
82
+ optional :query_expansion_info, :message, 7, "google.cloud.retail.v2.SearchResponse.QueryExpansionInfo"
83
+ optional :redirect_uri, :string, 10
84
+ end
85
+ add_message "google.cloud.retail.v2.SearchResponse.SearchResult" do
86
+ optional :id, :string, 1
87
+ optional :product, :message, 2, "google.cloud.retail.v2.Product"
88
+ optional :matching_variant_count, :int32, 3
89
+ map :matching_variant_fields, :string, :message, 4, "google.protobuf.FieldMask"
90
+ map :variant_rollup_values, :string, :message, 5, "google.protobuf.Value"
91
+ end
92
+ add_message "google.cloud.retail.v2.SearchResponse.Facet" do
93
+ optional :key, :string, 1
94
+ repeated :values, :message, 2, "google.cloud.retail.v2.SearchResponse.Facet.FacetValue"
95
+ optional :dynamic_facet, :bool, 3
96
+ end
97
+ add_message "google.cloud.retail.v2.SearchResponse.Facet.FacetValue" do
98
+ optional :count, :int64, 3
99
+ oneof :facet_value do
100
+ optional :value, :string, 1
101
+ optional :interval, :message, 2, "google.cloud.retail.v2.Interval"
102
+ end
103
+ end
104
+ add_message "google.cloud.retail.v2.SearchResponse.QueryExpansionInfo" do
105
+ optional :expanded_query, :bool, 1
106
+ end
107
+ end
108
+ end
109
+
110
+ module Google
111
+ module Cloud
112
+ module Retail
113
+ module V2
114
+ SearchRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest").msgclass
115
+ SearchRequest::FacetSpec = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.FacetSpec").msgclass
116
+ SearchRequest::FacetSpec::FacetKey = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.FacetSpec.FacetKey").msgclass
117
+ SearchRequest::DynamicFacetSpec = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.DynamicFacetSpec").msgclass
118
+ SearchRequest::DynamicFacetSpec::Mode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.DynamicFacetSpec.Mode").enummodule
119
+ SearchRequest::BoostSpec = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.BoostSpec").msgclass
120
+ SearchRequest::BoostSpec::ConditionBoostSpec = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.BoostSpec.ConditionBoostSpec").msgclass
121
+ SearchRequest::QueryExpansionSpec = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.QueryExpansionSpec").msgclass
122
+ SearchRequest::QueryExpansionSpec::Condition = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchRequest.QueryExpansionSpec.Condition").enummodule
123
+ SearchResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchResponse").msgclass
124
+ SearchResponse::SearchResult = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchResponse.SearchResult").msgclass
125
+ SearchResponse::Facet = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchResponse.Facet").msgclass
126
+ SearchResponse::Facet::FacetValue = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchResponse.Facet.FacetValue").msgclass
127
+ SearchResponse::QueryExpansionInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.SearchResponse.QueryExpansionInfo").msgclass
128
+ end
129
+ end
130
+ end
131
+ end
@@ -0,0 +1,53 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: google/cloud/retail/v2/search_service.proto for package 'Google.Cloud.Retail.V2'
3
+ # Original file comments:
4
+ # Copyright 2020 Google LLC
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ require 'grpc'
20
+ require 'google/cloud/retail/v2/search_service_pb'
21
+
22
+ module Google
23
+ module Cloud
24
+ module Retail
25
+ module V2
26
+ module SearchService
27
+ # Service for search.
28
+ #
29
+ # This feature is only available for users who have Retail Search enabled.
30
+ # Contact Retail Support (retail-search-support@google.com) if you are
31
+ # interested in using Retail Search.
32
+ class Service
33
+
34
+ include GRPC::GenericService
35
+
36
+ self.marshal_class_method = :encode
37
+ self.unmarshal_class_method = :decode
38
+ self.service_name = 'google.cloud.retail.v2.SearchService'
39
+
40
+ # Performs a search.
41
+ #
42
+ # This feature is only available for users who have Retail Search enabled.
43
+ # Contact Retail Support (retail-search-support@google.com) if you are
44
+ # interested in using Retail Search.
45
+ rpc :Search, ::Google::Cloud::Retail::V2::SearchRequest, ::Google::Cloud::Retail::V2::SearchResponse
46
+ end
47
+
48
+ Stub = Service.rpc_stub_class
49
+ end
50
+ end
51
+ end
52
+ end
53
+ end
@@ -14,14 +14,19 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
14
14
  add_message "google.cloud.retail.v2.UserEvent" do
15
15
  optional :event_type, :string, 1
16
16
  optional :visitor_id, :string, 2
17
+ optional :session_id, :string, 21
17
18
  optional :event_time, :message, 3, "google.protobuf.Timestamp"
18
19
  repeated :experiment_ids, :string, 4
19
20
  optional :attribution_token, :string, 5
20
21
  repeated :product_details, :message, 6, "google.cloud.retail.v2.ProductDetail"
22
+ optional :completion_detail, :message, 22, "google.cloud.retail.v2.CompletionDetail"
21
23
  map :attributes, :string, :message, 7, "google.cloud.retail.v2.CustomAttribute"
22
24
  optional :cart_id, :string, 8
23
25
  optional :purchase_transaction, :message, 9, "google.cloud.retail.v2.PurchaseTransaction"
24
26
  optional :search_query, :string, 10
27
+ optional :filter, :string, 16
28
+ optional :order_by, :string, 17
29
+ optional :offset, :int32, 18
25
30
  repeated :page_categories, :string, 11
26
31
  optional :user_info, :message, 12, "google.cloud.retail.v2.UserInfo"
27
32
  optional :uri, :string, 13
@@ -32,6 +37,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
32
37
  optional :product, :message, 1, "google.cloud.retail.v2.Product"
33
38
  optional :quantity, :message, 2, "google.protobuf.Int32Value"
34
39
  end
40
+ add_message "google.cloud.retail.v2.CompletionDetail" do
41
+ optional :completion_attribution_token, :string, 1
42
+ optional :selected_suggestion, :string, 2
43
+ optional :selected_position, :int32, 3
44
+ end
35
45
  add_message "google.cloud.retail.v2.PurchaseTransaction" do
36
46
  optional :id, :string, 1
37
47
  optional :revenue, :float, 2
@@ -48,6 +58,7 @@ module Google
48
58
  module V2
49
59
  UserEvent = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.UserEvent").msgclass
50
60
  ProductDetail = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.ProductDetail").msgclass
61
+ CompletionDetail = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.CompletionDetail").msgclass
51
62
  PurchaseTransaction = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.PurchaseTransaction").msgclass
52
63
  end
53
64
  end
@@ -343,7 +343,7 @@ module Google
343
343
  # @param parent [::String]
344
344
  # Required. The resource name of the catalog under which the events are
345
345
  # created. The format is
346
- # "projects/$\\{projectId}/locations/global/catalogs/$\\{catalogId}"
346
+ # `projects/${projectId}/locations/global/catalogs/${catalogId}`
347
347
  # @param filter [::String]
348
348
  # Required. The filter string to specify the events to be deleted with a
349
349
  # length limit of 5,000 characters. Empty string filter is not allowed. The
@@ -24,6 +24,25 @@ module Google
24
24
  module UserEventService
25
25
  # Path helper methods for the UserEventService API.
26
26
  module Paths
27
+ ##
28
+ # Create a fully-qualified Catalog resource string.
29
+ #
30
+ # The resource will be in the following format:
31
+ #
32
+ # `projects/{project}/locations/{location}/catalogs/{catalog}`
33
+ #
34
+ # @param project [String]
35
+ # @param location [String]
36
+ # @param catalog [String]
37
+ #
38
+ # @return [::String]
39
+ def catalog_path project:, location:, catalog:
40
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
41
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
42
+
43
+ "projects/#{project}/locations/#{location}/catalogs/#{catalog}"
44
+ end
45
+
27
46
  ##
28
47
  # Create a fully-qualified Product resource string.
29
48
  #
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Retail
23
23
  module V2
24
- VERSION = "0.3.2"
24
+ VERSION = "0.4.0"
25
25
  end
26
26
  end
27
27
  end
@@ -48,9 +48,9 @@ module Google
48
48
  # {::Google::Cloud::Retail::V2::ProductLevelConfig#merchant_center_product_id_field merchant_center_product_id_field}
49
49
  # is `itemGroupId`, an INVALID_ARGUMENT error is returned.
50
50
  #
51
- # See [Using catalog
52
- # levels](/retail/recommendations-ai/docs/catalog#catalog-levels) for more
53
- # details.
51
+ # See [Using product
52
+ # levels](https://cloud.google.com/retail/recommendations-ai/docs/catalog#product-levels)
53
+ # for more details.
54
54
  # @!attribute [rw] merchant_center_product_id_field
55
55
  # @return [::String]
56
56
  # Which field of [Merchant Center
@@ -70,9 +70,9 @@ module Google
70
70
  # {::Google::Cloud::Retail::V2::ProductLevelConfig#ingestion_product_type ingestion_product_type}
71
71
  # is `variant`, an INVALID_ARGUMENT error is returned.
72
72
  #
73
- # See [Using catalog
74
- # levels](/retail/recommendations-ai/docs/catalog#catalog-levels) for more
75
- # details.
73
+ # See [Using product
74
+ # levels](https://cloud.google.com/retail/recommendations-ai/docs/catalog#product-levels)
75
+ # for more details.
76
76
  class ProductLevelConfig
77
77
  include ::Google::Protobuf::MessageExts
78
78
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -89,10 +89,7 @@ module Google
89
89
  # @!attribute [rw] update_mask
90
90
  # @return [::Google::Protobuf::FieldMask]
91
91
  # Indicates which fields in the provided
92
- # {::Google::Cloud::Retail::V2::Catalog Catalog} to update. If not set, will only
93
- # update the
94
- # {::Google::Cloud::Retail::V2::Catalog#product_level_config Catalog.product_level_config}
95
- # field, which is also the only currently supported field to update.
92
+ # {::Google::Cloud::Retail::V2::Catalog Catalog} to update.
96
93
  #
97
94
  # If an unsupported or unknown field is provided, an INVALID_ARGUMENT error
98
95
  # is returned.
@@ -100,6 +97,58 @@ module Google
100
97
  include ::Google::Protobuf::MessageExts
101
98
  extend ::Google::Protobuf::MessageExts::ClassMethods
102
99
  end
100
+
101
+ # Request message to set a specified branch as new default_branch.
102
+ # @!attribute [rw] catalog
103
+ # @return [::String]
104
+ # Full resource name of the catalog, such as
105
+ # `projects/*/locations/global/catalogs/default_catalog`.
106
+ # @!attribute [rw] branch_id
107
+ # @return [::String]
108
+ # The final component of the resource name of a branch.
109
+ #
110
+ # This field must be one of "0", "1" or "2". Otherwise, an INVALID_ARGUMENT
111
+ # error is returned.
112
+ # @!attribute [rw] note
113
+ # @return [::String]
114
+ # Some note on this request, this can be retrieved by
115
+ # {::Google::Cloud::Retail::V2::CatalogService::Client#get_default_branch CatalogService.GetDefaultBranch}
116
+ # before next valid default branch set occurs.
117
+ #
118
+ # This field must be a UTF-8 encoded string with a length limit of 1,000
119
+ # characters. Otherwise, an INVALID_ARGUMENT error is returned.
120
+ class SetDefaultBranchRequest
121
+ include ::Google::Protobuf::MessageExts
122
+ extend ::Google::Protobuf::MessageExts::ClassMethods
123
+ end
124
+
125
+ # Request message to show which branch is currently the default branch.
126
+ # @!attribute [rw] catalog
127
+ # @return [::String]
128
+ # The parent catalog resource name, such as
129
+ # `projects/*/locations/global/catalogs/default_catalog`.
130
+ class GetDefaultBranchRequest
131
+ include ::Google::Protobuf::MessageExts
132
+ extend ::Google::Protobuf::MessageExts::ClassMethods
133
+ end
134
+
135
+ # Response message of
136
+ # {::Google::Cloud::Retail::V2::CatalogService::Client#get_default_branch CatalogService.GetDefaultBranch}.
137
+ # @!attribute [rw] branch
138
+ # @return [::String]
139
+ # Full resource name of the branch id currently set as default branch.
140
+ # @!attribute [rw] set_time
141
+ # @return [::Google::Protobuf::Timestamp]
142
+ # The time when this branch is set to default.
143
+ # @!attribute [rw] note
144
+ # @return [::String]
145
+ # This corresponds to
146
+ # {::Google::Cloud::Retail::V2::SetDefaultBranchRequest#note SetDefaultBranchRequest.note}
147
+ # field, when this branch was set as default.
148
+ class GetDefaultBranchResponse
149
+ include ::Google::Protobuf::MessageExts
150
+ extend ::Google::Protobuf::MessageExts::ClassMethods
151
+ end
103
152
  end
104
153
  end
105
154
  end