google-cloud-discovery_engine-v1beta 0.11.0 → 0.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (115) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/discovery_engine/v1beta/completion_service/client.rb +9 -3
  3. data/lib/google/cloud/discovery_engine/v1beta/completion_service/operations.rb +13 -5
  4. data/lib/google/cloud/discovery_engine/v1beta/completion_service/rest/client.rb +9 -3
  5. data/lib/google/cloud/discovery_engine/v1beta/completion_service/rest/operations.rb +21 -6
  6. data/lib/google/cloud/discovery_engine/v1beta/control_service/client.rb +875 -0
  7. data/lib/google/cloud/discovery_engine/v1beta/control_service/credentials.rb +47 -0
  8. data/lib/google/cloud/discovery_engine/v1beta/control_service/paths.rb +167 -0
  9. data/lib/google/cloud/discovery_engine/v1beta/control_service/rest/client.rb +814 -0
  10. data/lib/google/cloud/discovery_engine/v1beta/control_service/rest/service_stub.rb +440 -0
  11. data/lib/google/cloud/discovery_engine/v1beta/control_service/rest.rb +55 -0
  12. data/lib/google/cloud/discovery_engine/v1beta/control_service.rb +58 -0
  13. data/lib/google/cloud/discovery_engine/v1beta/conversational_search_service/client.rb +31 -15
  14. data/lib/google/cloud/discovery_engine/v1beta/conversational_search_service/rest/client.rb +31 -15
  15. data/lib/google/cloud/discovery_engine/v1beta/data_store_service/client.rb +15 -7
  16. data/lib/google/cloud/discovery_engine/v1beta/data_store_service/operations.rb +13 -5
  17. data/lib/google/cloud/discovery_engine/v1beta/data_store_service/rest/client.rb +15 -7
  18. data/lib/google/cloud/discovery_engine/v1beta/data_store_service/rest/operations.rb +21 -6
  19. data/lib/google/cloud/discovery_engine/v1beta/document_service/client.rb +24 -15
  20. data/lib/google/cloud/discovery_engine/v1beta/document_service/operations.rb +13 -5
  21. data/lib/google/cloud/discovery_engine/v1beta/document_service/rest/client.rb +24 -15
  22. data/lib/google/cloud/discovery_engine/v1beta/document_service/rest/operations.rb +21 -6
  23. data/lib/google/cloud/discovery_engine/v1beta/engine_service/client.rb +19 -8
  24. data/lib/google/cloud/discovery_engine/v1beta/engine_service/operations.rb +13 -5
  25. data/lib/google/cloud/discovery_engine/v1beta/engine_service/rest/client.rb +19 -8
  26. data/lib/google/cloud/discovery_engine/v1beta/engine_service/rest/operations.rb +21 -6
  27. data/lib/google/cloud/discovery_engine/v1beta/grounded_generation_service/client.rb +25 -3
  28. data/lib/google/cloud/discovery_engine/v1beta/grounded_generation_service/rest/client.rb +25 -3
  29. data/lib/google/cloud/discovery_engine/v1beta/project_service/client.rb +485 -0
  30. data/lib/google/cloud/discovery_engine/v1beta/project_service/credentials.rb +47 -0
  31. data/lib/google/cloud/discovery_engine/v1beta/project_service/operations.rb +809 -0
  32. data/lib/google/cloud/discovery_engine/v1beta/project_service/paths.rb +47 -0
  33. data/lib/google/cloud/discovery_engine/v1beta/project_service/rest/client.rb +452 -0
  34. data/lib/google/cloud/discovery_engine/v1beta/project_service/rest/operations.rb +1092 -0
  35. data/lib/google/cloud/discovery_engine/v1beta/project_service/rest/service_stub.rb +129 -0
  36. data/lib/google/cloud/discovery_engine/v1beta/project_service/rest.rb +54 -0
  37. data/lib/google/cloud/discovery_engine/v1beta/project_service.rb +57 -0
  38. data/lib/google/cloud/discovery_engine/v1beta/rank_service/client.rb +24 -2
  39. data/lib/google/cloud/discovery_engine/v1beta/rank_service/rest/client.rb +24 -2
  40. data/lib/google/cloud/discovery_engine/v1beta/recommendation_service/client.rb +24 -19
  41. data/lib/google/cloud/discovery_engine/v1beta/recommendation_service/paths.rb +66 -0
  42. data/lib/google/cloud/discovery_engine/v1beta/recommendation_service/rest/client.rb +24 -19
  43. data/lib/google/cloud/discovery_engine/v1beta/rest.rb +2 -0
  44. data/lib/google/cloud/discovery_engine/v1beta/schema_service/client.rb +18 -10
  45. data/lib/google/cloud/discovery_engine/v1beta/schema_service/operations.rb +13 -5
  46. data/lib/google/cloud/discovery_engine/v1beta/schema_service/rest/client.rb +18 -10
  47. data/lib/google/cloud/discovery_engine/v1beta/schema_service/rest/operations.rb +21 -6
  48. data/lib/google/cloud/discovery_engine/v1beta/search_service/client.rb +15 -8
  49. data/lib/google/cloud/discovery_engine/v1beta/search_service/rest/client.rb +15 -8
  50. data/lib/google/cloud/discovery_engine/v1beta/search_tuning_service/client.rb +104 -2
  51. data/lib/google/cloud/discovery_engine/v1beta/search_tuning_service/operations.rb +13 -5
  52. data/lib/google/cloud/discovery_engine/v1beta/search_tuning_service/rest/client.rb +97 -2
  53. data/lib/google/cloud/discovery_engine/v1beta/search_tuning_service/rest/operations.rb +21 -6
  54. data/lib/google/cloud/discovery_engine/v1beta/search_tuning_service/rest/service_stub.rb +59 -0
  55. data/lib/google/cloud/discovery_engine/v1beta/serving_config_service/client.rb +9 -3
  56. data/lib/google/cloud/discovery_engine/v1beta/serving_config_service/rest/client.rb +9 -3
  57. data/lib/google/cloud/discovery_engine/v1beta/site_search_engine_service/client.rb +27 -12
  58. data/lib/google/cloud/discovery_engine/v1beta/site_search_engine_service/operations.rb +13 -5
  59. data/lib/google/cloud/discovery_engine/v1beta/site_search_engine_service/rest/client.rb +27 -12
  60. data/lib/google/cloud/discovery_engine/v1beta/site_search_engine_service/rest/operations.rb +21 -6
  61. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/client.rb +23 -6
  62. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/operations.rb +13 -5
  63. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/paths.rb +21 -0
  64. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/rest/client.rb +23 -6
  65. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/rest/operations.rb +21 -6
  66. data/lib/google/cloud/discovery_engine/v1beta/user_event_service/rest/service_stub.rb +8 -0
  67. data/lib/google/cloud/discovery_engine/v1beta/version.rb +1 -1
  68. data/lib/google/cloud/discovery_engine/v1beta.rb +2 -0
  69. data/lib/google/cloud/discoveryengine/v1beta/answer_pb.rb +3 -1
  70. data/lib/google/cloud/discoveryengine/v1beta/common_pb.rb +2 -1
  71. data/lib/google/cloud/discoveryengine/v1beta/control_pb.rb +55 -0
  72. data/lib/google/cloud/discoveryengine/v1beta/control_service_pb.rb +57 -0
  73. data/lib/google/cloud/discoveryengine/v1beta/control_service_services_pb.rb +69 -0
  74. data/lib/google/cloud/discoveryengine/v1beta/conversational_search_service_pb.rb +1 -1
  75. data/lib/google/cloud/discoveryengine/v1beta/custom_tuning_model_pb.rb +48 -0
  76. data/lib/google/cloud/discoveryengine/v1beta/document_service_services_pb.rb +1 -1
  77. data/lib/google/cloud/discoveryengine/v1beta/engine_pb.rb +1 -1
  78. data/lib/google/cloud/discoveryengine/v1beta/grounded_generation_service_pb.rb +1 -1
  79. data/lib/google/cloud/discoveryengine/v1beta/grounding_pb.rb +1 -1
  80. data/lib/google/cloud/discoveryengine/v1beta/project_pb.rb +49 -0
  81. data/lib/google/cloud/discoveryengine/v1beta/project_service_pb.rb +50 -0
  82. data/lib/google/cloud/discoveryengine/v1beta/project_service_services_pb.rb +51 -0
  83. data/lib/google/cloud/discoveryengine/v1beta/rank_service_pb.rb +1 -1
  84. data/lib/google/cloud/discoveryengine/v1beta/search_tuning_service_pb.rb +5 -1
  85. data/lib/google/cloud/discoveryengine/v1beta/search_tuning_service_services_pb.rb +2 -0
  86. data/lib/google/cloud/discoveryengine/v1beta/site_search_engine_pb.rb +1 -1
  87. data/lib/google/cloud/discoveryengine/v1beta/user_event_pb.rb +1 -1
  88. data/lib/google/cloud/discoveryengine/v1beta/user_event_service_pb.rb +1 -1
  89. data/lib/google/cloud/discoveryengine/v1beta/user_event_service_services_pb.rb +1 -1
  90. data/proto_docs/google/cloud/discoveryengine/v1beta/answer.rb +9 -1
  91. data/proto_docs/google/cloud/discoveryengine/v1beta/common.rb +16 -0
  92. data/proto_docs/google/cloud/discoveryengine/v1beta/control.rb +209 -0
  93. data/proto_docs/google/cloud/discoveryengine/v1beta/control_service.rb +126 -0
  94. data/proto_docs/google/cloud/discoveryengine/v1beta/conversation.rb +2 -2
  95. data/proto_docs/google/cloud/discoveryengine/v1beta/conversational_search_service.rb +19 -3
  96. data/proto_docs/google/cloud/discoveryengine/v1beta/custom_tuning_model.rb +75 -0
  97. data/proto_docs/google/cloud/discoveryengine/v1beta/data_store_service.rb +2 -2
  98. data/proto_docs/google/cloud/discoveryengine/v1beta/document_processing_config.rb +1 -0
  99. data/proto_docs/google/cloud/discoveryengine/v1beta/document_service.rb +6 -7
  100. data/proto_docs/google/cloud/discoveryengine/v1beta/engine.rb +3 -3
  101. data/proto_docs/google/cloud/discoveryengine/v1beta/grounded_generation_service.rb +39 -1
  102. data/proto_docs/google/cloud/discoveryengine/v1beta/grounding.rb +3 -0
  103. data/proto_docs/google/cloud/discoveryengine/v1beta/import_config.rb +4 -4
  104. data/proto_docs/google/cloud/discoveryengine/v1beta/project.rb +106 -0
  105. data/proto_docs/google/cloud/discoveryengine/v1beta/project_service.rb +57 -0
  106. data/proto_docs/google/cloud/discoveryengine/v1beta/rank_service.rb +28 -0
  107. data/proto_docs/google/cloud/discoveryengine/v1beta/recommendation_service.rb +20 -19
  108. data/proto_docs/google/cloud/discoveryengine/v1beta/schema_service.rb +5 -5
  109. data/proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb +30 -24
  110. data/proto_docs/google/cloud/discoveryengine/v1beta/search_tuning_service.rb +31 -0
  111. data/proto_docs/google/cloud/discoveryengine/v1beta/session.rb +4 -1
  112. data/proto_docs/google/cloud/discoveryengine/v1beta/site_search_engine.rb +3 -0
  113. data/proto_docs/google/cloud/discoveryengine/v1beta/user_event.rb +24 -3
  114. data/proto_docs/google/cloud/discoveryengine/v1beta/user_event_service.rb +13 -1
  115. metadata +30 -2
@@ -31,6 +31,9 @@ module Google
31
31
  # Service for managing site search related resources.
32
32
  #
33
33
  class Client
34
+ # @private
35
+ API_VERSION = ""
36
+
34
37
  # @private
35
38
  DEFAULT_ENDPOINT_TEMPLATE = "discoveryengine.$UNIVERSE_DOMAIN$"
36
39
 
@@ -252,10 +255,11 @@ module Google
252
255
  # Customize the options with defaults
253
256
  metadata = @config.rpcs.get_site_search_engine.metadata.to_h
254
257
 
255
- # Set x-goog-api-client and x-goog-user-project headers
258
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
256
259
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
257
260
  lib_name: @config.lib_name, lib_version: @config.lib_version,
258
261
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
262
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
259
263
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
260
264
 
261
265
  header_params = {}
@@ -349,10 +353,11 @@ module Google
349
353
  # Customize the options with defaults
350
354
  metadata = @config.rpcs.create_target_site.metadata.to_h
351
355
 
352
- # Set x-goog-api-client and x-goog-user-project headers
356
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
353
357
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
354
358
  lib_name: @config.lib_name, lib_version: @config.lib_version,
355
359
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
360
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
356
361
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
357
362
 
358
363
  header_params = {}
@@ -449,10 +454,11 @@ module Google
449
454
  # Customize the options with defaults
450
455
  metadata = @config.rpcs.batch_create_target_sites.metadata.to_h
451
456
 
452
- # Set x-goog-api-client and x-goog-user-project headers
457
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
453
458
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
454
459
  lib_name: @config.lib_name, lib_version: @config.lib_version,
455
460
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
461
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
456
462
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
457
463
 
458
464
  header_params = {}
@@ -545,10 +551,11 @@ module Google
545
551
  # Customize the options with defaults
546
552
  metadata = @config.rpcs.get_target_site.metadata.to_h
547
553
 
548
- # Set x-goog-api-client and x-goog-user-project headers
554
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
549
555
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
550
556
  lib_name: @config.lib_name, lib_version: @config.lib_version,
551
557
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
558
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
552
559
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
553
560
 
554
561
  header_params = {}
@@ -643,10 +650,11 @@ module Google
643
650
  # Customize the options with defaults
644
651
  metadata = @config.rpcs.update_target_site.metadata.to_h
645
652
 
646
- # Set x-goog-api-client and x-goog-user-project headers
653
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
647
654
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
648
655
  lib_name: @config.lib_name, lib_version: @config.lib_version,
649
656
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
657
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
650
658
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
651
659
 
652
660
  header_params = {}
@@ -746,10 +754,11 @@ module Google
746
754
  # Customize the options with defaults
747
755
  metadata = @config.rpcs.delete_target_site.metadata.to_h
748
756
 
749
- # Set x-goog-api-client and x-goog-user-project headers
757
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
750
758
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
751
759
  lib_name: @config.lib_name, lib_version: @config.lib_version,
752
760
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
761
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
753
762
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
754
763
 
755
764
  header_params = {}
@@ -855,10 +864,11 @@ module Google
855
864
  # Customize the options with defaults
856
865
  metadata = @config.rpcs.list_target_sites.metadata.to_h
857
866
 
858
- # Set x-goog-api-client and x-goog-user-project headers
867
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
859
868
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
860
869
  lib_name: @config.lib_name, lib_version: @config.lib_version,
861
870
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
871
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
862
872
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
863
873
 
864
874
  header_params = {}
@@ -951,10 +961,11 @@ module Google
951
961
  # Customize the options with defaults
952
962
  metadata = @config.rpcs.enable_advanced_site_search.metadata.to_h
953
963
 
954
- # Set x-goog-api-client and x-goog-user-project headers
964
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
955
965
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
956
966
  lib_name: @config.lib_name, lib_version: @config.lib_version,
957
967
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
968
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
958
969
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
959
970
 
960
971
  header_params = {}
@@ -1047,10 +1058,11 @@ module Google
1047
1058
  # Customize the options with defaults
1048
1059
  metadata = @config.rpcs.disable_advanced_site_search.metadata.to_h
1049
1060
 
1050
- # Set x-goog-api-client and x-goog-user-project headers
1061
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1051
1062
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1052
1063
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1053
1064
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
1065
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1054
1066
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1055
1067
 
1056
1068
  header_params = {}
@@ -1148,10 +1160,11 @@ module Google
1148
1160
  # Customize the options with defaults
1149
1161
  metadata = @config.rpcs.recrawl_uris.metadata.to_h
1150
1162
 
1151
- # Set x-goog-api-client and x-goog-user-project headers
1163
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1152
1164
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1153
1165
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1154
1166
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
1167
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1155
1168
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1156
1169
 
1157
1170
  header_params = {}
@@ -1244,10 +1257,11 @@ module Google
1244
1257
  # Customize the options with defaults
1245
1258
  metadata = @config.rpcs.batch_verify_target_sites.metadata.to_h
1246
1259
 
1247
- # Set x-goog-api-client and x-goog-user-project headers
1260
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1248
1261
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1249
1262
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1250
1263
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
1264
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1251
1265
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1252
1266
 
1253
1267
  header_params = {}
@@ -1351,10 +1365,11 @@ module Google
1351
1365
  # Customize the options with defaults
1352
1366
  metadata = @config.rpcs.fetch_domain_verification_status.metadata.to_h
1353
1367
 
1354
- # Set x-goog-api-client and x-goog-user-project headers
1368
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1355
1369
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1356
1370
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1357
1371
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
1372
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1358
1373
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1359
1374
 
1360
1375
  header_params = {}
@@ -26,6 +26,9 @@ module Google
26
26
  module SiteSearchEngineService
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 = "discoveryengine.$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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 managing site search related resources.
34
34
  #
35
35
  class Client
36
+ # @private
37
+ API_VERSION = ""
38
+
36
39
  # @private
37
40
  DEFAULT_ENDPOINT_TEMPLATE = "discoveryengine.$UNIVERSE_DOMAIN$"
38
41
 
@@ -244,12 +247,13 @@ module Google
244
247
  # Customize the options with defaults
245
248
  call_metadata = @config.rpcs.get_site_search_engine.metadata.to_h
246
249
 
247
- # Set x-goog-api-client and x-goog-user-project headers
250
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
248
251
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
249
252
  lib_name: @config.lib_name, lib_version: @config.lib_version,
250
253
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
251
254
  transports_version_send: [:rest]
252
255
 
256
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
253
257
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
254
258
 
255
259
  options.apply_defaults timeout: @config.rpcs.get_site_search_engine.timeout,
@@ -334,12 +338,13 @@ module Google
334
338
  # Customize the options with defaults
335
339
  call_metadata = @config.rpcs.create_target_site.metadata.to_h
336
340
 
337
- # Set x-goog-api-client and x-goog-user-project headers
341
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
338
342
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
339
343
  lib_name: @config.lib_name, lib_version: @config.lib_version,
340
344
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
341
345
  transports_version_send: [:rest]
342
346
 
347
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
343
348
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
344
349
 
345
350
  options.apply_defaults timeout: @config.rpcs.create_target_site.timeout,
@@ -427,12 +432,13 @@ module Google
427
432
  # Customize the options with defaults
428
433
  call_metadata = @config.rpcs.batch_create_target_sites.metadata.to_h
429
434
 
430
- # Set x-goog-api-client and x-goog-user-project headers
435
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
431
436
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
432
437
  lib_name: @config.lib_name, lib_version: @config.lib_version,
433
438
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
434
439
  transports_version_send: [:rest]
435
440
 
441
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
436
442
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
437
443
 
438
444
  options.apply_defaults timeout: @config.rpcs.batch_create_target_sites.timeout,
@@ -516,12 +522,13 @@ module Google
516
522
  # Customize the options with defaults
517
523
  call_metadata = @config.rpcs.get_target_site.metadata.to_h
518
524
 
519
- # Set x-goog-api-client and x-goog-user-project headers
525
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
520
526
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
521
527
  lib_name: @config.lib_name, lib_version: @config.lib_version,
522
528
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
523
529
  transports_version_send: [:rest]
524
530
 
531
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
525
532
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
526
533
 
527
534
  options.apply_defaults timeout: @config.rpcs.get_target_site.timeout,
@@ -607,12 +614,13 @@ module Google
607
614
  # Customize the options with defaults
608
615
  call_metadata = @config.rpcs.update_target_site.metadata.to_h
609
616
 
610
- # Set x-goog-api-client and x-goog-user-project headers
617
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
611
618
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
612
619
  lib_name: @config.lib_name, lib_version: @config.lib_version,
613
620
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
614
621
  transports_version_send: [:rest]
615
622
 
623
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
616
624
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
617
625
 
618
626
  options.apply_defaults timeout: @config.rpcs.update_target_site.timeout,
@@ -703,12 +711,13 @@ module Google
703
711
  # Customize the options with defaults
704
712
  call_metadata = @config.rpcs.delete_target_site.metadata.to_h
705
713
 
706
- # Set x-goog-api-client and x-goog-user-project headers
714
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
707
715
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
708
716
  lib_name: @config.lib_name, lib_version: @config.lib_version,
709
717
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
710
718
  transports_version_send: [:rest]
711
719
 
720
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
712
721
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
713
722
 
714
723
  options.apply_defaults timeout: @config.rpcs.delete_target_site.timeout,
@@ -805,12 +814,13 @@ module Google
805
814
  # Customize the options with defaults
806
815
  call_metadata = @config.rpcs.list_target_sites.metadata.to_h
807
816
 
808
- # Set x-goog-api-client and x-goog-user-project headers
817
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
809
818
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
810
819
  lib_name: @config.lib_name, lib_version: @config.lib_version,
811
820
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
812
821
  transports_version_send: [:rest]
813
822
 
823
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
814
824
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
815
825
 
816
826
  options.apply_defaults timeout: @config.rpcs.list_target_sites.timeout,
@@ -894,12 +904,13 @@ module Google
894
904
  # Customize the options with defaults
895
905
  call_metadata = @config.rpcs.enable_advanced_site_search.metadata.to_h
896
906
 
897
- # Set x-goog-api-client and x-goog-user-project headers
907
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
898
908
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
899
909
  lib_name: @config.lib_name, lib_version: @config.lib_version,
900
910
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
901
911
  transports_version_send: [:rest]
902
912
 
913
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
903
914
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
904
915
 
905
916
  options.apply_defaults timeout: @config.rpcs.enable_advanced_site_search.timeout,
@@ -983,12 +994,13 @@ module Google
983
994
  # Customize the options with defaults
984
995
  call_metadata = @config.rpcs.disable_advanced_site_search.metadata.to_h
985
996
 
986
- # Set x-goog-api-client and x-goog-user-project headers
997
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
987
998
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
988
999
  lib_name: @config.lib_name, lib_version: @config.lib_version,
989
1000
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
990
1001
  transports_version_send: [:rest]
991
1002
 
1003
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
992
1004
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
993
1005
 
994
1006
  options.apply_defaults timeout: @config.rpcs.disable_advanced_site_search.timeout,
@@ -1077,12 +1089,13 @@ module Google
1077
1089
  # Customize the options with defaults
1078
1090
  call_metadata = @config.rpcs.recrawl_uris.metadata.to_h
1079
1091
 
1080
- # Set x-goog-api-client and x-goog-user-project headers
1092
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1081
1093
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1082
1094
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1083
1095
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
1084
1096
  transports_version_send: [:rest]
1085
1097
 
1098
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1086
1099
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1087
1100
 
1088
1101
  options.apply_defaults timeout: @config.rpcs.recrawl_uris.timeout,
@@ -1166,12 +1179,13 @@ module Google
1166
1179
  # Customize the options with defaults
1167
1180
  call_metadata = @config.rpcs.batch_verify_target_sites.metadata.to_h
1168
1181
 
1169
- # Set x-goog-api-client and x-goog-user-project headers
1182
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1170
1183
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1171
1184
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1172
1185
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
1173
1186
  transports_version_send: [:rest]
1174
1187
 
1188
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1175
1189
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1176
1190
 
1177
1191
  options.apply_defaults timeout: @config.rpcs.batch_verify_target_sites.timeout,
@@ -1266,12 +1280,13 @@ module Google
1266
1280
  # Customize the options with defaults
1267
1281
  call_metadata = @config.rpcs.fetch_domain_verification_status.metadata.to_h
1268
1282
 
1269
- # Set x-goog-api-client and x-goog-user-project headers
1283
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1270
1284
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1271
1285
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1272
1286
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION,
1273
1287
  transports_version_send: [:rest]
1274
1288
 
1289
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1275
1290
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1276
1291
 
1277
1292
  options.apply_defaults timeout: @config.rpcs.fetch_domain_verification_status.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 = "discoveryengine.$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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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 and x-goog-user-project headers
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::DiscoveryEngine::V1beta::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,
@@ -1060,10 +1067,18 @@ module Google
1060
1067
  transcoder = Gapic::Rest::GrpcTranscoder.new
1061
1068
  .with_bindings(
1062
1069
  uri_method: :post,
1063
- uri_template: "/v1/{name}:cancel",
1070
+ uri_template: "/v1beta/{name}:cancel",
1064
1071
  body: "*",
1065
1072
  matches: [
1066
- ["name", %r{^operations(?:/.*)?$}, true]
1073
+ ["name", %r{^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+/?$}, false]
1074
+ ]
1075
+ )
1076
+ .with_bindings(
1077
+ uri_method: :post,
1078
+ uri_template: "/v1beta/{name}:cancel",
1079
+ body: "*",
1080
+ matches: [
1081
+ ["name", %r{^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+/?$}, false]
1067
1082
  ]
1068
1083
  )
1069
1084
  transcoder.transcode request_pb
@@ -31,6 +31,9 @@ module Google
31
31
  # Service for ingesting end user actions on a website to Discovery Engine API.
32
32
  #
33
33
  class Client
34
+ # @private
35
+ API_VERSION = ""
36
+
34
37
  # @private
35
38
  DEFAULT_ENDPOINT_TEMPLATE = "discoveryengine.$UNIVERSE_DOMAIN$"
36
39
 
@@ -212,16 +215,27 @@ module Google
212
215
  # @param options [::Gapic::CallOptions, ::Hash]
213
216
  # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
214
217
  #
215
- # @overload write_user_event(parent: nil, user_event: nil)
218
+ # @overload write_user_event(parent: nil, user_event: nil, write_async: nil)
216
219
  # Pass arguments to `write_user_event` via keyword arguments. Note that at
217
220
  # least one keyword argument is required. To specify no parameters, or to keep all
218
221
  # the default parameter values, pass an empty Hash as a request object (see above).
219
222
  #
220
223
  # @param parent [::String]
221
- # Required. The parent DataStore resource name, such as
224
+ # Required. The parent resource name.
225
+ # If the write user event action is applied in
226
+ # {::Google::Cloud::DiscoveryEngine::V1beta::DataStore DataStore} level, the
227
+ # format is:
222
228
  # `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.
229
+ # If the write user event action is applied in [Location][] level, for
230
+ # example, the event with
231
+ # {::Google::Cloud::DiscoveryEngine::V1beta::Document Document} across multiple
232
+ # {::Google::Cloud::DiscoveryEngine::V1beta::DataStore DataStore}, the format is:
233
+ # `projects/{project}/locations/{location}`.
223
234
  # @param user_event [::Google::Cloud::DiscoveryEngine::V1beta::UserEvent, ::Hash]
224
235
  # Required. User event to write.
236
+ # @param write_async [::Boolean]
237
+ # If set to true, the user event is written asynchronously after
238
+ # validation, and the API responds without waiting for the write.
225
239
  #
226
240
  # @yield [response, operation] Access the result along with the RPC operation
227
241
  # @yieldparam response [::Google::Cloud::DiscoveryEngine::V1beta::UserEvent]
@@ -257,10 +271,11 @@ module Google
257
271
  # Customize the options with defaults
258
272
  metadata = @config.rpcs.write_user_event.metadata.to_h
259
273
 
260
- # Set x-goog-api-client and x-goog-user-project headers
274
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
261
275
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
262
276
  lib_name: @config.lib_name, lib_version: @config.lib_version,
263
277
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
278
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
264
279
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
265
280
 
266
281
  header_params = {}
@@ -359,10 +374,11 @@ module Google
359
374
  # Customize the options with defaults
360
375
  metadata = @config.rpcs.collect_user_event.metadata.to_h
361
376
 
362
- # Set x-goog-api-client and x-goog-user-project headers
377
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
363
378
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
364
379
  lib_name: @config.lib_name, lib_version: @config.lib_version,
365
380
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
381
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
366
382
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
367
383
 
368
384
  header_params = {}
@@ -390,7 +406,7 @@ module Google
390
406
  end
391
407
 
392
408
  ##
393
- # Bulk import of User events. Request processing might be
409
+ # Bulk import of user events. Request processing might be
394
410
  # synchronous. Events that already exist are skipped.
395
411
  # Use this method for backfilling historical user events.
396
412
  #
@@ -467,10 +483,11 @@ module Google
467
483
  # Customize the options with defaults
468
484
  metadata = @config.rpcs.import_user_events.metadata.to_h
469
485
 
470
- # Set x-goog-api-client and x-goog-user-project headers
486
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
471
487
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
472
488
  lib_name: @config.lib_name, lib_version: @config.lib_version,
473
489
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1beta::VERSION
490
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
474
491
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
475
492
 
476
493
  header_params = {}