google-cloud-retail-v2 0.20.0 → 1.0.0
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.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/google/cloud/retail/v2/analytics_service/client.rb +5 -1
- data/lib/google/cloud/retail/v2/analytics_service/operations.rb +13 -5
- data/lib/google/cloud/retail/v2/analytics_service/rest/client.rb +5 -1
- data/lib/google/cloud/retail/v2/analytics_service/rest/operations.rb +11 -4
- data/lib/google/cloud/retail/v2/catalog_pb.rb +9 -1
- data/lib/google/cloud/retail/v2/catalog_service/client.rb +25 -11
- data/lib/google/cloud/retail/v2/catalog_service/rest/client.rb +25 -11
- data/lib/google/cloud/retail/v2/common_pb.rb +4 -1
- data/lib/google/cloud/retail/v2/completion_service/client.rb +15 -6
- data/lib/google/cloud/retail/v2/completion_service/operations.rb +13 -5
- data/lib/google/cloud/retail/v2/completion_service/rest/client.rb +15 -6
- data/lib/google/cloud/retail/v2/completion_service/rest/operations.rb +11 -4
- data/lib/google/cloud/retail/v2/completion_service_pb.rb +1 -1
- data/lib/google/cloud/retail/v2/control_service/client.rb +13 -5
- data/lib/google/cloud/retail/v2/control_service/rest/client.rb +13 -5
- data/lib/google/cloud/retail/v2/model_pb.rb +4 -1
- data/lib/google/cloud/retail/v2/model_service/client.rb +19 -8
- data/lib/google/cloud/retail/v2/model_service/operations.rb +13 -5
- data/lib/google/cloud/retail/v2/model_service/rest/client.rb +19 -8
- data/lib/google/cloud/retail/v2/model_service/rest/operations.rb +11 -4
- data/lib/google/cloud/retail/v2/prediction_service/client.rb +5 -1
- data/lib/google/cloud/retail/v2/prediction_service/rest/client.rb +5 -1
- data/lib/google/cloud/retail/v2/product_service/client.rb +206 -21
- data/lib/google/cloud/retail/v2/product_service/operations.rb +13 -5
- data/lib/google/cloud/retail/v2/product_service/rest/client.rb +199 -21
- data/lib/google/cloud/retail/v2/product_service/rest/operations.rb +11 -4
- data/lib/google/cloud/retail/v2/product_service/rest/service_stub.rb +60 -0
- data/lib/google/cloud/retail/v2/product_service_pb.rb +2 -1
- data/lib/google/cloud/retail/v2/product_service_services_pb.rb +26 -6
- data/lib/google/cloud/retail/v2/purge_config_pb.rb +6 -1
- data/lib/google/cloud/retail/v2/search_service/client.rb +27 -23
- data/lib/google/cloud/retail/v2/search_service/rest/client.rb +27 -23
- data/lib/google/cloud/retail/v2/serving_config_pb.rb +1 -1
- data/lib/google/cloud/retail/v2/serving_config_service/client.rb +17 -7
- data/lib/google/cloud/retail/v2/serving_config_service/rest/client.rb +17 -7
- data/lib/google/cloud/retail/v2/user_event_service/client.rb +14 -6
- data/lib/google/cloud/retail/v2/user_event_service/operations.rb +13 -5
- data/lib/google/cloud/retail/v2/user_event_service/rest/client.rb +14 -6
- data/lib/google/cloud/retail/v2/user_event_service/rest/operations.rb +11 -4
- data/lib/google/cloud/retail/v2/version.rb +1 -1
- data/proto_docs/google/api/client.rb +4 -0
- data/proto_docs/google/cloud/retail/v2/catalog.rb +143 -4
- data/proto_docs/google/cloud/retail/v2/common.rb +104 -10
- data/proto_docs/google/cloud/retail/v2/completion_service.rb +14 -7
- data/proto_docs/google/cloud/retail/v2/import_config.rb +10 -4
- data/proto_docs/google/cloud/retail/v2/model.rb +40 -0
- data/proto_docs/google/cloud/retail/v2/product.rb +23 -22
- data/proto_docs/google/cloud/retail/v2/promotion.rb +2 -2
- data/proto_docs/google/cloud/retail/v2/purge_config.rb +93 -0
- data/proto_docs/google/cloud/retail/v2/search_service.rb +42 -42
- data/proto_docs/google/cloud/retail/v2/serving_config.rb +4 -0
- data/proto_docs/google/cloud/retail/v2/user_event.rb +3 -2
- metadata +6 -5
@@ -31,6 +31,9 @@ module Google
|
|
31
31
|
# Service for ingesting end user actions on the customer website.
|
32
32
|
#
|
33
33
|
class Client
|
34
|
+
# @private
|
35
|
+
API_VERSION = ""
|
36
|
+
|
34
37
|
# @private
|
35
38
|
DEFAULT_ENDPOINT_TEMPLATE = "retail.$UNIVERSE_DOMAIN$"
|
36
39
|
|
@@ -68,7 +71,7 @@ module Google
|
|
68
71
|
end
|
69
72
|
default_config = Client::Configuration.new parent_config
|
70
73
|
|
71
|
-
default_config.timeout =
|
74
|
+
default_config.timeout = 10.0
|
72
75
|
default_config.retry_policy = {
|
73
76
|
initial_delay: 0.1, max_delay: 5.0, multiplier: 1.3, retry_codes: [14, 4]
|
74
77
|
}
|
@@ -267,10 +270,11 @@ module Google
|
|
267
270
|
# Customize the options with defaults
|
268
271
|
metadata = @config.rpcs.write_user_event.metadata.to_h
|
269
272
|
|
270
|
-
# Set x-goog-api-client
|
273
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
271
274
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
272
275
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
273
276
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
277
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
274
278
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
275
279
|
|
276
280
|
header_params = {}
|
@@ -377,10 +381,11 @@ module Google
|
|
377
381
|
# Customize the options with defaults
|
378
382
|
metadata = @config.rpcs.collect_user_event.metadata.to_h
|
379
383
|
|
380
|
-
# Set x-goog-api-client
|
384
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
381
385
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
382
386
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
383
387
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
388
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
384
389
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
385
390
|
|
386
391
|
header_params = {}
|
@@ -502,10 +507,11 @@ module Google
|
|
502
507
|
# Customize the options with defaults
|
503
508
|
metadata = @config.rpcs.purge_user_events.metadata.to_h
|
504
509
|
|
505
|
-
# Set x-goog-api-client
|
510
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
506
511
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
507
512
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
508
513
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
514
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
509
515
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
510
516
|
|
511
517
|
header_params = {}
|
@@ -606,10 +612,11 @@ module Google
|
|
606
612
|
# Customize the options with defaults
|
607
613
|
metadata = @config.rpcs.import_user_events.metadata.to_h
|
608
614
|
|
609
|
-
# Set x-goog-api-client
|
615
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
610
616
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
611
617
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
612
618
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
619
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
613
620
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
614
621
|
|
615
622
|
header_params = {}
|
@@ -712,10 +719,11 @@ module Google
|
|
712
719
|
# Customize the options with defaults
|
713
720
|
metadata = @config.rpcs.rejoin_user_events.metadata.to_h
|
714
721
|
|
715
|
-
# Set x-goog-api-client
|
722
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
716
723
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
717
724
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
718
725
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
726
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
719
727
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
720
728
|
|
721
729
|
header_params = {}
|
@@ -26,6 +26,9 @@ module Google
|
|
26
26
|
module UserEventService
|
27
27
|
# Service that implements Longrunning Operations API.
|
28
28
|
class Operations
|
29
|
+
# @private
|
30
|
+
API_VERSION = ""
|
31
|
+
|
29
32
|
# @private
|
30
33
|
DEFAULT_ENDPOINT_TEMPLATE = "retail.$UNIVERSE_DOMAIN$"
|
31
34
|
|
@@ -191,10 +194,11 @@ module Google
|
|
191
194
|
# Customize the options with defaults
|
192
195
|
metadata = @config.rpcs.list_operations.metadata.to_h
|
193
196
|
|
194
|
-
# Set x-goog-api-client
|
197
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
195
198
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
196
199
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
197
200
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
201
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
198
202
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
199
203
|
|
200
204
|
header_params = {}
|
@@ -287,10 +291,11 @@ module Google
|
|
287
291
|
# Customize the options with defaults
|
288
292
|
metadata = @config.rpcs.get_operation.metadata.to_h
|
289
293
|
|
290
|
-
# Set x-goog-api-client
|
294
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
291
295
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
292
296
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
293
297
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
298
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
294
299
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
295
300
|
|
296
301
|
header_params = {}
|
@@ -376,10 +381,11 @@ module Google
|
|
376
381
|
# Customize the options with defaults
|
377
382
|
metadata = @config.rpcs.delete_operation.metadata.to_h
|
378
383
|
|
379
|
-
# Set x-goog-api-client
|
384
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
380
385
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
381
386
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
382
387
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
388
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
383
389
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
384
390
|
|
385
391
|
header_params = {}
|
@@ -470,10 +476,11 @@ module Google
|
|
470
476
|
# Customize the options with defaults
|
471
477
|
metadata = @config.rpcs.cancel_operation.metadata.to_h
|
472
478
|
|
473
|
-
# Set x-goog-api-client
|
479
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
474
480
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
475
481
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
476
482
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
483
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
477
484
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
478
485
|
|
479
486
|
header_params = {}
|
@@ -574,10 +581,11 @@ module Google
|
|
574
581
|
# Customize the options with defaults
|
575
582
|
metadata = @config.rpcs.wait_operation.metadata.to_h
|
576
583
|
|
577
|
-
# Set x-goog-api-client
|
584
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
578
585
|
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
579
586
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
580
587
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION
|
588
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
581
589
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
582
590
|
|
583
591
|
options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
|
@@ -33,6 +33,9 @@ module Google
|
|
33
33
|
# Service for ingesting end user actions on the customer website.
|
34
34
|
#
|
35
35
|
class Client
|
36
|
+
# @private
|
37
|
+
API_VERSION = ""
|
38
|
+
|
36
39
|
# @private
|
37
40
|
DEFAULT_ENDPOINT_TEMPLATE = "retail.$UNIVERSE_DOMAIN$"
|
38
41
|
|
@@ -70,7 +73,7 @@ module Google
|
|
70
73
|
end
|
71
74
|
default_config = Client::Configuration.new parent_config
|
72
75
|
|
73
|
-
default_config.timeout =
|
76
|
+
default_config.timeout = 10.0
|
74
77
|
default_config.retry_policy = {
|
75
78
|
initial_delay: 0.1, max_delay: 5.0, multiplier: 1.3, retry_codes: [14, 4]
|
76
79
|
}
|
@@ -259,12 +262,13 @@ module Google
|
|
259
262
|
# Customize the options with defaults
|
260
263
|
call_metadata = @config.rpcs.write_user_event.metadata.to_h
|
261
264
|
|
262
|
-
# Set x-goog-api-client
|
265
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
263
266
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
264
267
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
265
268
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
266
269
|
transports_version_send: [:rest]
|
267
270
|
|
271
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
268
272
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
269
273
|
|
270
274
|
options.apply_defaults timeout: @config.rpcs.write_user_event.timeout,
|
@@ -362,12 +366,13 @@ module Google
|
|
362
366
|
# Customize the options with defaults
|
363
367
|
call_metadata = @config.rpcs.collect_user_event.metadata.to_h
|
364
368
|
|
365
|
-
# Set x-goog-api-client
|
369
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
366
370
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
367
371
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
368
372
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
369
373
|
transports_version_send: [:rest]
|
370
374
|
|
375
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
371
376
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
372
377
|
|
373
378
|
options.apply_defaults timeout: @config.rpcs.collect_user_event.timeout,
|
@@ -480,12 +485,13 @@ module Google
|
|
480
485
|
# Customize the options with defaults
|
481
486
|
call_metadata = @config.rpcs.purge_user_events.metadata.to_h
|
482
487
|
|
483
|
-
# Set x-goog-api-client
|
488
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
484
489
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
485
490
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
486
491
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
487
492
|
transports_version_send: [:rest]
|
488
493
|
|
494
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
489
495
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
490
496
|
|
491
497
|
options.apply_defaults timeout: @config.rpcs.purge_user_events.timeout,
|
@@ -577,12 +583,13 @@ module Google
|
|
577
583
|
# Customize the options with defaults
|
578
584
|
call_metadata = @config.rpcs.import_user_events.metadata.to_h
|
579
585
|
|
580
|
-
# Set x-goog-api-client
|
586
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
581
587
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
582
588
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
583
589
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
584
590
|
transports_version_send: [:rest]
|
585
591
|
|
592
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
586
593
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
587
594
|
|
588
595
|
options.apply_defaults timeout: @config.rpcs.import_user_events.timeout,
|
@@ -676,12 +683,13 @@ module Google
|
|
676
683
|
# Customize the options with defaults
|
677
684
|
call_metadata = @config.rpcs.rejoin_user_events.metadata.to_h
|
678
685
|
|
679
|
-
# Set x-goog-api-client
|
686
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
680
687
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
681
688
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
682
689
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
683
690
|
transports_version_send: [:rest]
|
684
691
|
|
692
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
685
693
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
686
694
|
|
687
695
|
options.apply_defaults timeout: @config.rpcs.rejoin_user_events.timeout,
|
@@ -26,6 +26,9 @@ module Google
|
|
26
26
|
module Rest
|
27
27
|
# Service that implements Longrunning Operations API.
|
28
28
|
class Operations
|
29
|
+
# @private
|
30
|
+
API_VERSION = ""
|
31
|
+
|
29
32
|
# @private
|
30
33
|
DEFAULT_ENDPOINT_TEMPLATE = "retail.$UNIVERSE_DOMAIN$"
|
31
34
|
|
@@ -181,12 +184,13 @@ module Google
|
|
181
184
|
# Customize the options with defaults
|
182
185
|
call_metadata = @config.rpcs.list_operations.metadata.to_h
|
183
186
|
|
184
|
-
# Set x-goog-api-client
|
187
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
185
188
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
186
189
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
187
190
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
188
191
|
transports_version_send: [:rest]
|
189
192
|
|
193
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
190
194
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
191
195
|
|
192
196
|
options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
|
@@ -269,12 +273,13 @@ module Google
|
|
269
273
|
# Customize the options with defaults
|
270
274
|
call_metadata = @config.rpcs.get_operation.metadata.to_h
|
271
275
|
|
272
|
-
# Set x-goog-api-client
|
276
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
273
277
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
274
278
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
275
279
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
276
280
|
transports_version_send: [:rest]
|
277
281
|
|
282
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
278
283
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
279
284
|
|
280
285
|
options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
|
@@ -351,12 +356,13 @@ module Google
|
|
351
356
|
# Customize the options with defaults
|
352
357
|
call_metadata = @config.rpcs.delete_operation.metadata.to_h
|
353
358
|
|
354
|
-
# Set x-goog-api-client
|
359
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
355
360
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
356
361
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
357
362
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
358
363
|
transports_version_send: [:rest]
|
359
364
|
|
365
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
360
366
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
361
367
|
|
362
368
|
options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
|
@@ -438,12 +444,13 @@ module Google
|
|
438
444
|
# Customize the options with defaults
|
439
445
|
call_metadata = @config.rpcs.cancel_operation.metadata.to_h
|
440
446
|
|
441
|
-
# Set x-goog-api-client
|
447
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
442
448
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
443
449
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
444
450
|
gapic_version: ::Google::Cloud::Retail::V2::VERSION,
|
445
451
|
transports_version_send: [:rest]
|
446
452
|
|
453
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
447
454
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
448
455
|
|
449
456
|
options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
|
@@ -118,6 +118,10 @@ module Google
|
|
118
118
|
# @return [::String]
|
119
119
|
# Optional link to proto reference documentation. Example:
|
120
120
|
# https://cloud.google.com/pubsub/lite/docs/reference/rpc
|
121
|
+
# @!attribute [rw] rest_reference_documentation_uri
|
122
|
+
# @return [::String]
|
123
|
+
# Optional link to REST reference documentation. Example:
|
124
|
+
# https://cloud.google.com/pubsub/lite/docs/reference/rest
|
121
125
|
class Publishing
|
122
126
|
include ::Google::Protobuf::MessageExts
|
123
127
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -130,7 +130,9 @@ module Google
|
|
130
130
|
# are indexed so that it can be filtered, faceted, or boosted in
|
131
131
|
# {::Google::Cloud::Retail::V2::SearchService::Client#search SearchService.Search}.
|
132
132
|
#
|
133
|
-
# Must be specified
|
133
|
+
# Must be specified when
|
134
|
+
# {::Google::Cloud::Retail::V2::AttributesConfig#attribute_config_level AttributesConfig.attribute_config_level}
|
135
|
+
# is CATALOG_LEVEL_ATTRIBUTE_CONFIG, otherwise throws INVALID_FORMAT error.
|
134
136
|
# @!attribute [rw] dynamic_facetable_option
|
135
137
|
# @return [::Google::Cloud::Retail::V2::CatalogAttribute::DynamicFacetableOption]
|
136
138
|
# If DYNAMIC_FACETABLE_ENABLED, attribute values are available for dynamic
|
@@ -152,7 +154,9 @@ module Google
|
|
152
154
|
# {::Google::Cloud::Retail::V2::SearchService::Client#search SearchService.Search}, as
|
153
155
|
# there are no text values associated to numerical attributes.
|
154
156
|
#
|
155
|
-
# Must be specified,
|
157
|
+
# Must be specified, when
|
158
|
+
# {::Google::Cloud::Retail::V2::AttributesConfig#attribute_config_level AttributesConfig.attribute_config_level}
|
159
|
+
# is CATALOG_LEVEL_ATTRIBUTE_CONFIG, otherwise throws INVALID_FORMAT error.
|
156
160
|
# @!attribute [rw] exact_searchable_option
|
157
161
|
# @return [::Google::Cloud::Retail::V2::CatalogAttribute::ExactSearchableOption]
|
158
162
|
# If EXACT_SEARCHABLE_ENABLED, attribute values will be exact searchable.
|
@@ -165,10 +169,145 @@ module Google
|
|
165
169
|
# If RETRIEVABLE_ENABLED, attribute values are retrievable in the search
|
166
170
|
# results. If unset, the server behavior defaults to
|
167
171
|
# {::Google::Cloud::Retail::V2::CatalogAttribute::RetrievableOption::RETRIEVABLE_DISABLED RETRIEVABLE_DISABLED}.
|
172
|
+
# @!attribute [rw] facet_config
|
173
|
+
# @return [::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig]
|
174
|
+
# Contains facet options.
|
168
175
|
class CatalogAttribute
|
169
176
|
include ::Google::Protobuf::MessageExts
|
170
177
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
171
178
|
|
179
|
+
# Possible options for the facet that corresponds to the current attribute
|
180
|
+
# config.
|
181
|
+
# @!attribute [rw] facet_intervals
|
182
|
+
# @return [::Array<::Google::Cloud::Retail::V2::Interval>]
|
183
|
+
# If you don't set the facet
|
184
|
+
# {::Google::Cloud::Retail::V2::SearchRequest::FacetSpec::FacetKey#intervals SearchRequest.FacetSpec.FacetKey.intervals}
|
185
|
+
# in the request to a numerical attribute, then we use the computed
|
186
|
+
# intervals with rounded bounds obtained from all its product numerical
|
187
|
+
# attribute values. The computed intervals might not be ideal for some
|
188
|
+
# attributes. Therefore, we give you the option to overwrite them with the
|
189
|
+
# facet_intervals field. The maximum of facet intervals per
|
190
|
+
# {::Google::Cloud::Retail::V2::CatalogAttribute CatalogAttribute} is 40. Each
|
191
|
+
# interval must have a lower bound or an upper bound. If both bounds are
|
192
|
+
# provided, then the lower bound must be smaller or equal than the upper
|
193
|
+
# bound.
|
194
|
+
# @!attribute [rw] ignored_facet_values
|
195
|
+
# @return [::Array<::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::IgnoredFacetValues>]
|
196
|
+
# Each instance represents a list of attribute values to ignore as facet
|
197
|
+
# values for a specific time range. The maximum number of instances per
|
198
|
+
# {::Google::Cloud::Retail::V2::CatalogAttribute CatalogAttribute} is 25.
|
199
|
+
# @!attribute [rw] merged_facet_values
|
200
|
+
# @return [::Array<::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::MergedFacetValue>]
|
201
|
+
# Each instance replaces a list of facet values by a merged facet
|
202
|
+
# value. If a facet value is not in any list, then it will stay the same.
|
203
|
+
# To avoid conflicts, only paths of length 1 are accepted. In other words,
|
204
|
+
# if "dark_blue" merged into "BLUE", then the latter can't merge into
|
205
|
+
# "blues" because this would create a path of length 2. The maximum number
|
206
|
+
# of instances of MergedFacetValue per
|
207
|
+
# {::Google::Cloud::Retail::V2::CatalogAttribute CatalogAttribute} is 100. This
|
208
|
+
# feature is available only for textual custom attributes.
|
209
|
+
# @!attribute [rw] merged_facet
|
210
|
+
# @return [::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::MergedFacet]
|
211
|
+
# Use this field only if you want to merge a facet key into another facet
|
212
|
+
# key.
|
213
|
+
# @!attribute [rw] rerank_config
|
214
|
+
# @return [::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::RerankConfig]
|
215
|
+
# Set this field only if you want to rerank based on facet values engaged
|
216
|
+
# by the user for the current key. This option is only possible for custom
|
217
|
+
# facetable textual keys.
|
218
|
+
class FacetConfig
|
219
|
+
include ::Google::Protobuf::MessageExts
|
220
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
221
|
+
|
222
|
+
# {::Google::Cloud::Retail::V2::SearchResponse::Facet#values Facet values} to
|
223
|
+
# ignore on {::Google::Cloud::Retail::V2::SearchResponse::Facet facets} during
|
224
|
+
# the specified time range for the given
|
225
|
+
# {::Google::Cloud::Retail::V2::SearchResponse::Facet#key SearchResponse.Facet.key}
|
226
|
+
# attribute.
|
227
|
+
# @!attribute [rw] values
|
228
|
+
# @return [::Array<::String>]
|
229
|
+
# List of facet values to ignore for the following time range. The facet
|
230
|
+
# values are the same as the attribute values. There is a limit of 10
|
231
|
+
# values per instance of IgnoredFacetValues. Each value can have at most
|
232
|
+
# 128 characters.
|
233
|
+
# @!attribute [rw] start_time
|
234
|
+
# @return [::Google::Protobuf::Timestamp]
|
235
|
+
# Time range for the current list of facet values to ignore.
|
236
|
+
# If multiple time ranges are specified for an facet value for the
|
237
|
+
# current attribute, consider all of them. If both are empty, ignore
|
238
|
+
# always. If start time and end time are set, then start time
|
239
|
+
# must be before end time.
|
240
|
+
# If start time is not empty and end time is empty, then will ignore
|
241
|
+
# these facet values after the start time.
|
242
|
+
# @!attribute [rw] end_time
|
243
|
+
# @return [::Google::Protobuf::Timestamp]
|
244
|
+
# If start time is empty and end time is not empty, then ignore these
|
245
|
+
# facet values before end time.
|
246
|
+
class IgnoredFacetValues
|
247
|
+
include ::Google::Protobuf::MessageExts
|
248
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
249
|
+
end
|
250
|
+
|
251
|
+
# Replaces a set of textual facet values by the same (possibly different)
|
252
|
+
# merged facet value. Each facet value should appear at most once as a
|
253
|
+
# value per {::Google::Cloud::Retail::V2::CatalogAttribute CatalogAttribute}.
|
254
|
+
# This feature is available only for textual custom attributes.
|
255
|
+
# @!attribute [rw] values
|
256
|
+
# @return [::Array<::String>]
|
257
|
+
# All the facet values that are replaces by the same
|
258
|
+
# {::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::MergedFacetValue#merged_value merged_value}
|
259
|
+
# that follows. The maximum number of values per MergedFacetValue is 25.
|
260
|
+
# Each value can have up to 128 characters.
|
261
|
+
# @!attribute [rw] merged_value
|
262
|
+
# @return [::String]
|
263
|
+
# All the previous values are replaced by this merged facet value.
|
264
|
+
# This merged_value must be non-empty and can have up to 128 characters.
|
265
|
+
class MergedFacetValue
|
266
|
+
include ::Google::Protobuf::MessageExts
|
267
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
268
|
+
end
|
269
|
+
|
270
|
+
# The current facet key (i.e. attribute config) maps into the
|
271
|
+
# {::Google::Cloud::Retail::V2::CatalogAttribute::FacetConfig::MergedFacet#merged_facet_key merged_facet_key}.
|
272
|
+
# A facet key can have at most one child. The current facet key and the
|
273
|
+
# merged facet key need both to be textual custom attributes or both
|
274
|
+
# numerical custom attributes (same type).
|
275
|
+
# @!attribute [rw] merged_facet_key
|
276
|
+
# @return [::String]
|
277
|
+
# The merged facet key should be a valid facet key that is different than
|
278
|
+
# the facet key of the current catalog attribute. We refer this is
|
279
|
+
# merged facet key as the child of the current catalog attribute. This
|
280
|
+
# merged facet key can't be a parent of another facet key (i.e. no
|
281
|
+
# directed path of length 2). This merged facet key needs to be either a
|
282
|
+
# textual custom attribute or a numerical custom attribute.
|
283
|
+
class MergedFacet
|
284
|
+
include ::Google::Protobuf::MessageExts
|
285
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
286
|
+
end
|
287
|
+
|
288
|
+
# Options to rerank based on facet values engaged by the user for the
|
289
|
+
# current key. That key needs to be a custom textual key and facetable.
|
290
|
+
# To use this control, you also need to pass all the facet keys engaged by
|
291
|
+
# the user in the request using the field [SearchRequest.FacetSpec]. In
|
292
|
+
# particular, if you don't pass the facet keys engaged that you want to
|
293
|
+
# rerank on, this control won't be effective. Moreover, to obtain better
|
294
|
+
# results, the facet values that you want to rerank on should be close to
|
295
|
+
# English (ideally made of words, underscores, and spaces).
|
296
|
+
# @!attribute [rw] rerank_facet
|
297
|
+
# @return [::Boolean]
|
298
|
+
# If set to true, then we also rerank the dynamic facets based on the
|
299
|
+
# facet values engaged by the user for the current attribute key during
|
300
|
+
# serving.
|
301
|
+
# @!attribute [rw] facet_values
|
302
|
+
# @return [::Array<::String>]
|
303
|
+
# If empty, rerank on all facet values for the current key. Otherwise,
|
304
|
+
# will rerank on the facet values from this list only.
|
305
|
+
class RerankConfig
|
306
|
+
include ::Google::Protobuf::MessageExts
|
307
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
308
|
+
end
|
309
|
+
end
|
310
|
+
|
172
311
|
# The type of an attribute.
|
173
312
|
module AttributeType
|
174
313
|
# The type of the attribute is unknown.
|
@@ -327,8 +466,8 @@ module Google
|
|
327
466
|
# Output only. Name of the LRO corresponding to the latest suggestion terms
|
328
467
|
# list import.
|
329
468
|
#
|
330
|
-
# Can use GetOperation API
|
331
|
-
# retrieve the latest state of the Long Running Operation.
|
469
|
+
# Can use GetOperation API
|
470
|
+
# method to retrieve the latest state of the Long Running Operation.
|
332
471
|
# @!attribute [r] denylist_input_config
|
333
472
|
# @return [::Google::Cloud::Retail::V2::CompletionDataInputConfig]
|
334
473
|
# Output only. The source data for the latest import of the autocomplete
|