google-cloud-discovery_engine-v1 0.6.0 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (139) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/discovery_engine/v1/completion_service/client.rb +9 -3
  3. data/lib/google/cloud/discovery_engine/v1/completion_service/operations.rb +13 -5
  4. data/lib/google/cloud/discovery_engine/v1/completion_service/rest/client.rb +9 -3
  5. data/lib/google/cloud/discovery_engine/v1/completion_service/rest/operations.rb +28 -5
  6. data/lib/google/cloud/discovery_engine/v1/control_service/client.rb +875 -0
  7. data/lib/google/cloud/discovery_engine/v1/control_service/credentials.rb +47 -0
  8. data/lib/google/cloud/discovery_engine/v1/control_service/paths.rb +167 -0
  9. data/lib/google/cloud/discovery_engine/v1/control_service/rest/client.rb +814 -0
  10. data/lib/google/cloud/discovery_engine/v1/control_service/rest/service_stub.rb +440 -0
  11. data/lib/google/cloud/discovery_engine/v1/control_service/rest.rb +55 -0
  12. data/lib/google/cloud/discovery_engine/v1/control_service.rb +58 -0
  13. data/lib/google/cloud/discovery_engine/v1/conversational_search_service/client.rb +769 -7
  14. data/lib/google/cloud/discovery_engine/v1/conversational_search_service/paths.rb +199 -0
  15. data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/client.rb +720 -7
  16. data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/service_stub.rb +520 -0
  17. data/lib/google/cloud/discovery_engine/v1/data_store_service/client.rb +15 -7
  18. data/lib/google/cloud/discovery_engine/v1/data_store_service/operations.rb +13 -5
  19. data/lib/google/cloud/discovery_engine/v1/data_store_service/paths.rb +94 -0
  20. data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/client.rb +15 -7
  21. data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/operations.rb +28 -5
  22. data/lib/google/cloud/discovery_engine/v1/document_service/client.rb +71 -33
  23. data/lib/google/cloud/discovery_engine/v1/document_service/operations.rb +13 -5
  24. data/lib/google/cloud/discovery_engine/v1/document_service/paths.rb +21 -0
  25. data/lib/google/cloud/discovery_engine/v1/document_service/rest/client.rb +71 -33
  26. data/lib/google/cloud/discovery_engine/v1/document_service/rest/operations.rb +28 -5
  27. data/lib/google/cloud/discovery_engine/v1/engine_service/client.rb +13 -5
  28. data/lib/google/cloud/discovery_engine/v1/engine_service/operations.rb +13 -5
  29. data/lib/google/cloud/discovery_engine/v1/engine_service/rest/client.rb +13 -5
  30. data/lib/google/cloud/discovery_engine/v1/engine_service/rest/operations.rb +28 -5
  31. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/client.rb +471 -0
  32. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/credentials.rb +47 -0
  33. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/paths.rb +52 -0
  34. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest/client.rb +438 -0
  35. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest/service_stub.rb +129 -0
  36. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest.rb +52 -0
  37. data/lib/google/cloud/discovery_engine/v1/grounded_generation_service.rb +55 -0
  38. data/lib/google/cloud/discovery_engine/v1/project_service/client.rb +485 -0
  39. data/lib/google/cloud/discovery_engine/v1/project_service/credentials.rb +47 -0
  40. data/lib/google/cloud/discovery_engine/v1/project_service/operations.rb +809 -0
  41. data/lib/google/cloud/discovery_engine/v1/project_service/paths.rb +47 -0
  42. data/lib/google/cloud/discovery_engine/v1/project_service/rest/client.rb +452 -0
  43. data/lib/google/cloud/discovery_engine/v1/project_service/rest/operations.rb +1114 -0
  44. data/lib/google/cloud/discovery_engine/v1/project_service/rest/service_stub.rb +129 -0
  45. data/lib/google/cloud/discovery_engine/v1/project_service/rest.rb +54 -0
  46. data/lib/google/cloud/discovery_engine/v1/project_service.rb +57 -0
  47. data/lib/google/cloud/discovery_engine/v1/rank_service/client.rb +481 -0
  48. data/lib/google/cloud/discovery_engine/v1/rank_service/credentials.rb +47 -0
  49. data/lib/google/cloud/discovery_engine/v1/rank_service/paths.rb +52 -0
  50. data/lib/google/cloud/discovery_engine/v1/rank_service/rest/client.rb +448 -0
  51. data/lib/google/cloud/discovery_engine/v1/rank_service/rest/service_stub.rb +129 -0
  52. data/lib/google/cloud/discovery_engine/v1/rank_service/rest.rb +52 -0
  53. data/lib/google/cloud/discovery_engine/v1/rank_service.rb +55 -0
  54. data/lib/google/cloud/discovery_engine/v1/recommendation_service/client.rb +558 -0
  55. data/lib/google/cloud/discovery_engine/v1/recommendation_service/credentials.rb +47 -0
  56. data/lib/google/cloud/discovery_engine/v1/recommendation_service/paths.rb +220 -0
  57. data/lib/google/cloud/discovery_engine/v1/recommendation_service/rest/client.rb +525 -0
  58. data/lib/google/cloud/discovery_engine/v1/recommendation_service/rest/service_stub.rb +145 -0
  59. data/lib/google/cloud/discovery_engine/v1/recommendation_service/rest.rb +52 -0
  60. data/lib/google/cloud/discovery_engine/v1/recommendation_service.rb +55 -0
  61. data/lib/google/cloud/discovery_engine/v1/rest.rb +5 -0
  62. data/lib/google/cloud/discovery_engine/v1/schema_service/client.rb +18 -10
  63. data/lib/google/cloud/discovery_engine/v1/schema_service/operations.rb +13 -5
  64. data/lib/google/cloud/discovery_engine/v1/schema_service/rest/client.rb +18 -10
  65. data/lib/google/cloud/discovery_engine/v1/schema_service/rest/operations.rb +28 -5
  66. data/lib/google/cloud/discovery_engine/v1/search_service/client.rb +26 -13
  67. data/lib/google/cloud/discovery_engine/v1/search_service/paths.rb +45 -0
  68. data/lib/google/cloud/discovery_engine/v1/search_service/rest/client.rb +26 -13
  69. data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/client.rb +27 -12
  70. data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/operations.rb +13 -5
  71. data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/client.rb +27 -12
  72. data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/operations.rb +28 -5
  73. data/lib/google/cloud/discovery_engine/v1/user_event_service/client.rb +23 -6
  74. data/lib/google/cloud/discovery_engine/v1/user_event_service/operations.rb +13 -5
  75. data/lib/google/cloud/discovery_engine/v1/user_event_service/paths.rb +21 -0
  76. data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/client.rb +23 -6
  77. data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/operations.rb +28 -5
  78. data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/service_stub.rb +8 -0
  79. data/lib/google/cloud/discovery_engine/v1/version.rb +1 -1
  80. data/lib/google/cloud/discovery_engine/v1.rb +5 -0
  81. data/lib/google/cloud/discoveryengine/v1/answer_pb.rb +69 -0
  82. data/lib/google/cloud/discoveryengine/v1/common_pb.rb +2 -1
  83. data/lib/google/cloud/discoveryengine/v1/control_pb.rb +55 -0
  84. data/lib/google/cloud/discoveryengine/v1/control_service_pb.rb +57 -0
  85. data/lib/google/cloud/discoveryengine/v1/control_service_services_pb.rb +69 -0
  86. data/lib/google/cloud/discoveryengine/v1/conversational_search_service_pb.rb +32 -1
  87. data/lib/google/cloud/discoveryengine/v1/conversational_search_service_services_pb.rb +25 -0
  88. data/lib/google/cloud/discoveryengine/v1/data_store_pb.rb +5 -1
  89. data/lib/google/cloud/discoveryengine/v1/document_pb.rb +3 -1
  90. data/lib/google/cloud/discoveryengine/v1/document_processing_config_pb.rb +48 -0
  91. data/lib/google/cloud/discoveryengine/v1/document_service_pb.rb +3 -1
  92. data/lib/google/cloud/discoveryengine/v1/document_service_services_pb.rb +1 -1
  93. data/lib/google/cloud/discoveryengine/v1/engine_pb.rb +1 -1
  94. data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_pb.rb +52 -0
  95. data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_services_pb.rb +45 -0
  96. data/lib/google/cloud/discoveryengine/v1/grounding_pb.rb +46 -0
  97. data/lib/google/cloud/discoveryengine/v1/import_config_pb.rb +13 -1
  98. data/lib/google/cloud/discoveryengine/v1/project_pb.rb +49 -0
  99. data/lib/google/cloud/discoveryengine/v1/project_service_pb.rb +50 -0
  100. data/lib/google/cloud/discoveryengine/v1/project_service_services_pb.rb +51 -0
  101. data/lib/google/cloud/discoveryengine/v1/purge_config_pb.rb +1 -1
  102. data/lib/google/cloud/discoveryengine/v1/rank_service_pb.rb +49 -0
  103. data/lib/google/cloud/discoveryengine/v1/rank_service_services_pb.rb +45 -0
  104. data/lib/google/cloud/discoveryengine/v1/recommendation_service_pb.rb +55 -0
  105. data/lib/google/cloud/discoveryengine/v1/recommendation_service_services_pb.rb +45 -0
  106. data/lib/google/cloud/discoveryengine/v1/search_service_pb.rb +4 -1
  107. data/lib/google/cloud/discoveryengine/v1/session_pb.rb +50 -0
  108. data/lib/google/cloud/discoveryengine/v1/site_search_engine_pb.rb +1 -1
  109. data/lib/google/cloud/discoveryengine/v1/user_event_pb.rb +1 -1
  110. data/lib/google/cloud/discoveryengine/v1/user_event_service_pb.rb +1 -1
  111. data/lib/google/cloud/discoveryengine/v1/user_event_service_services_pb.rb +1 -1
  112. data/proto_docs/google/api/client.rb +4 -0
  113. data/proto_docs/google/cloud/discoveryengine/v1/answer.rb +362 -0
  114. data/proto_docs/google/cloud/discoveryengine/v1/common.rb +25 -1
  115. data/proto_docs/google/cloud/discoveryengine/v1/control.rb +207 -0
  116. data/proto_docs/google/cloud/discoveryengine/v1/control_service.rb +126 -0
  117. data/proto_docs/google/cloud/discoveryengine/v1/conversation.rb +2 -2
  118. data/proto_docs/google/cloud/discoveryengine/v1/conversational_search_service.rb +490 -0
  119. data/proto_docs/google/cloud/discoveryengine/v1/data_store.rb +19 -0
  120. data/proto_docs/google/cloud/discoveryengine/v1/data_store_service.rb +2 -2
  121. data/proto_docs/google/cloud/discoveryengine/v1/document.rb +7 -0
  122. data/proto_docs/google/cloud/discoveryengine/v1/document_processing_config.rb +102 -0
  123. data/proto_docs/google/cloud/discoveryengine/v1/document_service.rb +8 -4
  124. data/proto_docs/google/cloud/discoveryengine/v1/engine.rb +5 -5
  125. data/proto_docs/google/cloud/discoveryengine/v1/grounded_generation_service.rb +144 -0
  126. data/proto_docs/google/cloud/discoveryengine/v1/grounding.rb +79 -0
  127. data/proto_docs/google/cloud/discoveryengine/v1/import_config.rb +313 -24
  128. data/proto_docs/google/cloud/discoveryengine/v1/project.rb +106 -0
  129. data/proto_docs/google/cloud/discoveryengine/v1/project_service.rb +57 -0
  130. data/proto_docs/google/cloud/discoveryengine/v1/purge_config.rb +3 -0
  131. data/proto_docs/google/cloud/discoveryengine/v1/rank_service.rb +124 -0
  132. data/proto_docs/google/cloud/discoveryengine/v1/recommendation_service.rb +229 -0
  133. data/proto_docs/google/cloud/discoveryengine/v1/schema_service.rb +5 -5
  134. data/proto_docs/google/cloud/discoveryengine/v1/search_service.rb +150 -37
  135. data/proto_docs/google/cloud/discoveryengine/v1/session.rb +88 -0
  136. data/proto_docs/google/cloud/discoveryengine/v1/site_search_engine.rb +3 -0
  137. data/proto_docs/google/cloud/discoveryengine/v1/user_event.rb +40 -14
  138. data/proto_docs/google/cloud/discoveryengine/v1/user_event_service.rb +13 -1
  139. metadata +66 -2
@@ -73,6 +73,51 @@ module Google
73
73
  resource.call(**args)
74
74
  end
75
75
 
76
+ ##
77
+ # Create a fully-qualified DataStore resource string.
78
+ #
79
+ # @overload data_store_path(project:, location:, data_store:)
80
+ # The resource will be in the following format:
81
+ #
82
+ # `projects/{project}/locations/{location}/dataStores/{data_store}`
83
+ #
84
+ # @param project [String]
85
+ # @param location [String]
86
+ # @param data_store [String]
87
+ #
88
+ # @overload data_store_path(project:, location:, collection:, data_store:)
89
+ # The resource will be in the following format:
90
+ #
91
+ # `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`
92
+ #
93
+ # @param project [String]
94
+ # @param location [String]
95
+ # @param collection [String]
96
+ # @param data_store [String]
97
+ #
98
+ # @return [::String]
99
+ def data_store_path **args
100
+ resources = {
101
+ "data_store:location:project" => (proc do |project:, location:, data_store:|
102
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
103
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
104
+
105
+ "projects/#{project}/locations/#{location}/dataStores/#{data_store}"
106
+ end),
107
+ "collection:data_store:location:project" => (proc do |project:, location:, collection:, data_store:|
108
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
109
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
110
+ raise ::ArgumentError, "collection cannot contain /" if collection.to_s.include? "/"
111
+
112
+ "projects/#{project}/locations/#{location}/collections/#{collection}/dataStores/#{data_store}"
113
+ end)
114
+ }
115
+
116
+ resource = resources[args.keys.sort.join(":")]
117
+ raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
118
+ resource.call(**args)
119
+ end
120
+
76
121
  ##
77
122
  # Create a fully-qualified ServingConfig resource string.
78
123
  #
@@ -33,6 +33,9 @@ module Google
33
33
  # Service for search.
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
 
@@ -70,9 +73,9 @@ module Google
70
73
  end
71
74
  default_config = Client::Configuration.new parent_config
72
75
 
73
- default_config.timeout = 5.0
76
+ default_config.timeout = 30.0
74
77
  default_config.retry_policy = {
75
- initial_delay: 0.1, max_delay: 5.0, multiplier: 1.3, retry_codes: [14]
78
+ initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
76
79
  }
77
80
 
78
81
  default_config
@@ -186,7 +189,7 @@ module Google
186
189
  # @param options [::Gapic::CallOptions, ::Hash]
187
190
  # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
188
191
  #
189
- # @overload search(serving_config: nil, branch: nil, query: nil, image_query: nil, page_size: nil, page_token: nil, offset: nil, filter: nil, canonical_filter: nil, order_by: nil, user_info: nil, facet_specs: nil, boost_spec: nil, params: nil, query_expansion_spec: nil, spell_correction_spec: nil, user_pseudo_id: nil, content_search_spec: nil, safe_search: nil, user_labels: nil)
192
+ # @overload search(serving_config: nil, branch: nil, query: nil, image_query: nil, page_size: nil, page_token: nil, offset: nil, data_store_specs: nil, filter: nil, canonical_filter: nil, order_by: nil, user_info: nil, facet_specs: nil, boost_spec: nil, params: nil, query_expansion_spec: nil, spell_correction_spec: nil, user_pseudo_id: nil, content_search_spec: nil, safe_search: nil, user_labels: nil)
190
193
  # Pass arguments to `search` via keyword arguments. Note that at
191
194
  # least one keyword argument is required. To specify no parameters, or to keep all
192
195
  # the default parameter values, pass an empty Hash as a request object (see above).
@@ -210,10 +213,14 @@ module Google
210
213
  # Raw image query.
211
214
  # @param page_size [::Integer]
212
215
  # Maximum number of {::Google::Cloud::DiscoveryEngine::V1::Document Document}s to
213
- # return. If unspecified, defaults to a reasonable value. The maximum allowed
214
- # value is 100. Values above 100 are coerced to 100.
216
+ # return. The maximum allowed value depends on the data type. Values above
217
+ # the maximum value are coerced to the maximum value.
215
218
  #
216
- # If this field is negative, an `INVALID_ARGUMENT` is returned.
219
+ # * Websites with basic indexing: Default `10`, Maximum `25`.
220
+ # * Websites with advanced indexing: Default `25`, Maximum `50`.
221
+ # * Other: Default `50`, Maximum `100`.
222
+ #
223
+ # If this field is negative, an `INVALID_ARGUMENT` is returned.
217
224
  # @param page_token [::String]
218
225
  # A page token received from a previous
219
226
  # {::Google::Cloud::DiscoveryEngine::V1::SearchService::Rest::Client#search SearchService.Search}
@@ -232,6 +239,11 @@ module Google
232
239
  # unset.
233
240
  #
234
241
  # If this field is negative, an `INVALID_ARGUMENT` is returned.
242
+ # @param data_store_specs [::Array<::Google::Cloud::DiscoveryEngine::V1::SearchRequest::DataStoreSpec, ::Hash>]
243
+ # Specs defining dataStores to filter on in a search call and configurations
244
+ # for those dataStores. This is only considered for engines with multiple
245
+ # dataStores use case. For single dataStore within an engine, they should
246
+ # use the specs at the top level.
235
247
  # @param filter [::String]
236
248
  # The filter syntax consists of an expression language for constructing a
237
249
  # predicate from one or more fields of the documents being filtered. Filter
@@ -265,7 +277,9 @@ module Google
265
277
  # The order in which documents are returned. Documents can be ordered by
266
278
  # a field in an {::Google::Cloud::DiscoveryEngine::V1::Document Document} object.
267
279
  # Leave it unset if ordered by relevance. `order_by` expression is
268
- # case-sensitive. For more information on ordering, see
280
+ # case-sensitive.
281
+ #
282
+ # For more information on ordering for retail search, see
269
283
  # [Ordering](https://cloud.google.com/retail/docs/filter-and-order#order)
270
284
  #
271
285
  # If this field is unrecognizable, an `INVALID_ARGUMENT` is returned.
@@ -282,7 +296,7 @@ module Google
282
296
  # @param boost_spec [::Google::Cloud::DiscoveryEngine::V1::SearchRequest::BoostSpec, ::Hash]
283
297
  # Boost specification to boost certain documents.
284
298
  # For more information on boosting, see
285
- # [Boosting](https://cloud.google.com/retail/docs/boosting#boost)
299
+ # [Boosting](https://cloud.google.com/generative-ai-app-builder/docs/boost-search-results)
286
300
  # @param params [::Hash{::String => ::Google::Protobuf::Value, ::Hash}]
287
301
  # Additional search parameters.
288
302
  #
@@ -290,8 +304,7 @@ module Google
290
304
  #
291
305
  # * `user_country_code`: string. Default empty. If set to non-empty, results
292
306
  # are restricted or boosted based on the location provided.
293
- # Example:
294
- # user_country_code: "au"
307
+ # For example, `user_country_code: "au"`
295
308
  #
296
309
  # For available codes see [Country
297
310
  # Codes](https://developers.google.com/custom-search/docs/json_api_reference#countryCodes)
@@ -299,8 +312,7 @@ module Google
299
312
  # * `search_type`: double. Default empty. Enables non-webpage searching
300
313
  # depending on the value. The only valid non-default value is 1,
301
314
  # which enables image searching.
302
- # Example:
303
- # search_type: 1
315
+ # For example, `search_type: 1`
304
316
  # @param query_expansion_spec [::Google::Cloud::DiscoveryEngine::V1::SearchRequest::QueryExpansionSpec, ::Hash]
305
317
  # The query expansion specification that specifies the conditions under which
306
318
  # query expansion occurs.
@@ -383,12 +395,13 @@ module Google
383
395
  # Customize the options with defaults
384
396
  call_metadata = @config.rpcs.search.metadata.to_h
385
397
 
386
- # Set x-goog-api-client and x-goog-user-project headers
398
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
387
399
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
388
400
  lib_name: @config.lib_name, lib_version: @config.lib_version,
389
401
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
390
402
  transports_version_send: [:rest]
391
403
 
404
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
392
405
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
393
406
 
394
407
  options.apply_defaults timeout: @config.rpcs.search.timeout,
@@ -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::V1::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::V1::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::V1::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 = {}
@@ -544,10 +550,11 @@ module Google
544
550
  # Customize the options with defaults
545
551
  metadata = @config.rpcs.get_target_site.metadata.to_h
546
552
 
547
- # Set x-goog-api-client and x-goog-user-project headers
553
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
548
554
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
549
555
  lib_name: @config.lib_name, lib_version: @config.lib_version,
550
556
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
557
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
551
558
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
552
559
 
553
560
  header_params = {}
@@ -642,10 +649,11 @@ module Google
642
649
  # Customize the options with defaults
643
650
  metadata = @config.rpcs.update_target_site.metadata.to_h
644
651
 
645
- # Set x-goog-api-client and x-goog-user-project headers
652
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
646
653
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
647
654
  lib_name: @config.lib_name, lib_version: @config.lib_version,
648
655
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
656
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
649
657
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
650
658
 
651
659
  header_params = {}
@@ -744,10 +752,11 @@ module Google
744
752
  # Customize the options with defaults
745
753
  metadata = @config.rpcs.delete_target_site.metadata.to_h
746
754
 
747
- # Set x-goog-api-client and x-goog-user-project headers
755
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
748
756
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
749
757
  lib_name: @config.lib_name, lib_version: @config.lib_version,
750
758
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
759
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
751
760
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
752
761
 
753
762
  header_params = {}
@@ -852,10 +861,11 @@ module Google
852
861
  # Customize the options with defaults
853
862
  metadata = @config.rpcs.list_target_sites.metadata.to_h
854
863
 
855
- # Set x-goog-api-client and x-goog-user-project headers
864
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
856
865
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
857
866
  lib_name: @config.lib_name, lib_version: @config.lib_version,
858
867
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
868
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
859
869
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
860
870
 
861
871
  header_params = {}
@@ -948,10 +958,11 @@ module Google
948
958
  # Customize the options with defaults
949
959
  metadata = @config.rpcs.enable_advanced_site_search.metadata.to_h
950
960
 
951
- # Set x-goog-api-client and x-goog-user-project headers
961
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
952
962
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
953
963
  lib_name: @config.lib_name, lib_version: @config.lib_version,
954
964
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
965
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
955
966
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
956
967
 
957
968
  header_params = {}
@@ -1044,10 +1055,11 @@ module Google
1044
1055
  # Customize the options with defaults
1045
1056
  metadata = @config.rpcs.disable_advanced_site_search.metadata.to_h
1046
1057
 
1047
- # Set x-goog-api-client and x-goog-user-project headers
1058
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1048
1059
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1049
1060
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1050
1061
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
1062
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1051
1063
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1052
1064
 
1053
1065
  header_params = {}
@@ -1144,10 +1156,11 @@ module Google
1144
1156
  # Customize the options with defaults
1145
1157
  metadata = @config.rpcs.recrawl_uris.metadata.to_h
1146
1158
 
1147
- # Set x-goog-api-client and x-goog-user-project headers
1159
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1148
1160
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1149
1161
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1150
1162
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
1163
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1151
1164
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1152
1165
 
1153
1166
  header_params = {}
@@ -1240,10 +1253,11 @@ module Google
1240
1253
  # Customize the options with defaults
1241
1254
  metadata = @config.rpcs.batch_verify_target_sites.metadata.to_h
1242
1255
 
1243
- # Set x-goog-api-client and x-goog-user-project headers
1256
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1244
1257
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1245
1258
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1246
1259
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
1260
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1247
1261
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1248
1262
 
1249
1263
  header_params = {}
@@ -1347,10 +1361,11 @@ module Google
1347
1361
  # Customize the options with defaults
1348
1362
  metadata = @config.rpcs.fetch_domain_verification_status.metadata.to_h
1349
1363
 
1350
- # Set x-goog-api-client and x-goog-user-project headers
1364
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1351
1365
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1352
1366
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1353
1367
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION
1368
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1354
1369
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1355
1370
 
1356
1371
  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::V1::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::V1::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::V1::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::V1::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::V1::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::V1::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::V1::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::V1::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,
@@ -515,12 +521,13 @@ module Google
515
521
  # Customize the options with defaults
516
522
  call_metadata = @config.rpcs.get_target_site.metadata.to_h
517
523
 
518
- # Set x-goog-api-client and x-goog-user-project headers
524
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
519
525
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
520
526
  lib_name: @config.lib_name, lib_version: @config.lib_version,
521
527
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
522
528
  transports_version_send: [:rest]
523
529
 
530
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
524
531
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
525
532
 
526
533
  options.apply_defaults timeout: @config.rpcs.get_target_site.timeout,
@@ -606,12 +613,13 @@ module Google
606
613
  # Customize the options with defaults
607
614
  call_metadata = @config.rpcs.update_target_site.metadata.to_h
608
615
 
609
- # Set x-goog-api-client and x-goog-user-project headers
616
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
610
617
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
611
618
  lib_name: @config.lib_name, lib_version: @config.lib_version,
612
619
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
613
620
  transports_version_send: [:rest]
614
621
 
622
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
615
623
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
616
624
 
617
625
  options.apply_defaults timeout: @config.rpcs.update_target_site.timeout,
@@ -701,12 +709,13 @@ module Google
701
709
  # Customize the options with defaults
702
710
  call_metadata = @config.rpcs.delete_target_site.metadata.to_h
703
711
 
704
- # Set x-goog-api-client and x-goog-user-project headers
712
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
705
713
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
706
714
  lib_name: @config.lib_name, lib_version: @config.lib_version,
707
715
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
708
716
  transports_version_send: [:rest]
709
717
 
718
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
710
719
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
711
720
 
712
721
  options.apply_defaults timeout: @config.rpcs.delete_target_site.timeout,
@@ -802,12 +811,13 @@ module Google
802
811
  # Customize the options with defaults
803
812
  call_metadata = @config.rpcs.list_target_sites.metadata.to_h
804
813
 
805
- # Set x-goog-api-client and x-goog-user-project headers
814
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
806
815
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
807
816
  lib_name: @config.lib_name, lib_version: @config.lib_version,
808
817
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
809
818
  transports_version_send: [:rest]
810
819
 
820
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
811
821
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
812
822
 
813
823
  options.apply_defaults timeout: @config.rpcs.list_target_sites.timeout,
@@ -891,12 +901,13 @@ module Google
891
901
  # Customize the options with defaults
892
902
  call_metadata = @config.rpcs.enable_advanced_site_search.metadata.to_h
893
903
 
894
- # Set x-goog-api-client and x-goog-user-project headers
904
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
895
905
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
896
906
  lib_name: @config.lib_name, lib_version: @config.lib_version,
897
907
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
898
908
  transports_version_send: [:rest]
899
909
 
910
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
900
911
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
901
912
 
902
913
  options.apply_defaults timeout: @config.rpcs.enable_advanced_site_search.timeout,
@@ -980,12 +991,13 @@ module Google
980
991
  # Customize the options with defaults
981
992
  call_metadata = @config.rpcs.disable_advanced_site_search.metadata.to_h
982
993
 
983
- # Set x-goog-api-client and x-goog-user-project headers
994
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
984
995
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
985
996
  lib_name: @config.lib_name, lib_version: @config.lib_version,
986
997
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
987
998
  transports_version_send: [:rest]
988
999
 
1000
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
989
1001
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
990
1002
 
991
1003
  options.apply_defaults timeout: @config.rpcs.disable_advanced_site_search.timeout,
@@ -1073,12 +1085,13 @@ module Google
1073
1085
  # Customize the options with defaults
1074
1086
  call_metadata = @config.rpcs.recrawl_uris.metadata.to_h
1075
1087
 
1076
- # Set x-goog-api-client and x-goog-user-project headers
1088
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1077
1089
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1078
1090
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1079
1091
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
1080
1092
  transports_version_send: [:rest]
1081
1093
 
1094
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1082
1095
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1083
1096
 
1084
1097
  options.apply_defaults timeout: @config.rpcs.recrawl_uris.timeout,
@@ -1162,12 +1175,13 @@ module Google
1162
1175
  # Customize the options with defaults
1163
1176
  call_metadata = @config.rpcs.batch_verify_target_sites.metadata.to_h
1164
1177
 
1165
- # Set x-goog-api-client and x-goog-user-project headers
1178
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1166
1179
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1167
1180
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1168
1181
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
1169
1182
  transports_version_send: [:rest]
1170
1183
 
1184
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1171
1185
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1172
1186
 
1173
1187
  options.apply_defaults timeout: @config.rpcs.batch_verify_target_sites.timeout,
@@ -1262,12 +1276,13 @@ module Google
1262
1276
  # Customize the options with defaults
1263
1277
  call_metadata = @config.rpcs.fetch_domain_verification_status.metadata.to_h
1264
1278
 
1265
- # Set x-goog-api-client and x-goog-user-project headers
1279
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1266
1280
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1267
1281
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1268
1282
  gapic_version: ::Google::Cloud::DiscoveryEngine::V1::VERSION,
1269
1283
  transports_version_send: [:rest]
1270
1284
 
1285
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1271
1286
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1272
1287
 
1273
1288
  options.apply_defaults timeout: @config.rpcs.fetch_domain_verification_status.timeout,