google-cloud-dialogflow 1.9.1 → 1.11.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1070d13c9e9f76dd374b1b2522676c4691f030b6bfb17c486c505695b343e1b6
4
- data.tar.gz: 225de54f2cf6e09c0e87aa128b72bb4fc79e5ce01c9fc653c8470d0b70e45070
3
+ metadata.gz: b912ab99fc7bc2ea024ee33b193ced65ba3f3e035f10d6d21dd132f50f51bc5d
4
+ data.tar.gz: 796a726cd2bd15ec2a661ae4c0a17e1124ef739e901357d51aefe008b97abf96
5
5
  SHA512:
6
- metadata.gz: 1680bc1010f1978f757e83f61a9ea21abc750174aa87a8582d42cdd1ec6099b9cb169c816963725756d5cc3896b71230685da6926d13c9847345956fe8a99fcf
7
- data.tar.gz: eca9c1fb74cb54d47df2cf7dba36c32415096be415682b8a879b88457b5c1232ee0389f4d3149ab050e7fc4ecbb95130d58d2efe05b7d3b873c385f316596a73
6
+ metadata.gz: d3209e324e207c845f4665189eb31a3b64964462bccb647ba1b4536ed5e6afa5135ee0fd6b90e7ad5143fdb3c5361b978a4a00276c0e421ccd927b244831f9e7
7
+ data.tar.gz: 4c2b2f8528c1b6a58c61b364bfbaef16d626de65d54a0c2e318b1b6e85b43f03b69a95165ed735a3fb5e55bfc61e8f03a90aa6a8a1595c2fff7af4b43284a864
data/README.md CHANGED
@@ -42,9 +42,39 @@ and includes substantial interface changes. Existing code written for earlier
42
42
  versions of this library will likely require updates to use this version.
43
43
  See the {file:MIGRATING.md MIGRATING.md} document for more information.
44
44
 
45
+ ## Debug Logging
46
+
47
+ This library comes with opt-in Debug Logging that can help you troubleshoot
48
+ your application's integration with the API. When logging is activated, key
49
+ events such as requests and responses, along with data payloads and metadata
50
+ such as headers and client configuration, are logged to the standard error
51
+ stream.
52
+
53
+ **WARNING:** Client Library Debug Logging includes your data payloads in
54
+ plaintext, which could include sensitive data such as PII for yourself or your
55
+ customers, private keys, or other security data that could be compromising if
56
+ leaked. Always practice good data hygiene with your application logs, and follow
57
+ the principle of least access. Google also recommends that Client Library Debug
58
+ Logging be enabled only temporarily during active debugging, and not used
59
+ permanently in production.
60
+
61
+ To enable logging, set the environment variable `GOOGLE_SDK_RUBY_LOGGING_GEMS`
62
+ to the value `all`. Alternatively, you can set the value to a comma-delimited
63
+ list of client library gem names. This will select the default logging behavior,
64
+ which writes logs to the standard error stream. On a local workstation, this may
65
+ result in logs appearing on the console. When running on a Google Cloud hosting
66
+ service such as [Google Cloud Run](https://cloud.google.com/run), this generally
67
+ results in logs appearing alongside your application logs in the
68
+ [Google Cloud Logging](https://cloud.google.com/logging/) service.
69
+
70
+ Debug logging also requires that the versioned clients for this service be
71
+ sufficiently recent, released after about Dec 10, 2024. If logging is not
72
+ working, try updating the versioned clients in your bundle or installed gems:
73
+ [google-cloud-dialogflow-v2](https://cloud.google.com/ruby/docs/reference/google-cloud-dialogflow-v2/latest).
74
+
45
75
  ## Supported Ruby Versions
46
76
 
47
- This library is supported on Ruby 2.7+.
77
+ This library is supported on Ruby 3.0+.
48
78
 
49
79
  Google provides official support for Ruby versions that are actively supported
50
80
  by Ruby Core—that is, Ruby versions that are either in normal maintenance or
@@ -16,7 +16,7 @@
16
16
  module Google
17
17
  module Cloud
18
18
  module Dialogflow
19
- VERSION = "1.9.1".freeze
19
+ VERSION = "1.11.0".freeze
20
20
  end
21
21
  end
22
22
  end
@@ -58,6 +58,11 @@ module Google
58
58
  # You can also specify a different transport by passing `:rest` or `:grpc` in
59
59
  # the `transport` parameter.
60
60
  #
61
+ # Raises an exception if the currently installed versioned client gem for the
62
+ # given API version does not support the given transport of the Agents service.
63
+ # You can determine whether the method will succeed by calling
64
+ # {Google::Cloud::Dialogflow.agents_available?}.
65
+ #
61
66
  # ## About Agents
62
67
  #
63
68
  # Service for managing Agents.
@@ -79,6 +84,111 @@ module Google
79
84
  service_module.const_get(:Client).new(&block)
80
85
  end
81
86
 
87
+ ##
88
+ # Determines whether the Agents service is supported by the current client.
89
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.agents}.
90
+ # If false, that method will raise an exception. This could happen if the given
91
+ # API version does not exist or does not support the Agents service,
92
+ # or if the versioned client gem needs an update to support the Agents service.
93
+ #
94
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
95
+ # Defaults to `:v2`.
96
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
97
+ # @return [boolean] Whether the service is available.
98
+ #
99
+ def self.agents_available? version: :v2, transport: :grpc
100
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
101
+ package_name = Google::Cloud::Dialogflow
102
+ .constants
103
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
104
+ .first
105
+ return false unless package_name
106
+ service_module = Google::Cloud::Dialogflow.const_get package_name
107
+ return false unless service_module.const_defined? :Agents
108
+ service_module = service_module.const_get :Agents
109
+ if transport == :rest
110
+ return false unless service_module.const_defined? :Rest
111
+ service_module = service_module.const_get :Rest
112
+ end
113
+ service_module.const_defined? :Client
114
+ rescue ::LoadError
115
+ false
116
+ end
117
+
118
+ ##
119
+ # Create a new client object for Generators.
120
+ #
121
+ # By default, this returns an instance of
122
+ # [Google::Cloud::Dialogflow::V2::Generators::Client](https://cloud.google.com/ruby/docs/reference/google-cloud-dialogflow-v2/latest/Google-Cloud-Dialogflow-V2-Generators-Client)
123
+ # for a gRPC client for version V2 of the API.
124
+ # However, you can specify a different API version by passing it in the
125
+ # `version` parameter. If the Generators service is
126
+ # supported by that API version, and the corresponding gem is available, the
127
+ # appropriate versioned client will be returned.
128
+ # You can also specify a different transport by passing `:rest` or `:grpc` in
129
+ # the `transport` parameter.
130
+ #
131
+ # Raises an exception if the currently installed versioned client gem for the
132
+ # given API version does not support the given transport of the Generators service.
133
+ # You can determine whether the method will succeed by calling
134
+ # {Google::Cloud::Dialogflow.generators_available?}.
135
+ #
136
+ # ## About Generators
137
+ #
138
+ # Generator Service for LLM powered Agent Assist. This service manages the
139
+ # configurations of user owned Generators, such as description, context and
140
+ # instruction, input/output format, etc. The generator resources will be used
141
+ # inside a conversation and will be triggered by TriggerEvent to query LLM for
142
+ # answers.
143
+ #
144
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
145
+ # Defaults to `:v2`.
146
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
147
+ # @return [::Object] A client object for the specified version.
148
+ #
149
+ def self.generators version: :v2, transport: :grpc, &block
150
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
151
+
152
+ package_name = Google::Cloud::Dialogflow
153
+ .constants
154
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
155
+ .first
156
+ service_module = Google::Cloud::Dialogflow.const_get(package_name).const_get(:Generators)
157
+ service_module = service_module.const_get(:Rest) if transport == :rest
158
+ service_module.const_get(:Client).new(&block)
159
+ end
160
+
161
+ ##
162
+ # Determines whether the Generators service is supported by the current client.
163
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.generators}.
164
+ # If false, that method will raise an exception. This could happen if the given
165
+ # API version does not exist or does not support the Generators service,
166
+ # or if the versioned client gem needs an update to support the Generators service.
167
+ #
168
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
169
+ # Defaults to `:v2`.
170
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
171
+ # @return [boolean] Whether the service is available.
172
+ #
173
+ def self.generators_available? version: :v2, transport: :grpc
174
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
175
+ package_name = Google::Cloud::Dialogflow
176
+ .constants
177
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
178
+ .first
179
+ return false unless package_name
180
+ service_module = Google::Cloud::Dialogflow.const_get package_name
181
+ return false unless service_module.const_defined? :Generators
182
+ service_module = service_module.const_get :Generators
183
+ if transport == :rest
184
+ return false unless service_module.const_defined? :Rest
185
+ service_module = service_module.const_get :Rest
186
+ end
187
+ service_module.const_defined? :Client
188
+ rescue ::LoadError
189
+ false
190
+ end
191
+
82
192
  ##
83
193
  # Create a new client object for Contexts.
84
194
  #
@@ -92,6 +202,11 @@ module Google
92
202
  # You can also specify a different transport by passing `:rest` or `:grpc` in
93
203
  # the `transport` parameter.
94
204
  #
205
+ # Raises an exception if the currently installed versioned client gem for the
206
+ # given API version does not support the given transport of the Contexts service.
207
+ # You can determine whether the method will succeed by calling
208
+ # {Google::Cloud::Dialogflow.contexts_available?}.
209
+ #
95
210
  # ## About Contexts
96
211
  #
97
212
  # Service for managing Contexts.
@@ -113,6 +228,37 @@ module Google
113
228
  service_module.const_get(:Client).new(&block)
114
229
  end
115
230
 
231
+ ##
232
+ # Determines whether the Contexts service is supported by the current client.
233
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.contexts}.
234
+ # If false, that method will raise an exception. This could happen if the given
235
+ # API version does not exist or does not support the Contexts service,
236
+ # or if the versioned client gem needs an update to support the Contexts service.
237
+ #
238
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
239
+ # Defaults to `:v2`.
240
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
241
+ # @return [boolean] Whether the service is available.
242
+ #
243
+ def self.contexts_available? version: :v2, transport: :grpc
244
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
245
+ package_name = Google::Cloud::Dialogflow
246
+ .constants
247
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
248
+ .first
249
+ return false unless package_name
250
+ service_module = Google::Cloud::Dialogflow.const_get package_name
251
+ return false unless service_module.const_defined? :Contexts
252
+ service_module = service_module.const_get :Contexts
253
+ if transport == :rest
254
+ return false unless service_module.const_defined? :Rest
255
+ service_module = service_module.const_get :Rest
256
+ end
257
+ service_module.const_defined? :Client
258
+ rescue ::LoadError
259
+ false
260
+ end
261
+
116
262
  ##
117
263
  # Create a new client object for Intents.
118
264
  #
@@ -126,6 +272,11 @@ module Google
126
272
  # You can also specify a different transport by passing `:rest` or `:grpc` in
127
273
  # the `transport` parameter.
128
274
  #
275
+ # Raises an exception if the currently installed versioned client gem for the
276
+ # given API version does not support the given transport of the Intents service.
277
+ # You can determine whether the method will succeed by calling
278
+ # {Google::Cloud::Dialogflow.intents_available?}.
279
+ #
129
280
  # ## About Intents
130
281
  #
131
282
  # Service for managing Intents.
@@ -147,6 +298,37 @@ module Google
147
298
  service_module.const_get(:Client).new(&block)
148
299
  end
149
300
 
301
+ ##
302
+ # Determines whether the Intents service is supported by the current client.
303
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.intents}.
304
+ # If false, that method will raise an exception. This could happen if the given
305
+ # API version does not exist or does not support the Intents service,
306
+ # or if the versioned client gem needs an update to support the Intents service.
307
+ #
308
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
309
+ # Defaults to `:v2`.
310
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
311
+ # @return [boolean] Whether the service is available.
312
+ #
313
+ def self.intents_available? version: :v2, transport: :grpc
314
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
315
+ package_name = Google::Cloud::Dialogflow
316
+ .constants
317
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
318
+ .first
319
+ return false unless package_name
320
+ service_module = Google::Cloud::Dialogflow.const_get package_name
321
+ return false unless service_module.const_defined? :Intents
322
+ service_module = service_module.const_get :Intents
323
+ if transport == :rest
324
+ return false unless service_module.const_defined? :Rest
325
+ service_module = service_module.const_get :Rest
326
+ end
327
+ service_module.const_defined? :Client
328
+ rescue ::LoadError
329
+ false
330
+ end
331
+
150
332
  ##
151
333
  # Create a new client object for EntityTypes.
152
334
  #
@@ -160,6 +342,11 @@ module Google
160
342
  # You can also specify a different transport by passing `:rest` or `:grpc` in
161
343
  # the `transport` parameter.
162
344
  #
345
+ # Raises an exception if the currently installed versioned client gem for the
346
+ # given API version does not support the given transport of the EntityTypes service.
347
+ # You can determine whether the method will succeed by calling
348
+ # {Google::Cloud::Dialogflow.entity_types_available?}.
349
+ #
163
350
  # ## About EntityTypes
164
351
  #
165
352
  # Service for managing EntityTypes.
@@ -181,6 +368,37 @@ module Google
181
368
  service_module.const_get(:Client).new(&block)
182
369
  end
183
370
 
371
+ ##
372
+ # Determines whether the EntityTypes service is supported by the current client.
373
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.entity_types}.
374
+ # If false, that method will raise an exception. This could happen if the given
375
+ # API version does not exist or does not support the EntityTypes service,
376
+ # or if the versioned client gem needs an update to support the EntityTypes service.
377
+ #
378
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
379
+ # Defaults to `:v2`.
380
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
381
+ # @return [boolean] Whether the service is available.
382
+ #
383
+ def self.entity_types_available? version: :v2, transport: :grpc
384
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
385
+ package_name = Google::Cloud::Dialogflow
386
+ .constants
387
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
388
+ .first
389
+ return false unless package_name
390
+ service_module = Google::Cloud::Dialogflow.const_get package_name
391
+ return false unless service_module.const_defined? :EntityTypes
392
+ service_module = service_module.const_get :EntityTypes
393
+ if transport == :rest
394
+ return false unless service_module.const_defined? :Rest
395
+ service_module = service_module.const_get :Rest
396
+ end
397
+ service_module.const_defined? :Client
398
+ rescue ::LoadError
399
+ false
400
+ end
401
+
184
402
  ##
185
403
  # Create a new client object for SessionEntityTypes.
186
404
  #
@@ -194,6 +412,11 @@ module Google
194
412
  # You can also specify a different transport by passing `:rest` or `:grpc` in
195
413
  # the `transport` parameter.
196
414
  #
415
+ # Raises an exception if the currently installed versioned client gem for the
416
+ # given API version does not support the given transport of the SessionEntityTypes service.
417
+ # You can determine whether the method will succeed by calling
418
+ # {Google::Cloud::Dialogflow.session_entity_types_available?}.
419
+ #
197
420
  # ## About SessionEntityTypes
198
421
  #
199
422
  # Service for managing
@@ -216,6 +439,37 @@ module Google
216
439
  service_module.const_get(:Client).new(&block)
217
440
  end
218
441
 
442
+ ##
443
+ # Determines whether the SessionEntityTypes service is supported by the current client.
444
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.session_entity_types}.
445
+ # If false, that method will raise an exception. This could happen if the given
446
+ # API version does not exist or does not support the SessionEntityTypes service,
447
+ # or if the versioned client gem needs an update to support the SessionEntityTypes service.
448
+ #
449
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
450
+ # Defaults to `:v2`.
451
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
452
+ # @return [boolean] Whether the service is available.
453
+ #
454
+ def self.session_entity_types_available? version: :v2, transport: :grpc
455
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
456
+ package_name = Google::Cloud::Dialogflow
457
+ .constants
458
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
459
+ .first
460
+ return false unless package_name
461
+ service_module = Google::Cloud::Dialogflow.const_get package_name
462
+ return false unless service_module.const_defined? :SessionEntityTypes
463
+ service_module = service_module.const_get :SessionEntityTypes
464
+ if transport == :rest
465
+ return false unless service_module.const_defined? :Rest
466
+ service_module = service_module.const_get :Rest
467
+ end
468
+ service_module.const_defined? :Client
469
+ rescue ::LoadError
470
+ false
471
+ end
472
+
219
473
  ##
220
474
  # Create a new client object for Sessions.
221
475
  #
@@ -229,6 +483,11 @@ module Google
229
483
  # You can also specify a different transport by passing `:rest` or `:grpc` in
230
484
  # the `transport` parameter.
231
485
  #
486
+ # Raises an exception if the currently installed versioned client gem for the
487
+ # given API version does not support the given transport of the Sessions service.
488
+ # You can determine whether the method will succeed by calling
489
+ # {Google::Cloud::Dialogflow.sessions_available?}.
490
+ #
232
491
  # ## About Sessions
233
492
  #
234
493
  # A service used for session interactions.
@@ -253,6 +512,37 @@ module Google
253
512
  service_module.const_get(:Client).new(&block)
254
513
  end
255
514
 
515
+ ##
516
+ # Determines whether the Sessions service is supported by the current client.
517
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.sessions}.
518
+ # If false, that method will raise an exception. This could happen if the given
519
+ # API version does not exist or does not support the Sessions service,
520
+ # or if the versioned client gem needs an update to support the Sessions service.
521
+ #
522
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
523
+ # Defaults to `:v2`.
524
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
525
+ # @return [boolean] Whether the service is available.
526
+ #
527
+ def self.sessions_available? version: :v2, transport: :grpc
528
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
529
+ package_name = Google::Cloud::Dialogflow
530
+ .constants
531
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
532
+ .first
533
+ return false unless package_name
534
+ service_module = Google::Cloud::Dialogflow.const_get package_name
535
+ return false unless service_module.const_defined? :Sessions
536
+ service_module = service_module.const_get :Sessions
537
+ if transport == :rest
538
+ return false unless service_module.const_defined? :Rest
539
+ service_module = service_module.const_get :Rest
540
+ end
541
+ service_module.const_defined? :Client
542
+ rescue ::LoadError
543
+ false
544
+ end
545
+
256
546
  ##
257
547
  # Create a new client object for Participants.
258
548
  #
@@ -266,6 +556,11 @@ module Google
266
556
  # You can also specify a different transport by passing `:rest` or `:grpc` in
267
557
  # the `transport` parameter.
268
558
  #
559
+ # Raises an exception if the currently installed versioned client gem for the
560
+ # given API version does not support the given transport of the Participants service.
561
+ # You can determine whether the method will succeed by calling
562
+ # {Google::Cloud::Dialogflow.participants_available?}.
563
+ #
269
564
  # ## About Participants
270
565
  #
271
566
  # Service for managing Participants.
@@ -287,6 +582,37 @@ module Google
287
582
  service_module.const_get(:Client).new(&block)
288
583
  end
289
584
 
585
+ ##
586
+ # Determines whether the Participants service is supported by the current client.
587
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.participants}.
588
+ # If false, that method will raise an exception. This could happen if the given
589
+ # API version does not exist or does not support the Participants service,
590
+ # or if the versioned client gem needs an update to support the Participants service.
591
+ #
592
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
593
+ # Defaults to `:v2`.
594
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
595
+ # @return [boolean] Whether the service is available.
596
+ #
597
+ def self.participants_available? version: :v2, transport: :grpc
598
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
599
+ package_name = Google::Cloud::Dialogflow
600
+ .constants
601
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
602
+ .first
603
+ return false unless package_name
604
+ service_module = Google::Cloud::Dialogflow.const_get package_name
605
+ return false unless service_module.const_defined? :Participants
606
+ service_module = service_module.const_get :Participants
607
+ if transport == :rest
608
+ return false unless service_module.const_defined? :Rest
609
+ service_module = service_module.const_get :Rest
610
+ end
611
+ service_module.const_defined? :Client
612
+ rescue ::LoadError
613
+ false
614
+ end
615
+
290
616
  ##
291
617
  # Create a new client object for AnswerRecords.
292
618
  #
@@ -300,6 +626,11 @@ module Google
300
626
  # You can also specify a different transport by passing `:rest` or `:grpc` in
301
627
  # the `transport` parameter.
302
628
  #
629
+ # Raises an exception if the currently installed versioned client gem for the
630
+ # given API version does not support the given transport of the AnswerRecords service.
631
+ # You can determine whether the method will succeed by calling
632
+ # {Google::Cloud::Dialogflow.answer_records_available?}.
633
+ #
303
634
  # ## About AnswerRecords
304
635
  #
305
636
  # Service for managing
@@ -322,6 +653,37 @@ module Google
322
653
  service_module.const_get(:Client).new(&block)
323
654
  end
324
655
 
656
+ ##
657
+ # Determines whether the AnswerRecords service is supported by the current client.
658
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.answer_records}.
659
+ # If false, that method will raise an exception. This could happen if the given
660
+ # API version does not exist or does not support the AnswerRecords service,
661
+ # or if the versioned client gem needs an update to support the AnswerRecords service.
662
+ #
663
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
664
+ # Defaults to `:v2`.
665
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
666
+ # @return [boolean] Whether the service is available.
667
+ #
668
+ def self.answer_records_available? version: :v2, transport: :grpc
669
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
670
+ package_name = Google::Cloud::Dialogflow
671
+ .constants
672
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
673
+ .first
674
+ return false unless package_name
675
+ service_module = Google::Cloud::Dialogflow.const_get package_name
676
+ return false unless service_module.const_defined? :AnswerRecords
677
+ service_module = service_module.const_get :AnswerRecords
678
+ if transport == :rest
679
+ return false unless service_module.const_defined? :Rest
680
+ service_module = service_module.const_get :Rest
681
+ end
682
+ service_module.const_defined? :Client
683
+ rescue ::LoadError
684
+ false
685
+ end
686
+
325
687
  ##
326
688
  # Create a new client object for ConversationProfiles.
327
689
  #
@@ -335,6 +697,11 @@ module Google
335
697
  # You can also specify a different transport by passing `:rest` or `:grpc` in
336
698
  # the `transport` parameter.
337
699
  #
700
+ # Raises an exception if the currently installed versioned client gem for the
701
+ # given API version does not support the given transport of the ConversationProfiles service.
702
+ # You can determine whether the method will succeed by calling
703
+ # {Google::Cloud::Dialogflow.conversation_profiles_available?}.
704
+ #
338
705
  # ## About ConversationProfiles
339
706
  #
340
707
  # Service for managing
@@ -358,41 +725,34 @@ module Google
358
725
  end
359
726
 
360
727
  ##
361
- # Create a new client object for Generators.
362
- #
363
- # By default, this returns an instance of
364
- # [Google::Cloud::Dialogflow::V2::Generators::Client](https://cloud.google.com/ruby/docs/reference/google-cloud-dialogflow-v2/latest/Google-Cloud-Dialogflow-V2-Generators-Client)
365
- # for a gRPC client for version V2 of the API.
366
- # However, you can specify a different API version by passing it in the
367
- # `version` parameter. If the Generators service is
368
- # supported by that API version, and the corresponding gem is available, the
369
- # appropriate versioned client will be returned.
370
- # You can also specify a different transport by passing `:rest` or `:grpc` in
371
- # the `transport` parameter.
372
- #
373
- # ## About Generators
374
- #
375
- # Generator Service for LLM powered Agent Assist. This service manages the
376
- # configurations of user owned Generators, such as description, context and
377
- # instruction, input/output format, etc. The generator resources will be used
378
- # inside a conversation and will be triggered by TriggerEvent to query LLM for
379
- # answers.
728
+ # Determines whether the ConversationProfiles service is supported by the current client.
729
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.conversation_profiles}.
730
+ # If false, that method will raise an exception. This could happen if the given
731
+ # API version does not exist or does not support the ConversationProfiles service,
732
+ # or if the versioned client gem needs an update to support the ConversationProfiles service.
380
733
  #
381
734
  # @param version [::String, ::Symbol] The API version to connect to. Optional.
382
735
  # Defaults to `:v2`.
383
736
  # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
384
- # @return [::Object] A client object for the specified version.
737
+ # @return [boolean] Whether the service is available.
385
738
  #
386
- def self.generators version: :v2, transport: :grpc, &block
739
+ def self.conversation_profiles_available? version: :v2, transport: :grpc
387
740
  require "google/cloud/dialogflow/#{version.to_s.downcase}"
388
-
389
741
  package_name = Google::Cloud::Dialogflow
390
742
  .constants
391
743
  .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
392
744
  .first
393
- service_module = Google::Cloud::Dialogflow.const_get(package_name).const_get(:Generators)
394
- service_module = service_module.const_get(:Rest) if transport == :rest
395
- service_module.const_get(:Client).new(&block)
745
+ return false unless package_name
746
+ service_module = Google::Cloud::Dialogflow.const_get package_name
747
+ return false unless service_module.const_defined? :ConversationProfiles
748
+ service_module = service_module.const_get :ConversationProfiles
749
+ if transport == :rest
750
+ return false unless service_module.const_defined? :Rest
751
+ service_module = service_module.const_get :Rest
752
+ end
753
+ service_module.const_defined? :Client
754
+ rescue ::LoadError
755
+ false
396
756
  end
397
757
 
398
758
  ##
@@ -408,6 +768,11 @@ module Google
408
768
  # You can also specify a different transport by passing `:rest` or `:grpc` in
409
769
  # the `transport` parameter.
410
770
  #
771
+ # Raises an exception if the currently installed versioned client gem for the
772
+ # given API version does not support the given transport of the Conversations service.
773
+ # You can determine whether the method will succeed by calling
774
+ # {Google::Cloud::Dialogflow.conversations_available?}.
775
+ #
411
776
  # ## About Conversations
412
777
  #
413
778
  # Service for managing
@@ -430,6 +795,37 @@ module Google
430
795
  service_module.const_get(:Client).new(&block)
431
796
  end
432
797
 
798
+ ##
799
+ # Determines whether the Conversations service is supported by the current client.
800
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.conversations}.
801
+ # If false, that method will raise an exception. This could happen if the given
802
+ # API version does not exist or does not support the Conversations service,
803
+ # or if the versioned client gem needs an update to support the Conversations service.
804
+ #
805
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
806
+ # Defaults to `:v2`.
807
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
808
+ # @return [boolean] Whether the service is available.
809
+ #
810
+ def self.conversations_available? version: :v2, transport: :grpc
811
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
812
+ package_name = Google::Cloud::Dialogflow
813
+ .constants
814
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
815
+ .first
816
+ return false unless package_name
817
+ service_module = Google::Cloud::Dialogflow.const_get package_name
818
+ return false unless service_module.const_defined? :Conversations
819
+ service_module = service_module.const_get :Conversations
820
+ if transport == :rest
821
+ return false unless service_module.const_defined? :Rest
822
+ service_module = service_module.const_get :Rest
823
+ end
824
+ service_module.const_defined? :Client
825
+ rescue ::LoadError
826
+ false
827
+ end
828
+
433
829
  ##
434
830
  # Create a new client object for ConversationDatasets.
435
831
  #
@@ -443,6 +839,11 @@ module Google
443
839
  # You can also specify a different transport by passing `:rest` or `:grpc` in
444
840
  # the `transport` parameter.
445
841
  #
842
+ # Raises an exception if the currently installed versioned client gem for the
843
+ # given API version does not support the given transport of the ConversationDatasets service.
844
+ # You can determine whether the method will succeed by calling
845
+ # {Google::Cloud::Dialogflow.conversation_datasets_available?}.
846
+ #
446
847
  # ## About ConversationDatasets
447
848
  #
448
849
  # Conversation datasets.
@@ -467,6 +868,37 @@ module Google
467
868
  service_module.const_get(:Client).new(&block)
468
869
  end
469
870
 
871
+ ##
872
+ # Determines whether the ConversationDatasets service is supported by the current client.
873
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.conversation_datasets}.
874
+ # If false, that method will raise an exception. This could happen if the given
875
+ # API version does not exist or does not support the ConversationDatasets service,
876
+ # or if the versioned client gem needs an update to support the ConversationDatasets service.
877
+ #
878
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
879
+ # Defaults to `:v2`.
880
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
881
+ # @return [boolean] Whether the service is available.
882
+ #
883
+ def self.conversation_datasets_available? version: :v2, transport: :grpc
884
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
885
+ package_name = Google::Cloud::Dialogflow
886
+ .constants
887
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
888
+ .first
889
+ return false unless package_name
890
+ service_module = Google::Cloud::Dialogflow.const_get package_name
891
+ return false unless service_module.const_defined? :ConversationDatasets
892
+ service_module = service_module.const_get :ConversationDatasets
893
+ if transport == :rest
894
+ return false unless service_module.const_defined? :Rest
895
+ service_module = service_module.const_get :Rest
896
+ end
897
+ service_module.const_defined? :Client
898
+ rescue ::LoadError
899
+ false
900
+ end
901
+
470
902
  ##
471
903
  # Create a new client object for ConversationModels.
472
904
  #
@@ -480,6 +912,11 @@ module Google
480
912
  # You can also specify a different transport by passing `:rest` or `:grpc` in
481
913
  # the `transport` parameter.
482
914
  #
915
+ # Raises an exception if the currently installed versioned client gem for the
916
+ # given API version does not support the given transport of the ConversationModels service.
917
+ # You can determine whether the method will succeed by calling
918
+ # {Google::Cloud::Dialogflow.conversation_models_available?}.
919
+ #
483
920
  # ## About ConversationModels
484
921
  #
485
922
  # Manages a collection of models for human agent assistant.
@@ -501,6 +938,37 @@ module Google
501
938
  service_module.const_get(:Client).new(&block)
502
939
  end
503
940
 
941
+ ##
942
+ # Determines whether the ConversationModels service is supported by the current client.
943
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.conversation_models}.
944
+ # If false, that method will raise an exception. This could happen if the given
945
+ # API version does not exist or does not support the ConversationModels service,
946
+ # or if the versioned client gem needs an update to support the ConversationModels service.
947
+ #
948
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
949
+ # Defaults to `:v2`.
950
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
951
+ # @return [boolean] Whether the service is available.
952
+ #
953
+ def self.conversation_models_available? version: :v2, transport: :grpc
954
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
955
+ package_name = Google::Cloud::Dialogflow
956
+ .constants
957
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
958
+ .first
959
+ return false unless package_name
960
+ service_module = Google::Cloud::Dialogflow.const_get package_name
961
+ return false unless service_module.const_defined? :ConversationModels
962
+ service_module = service_module.const_get :ConversationModels
963
+ if transport == :rest
964
+ return false unless service_module.const_defined? :Rest
965
+ service_module = service_module.const_get :Rest
966
+ end
967
+ service_module.const_defined? :Client
968
+ rescue ::LoadError
969
+ false
970
+ end
971
+
504
972
  ##
505
973
  # Create a new client object for Documents.
506
974
  #
@@ -514,6 +982,11 @@ module Google
514
982
  # You can also specify a different transport by passing `:rest` or `:grpc` in
515
983
  # the `transport` parameter.
516
984
  #
985
+ # Raises an exception if the currently installed versioned client gem for the
986
+ # given API version does not support the given transport of the Documents service.
987
+ # You can determine whether the method will succeed by calling
988
+ # {Google::Cloud::Dialogflow.documents_available?}.
989
+ #
517
990
  # ## About Documents
518
991
  #
519
992
  # Service for managing knowledge
@@ -536,6 +1009,37 @@ module Google
536
1009
  service_module.const_get(:Client).new(&block)
537
1010
  end
538
1011
 
1012
+ ##
1013
+ # Determines whether the Documents service is supported by the current client.
1014
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.documents}.
1015
+ # If false, that method will raise an exception. This could happen if the given
1016
+ # API version does not exist or does not support the Documents service,
1017
+ # or if the versioned client gem needs an update to support the Documents service.
1018
+ #
1019
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1020
+ # Defaults to `:v2`.
1021
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1022
+ # @return [boolean] Whether the service is available.
1023
+ #
1024
+ def self.documents_available? version: :v2, transport: :grpc
1025
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1026
+ package_name = Google::Cloud::Dialogflow
1027
+ .constants
1028
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1029
+ .first
1030
+ return false unless package_name
1031
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1032
+ return false unless service_module.const_defined? :Documents
1033
+ service_module = service_module.const_get :Documents
1034
+ if transport == :rest
1035
+ return false unless service_module.const_defined? :Rest
1036
+ service_module = service_module.const_get :Rest
1037
+ end
1038
+ service_module.const_defined? :Client
1039
+ rescue ::LoadError
1040
+ false
1041
+ end
1042
+
539
1043
  ##
540
1044
  # Create a new client object for EncryptionSpecService.
541
1045
  #
@@ -549,6 +1053,11 @@ module Google
549
1053
  # You can also specify a different transport by passing `:rest` or `:grpc` in
550
1054
  # the `transport` parameter.
551
1055
  #
1056
+ # Raises an exception if the currently installed versioned client gem for the
1057
+ # given API version does not support the given transport of the EncryptionSpecService service.
1058
+ # You can determine whether the method will succeed by calling
1059
+ # {Google::Cloud::Dialogflow.encryption_spec_service_available?}.
1060
+ #
552
1061
  # ## About EncryptionSpecService
553
1062
  #
554
1063
  # Manages encryption spec settings for Dialogflow and Agent Assist.
@@ -570,6 +1079,37 @@ module Google
570
1079
  service_module.const_get(:Client).new(&block)
571
1080
  end
572
1081
 
1082
+ ##
1083
+ # Determines whether the EncryptionSpecService service is supported by the current client.
1084
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.encryption_spec_service}.
1085
+ # If false, that method will raise an exception. This could happen if the given
1086
+ # API version does not exist or does not support the EncryptionSpecService service,
1087
+ # or if the versioned client gem needs an update to support the EncryptionSpecService service.
1088
+ #
1089
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1090
+ # Defaults to `:v2`.
1091
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1092
+ # @return [boolean] Whether the service is available.
1093
+ #
1094
+ def self.encryption_spec_service_available? version: :v2, transport: :grpc
1095
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1096
+ package_name = Google::Cloud::Dialogflow
1097
+ .constants
1098
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1099
+ .first
1100
+ return false unless package_name
1101
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1102
+ return false unless service_module.const_defined? :EncryptionSpecService
1103
+ service_module = service_module.const_get :EncryptionSpecService
1104
+ if transport == :rest
1105
+ return false unless service_module.const_defined? :Rest
1106
+ service_module = service_module.const_get :Rest
1107
+ end
1108
+ service_module.const_defined? :Client
1109
+ rescue ::LoadError
1110
+ false
1111
+ end
1112
+
573
1113
  ##
574
1114
  # Create a new client object for Fulfillments.
575
1115
  #
@@ -583,6 +1123,11 @@ module Google
583
1123
  # You can also specify a different transport by passing `:rest` or `:grpc` in
584
1124
  # the `transport` parameter.
585
1125
  #
1126
+ # Raises an exception if the currently installed versioned client gem for the
1127
+ # given API version does not support the given transport of the Fulfillments service.
1128
+ # You can determine whether the method will succeed by calling
1129
+ # {Google::Cloud::Dialogflow.fulfillments_available?}.
1130
+ #
586
1131
  # ## About Fulfillments
587
1132
  #
588
1133
  # Service for managing Fulfillments.
@@ -604,6 +1149,37 @@ module Google
604
1149
  service_module.const_get(:Client).new(&block)
605
1150
  end
606
1151
 
1152
+ ##
1153
+ # Determines whether the Fulfillments service is supported by the current client.
1154
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.fulfillments}.
1155
+ # If false, that method will raise an exception. This could happen if the given
1156
+ # API version does not exist or does not support the Fulfillments service,
1157
+ # or if the versioned client gem needs an update to support the Fulfillments service.
1158
+ #
1159
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1160
+ # Defaults to `:v2`.
1161
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1162
+ # @return [boolean] Whether the service is available.
1163
+ #
1164
+ def self.fulfillments_available? version: :v2, transport: :grpc
1165
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1166
+ package_name = Google::Cloud::Dialogflow
1167
+ .constants
1168
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1169
+ .first
1170
+ return false unless package_name
1171
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1172
+ return false unless service_module.const_defined? :Fulfillments
1173
+ service_module = service_module.const_get :Fulfillments
1174
+ if transport == :rest
1175
+ return false unless service_module.const_defined? :Rest
1176
+ service_module = service_module.const_get :Rest
1177
+ end
1178
+ service_module.const_defined? :Client
1179
+ rescue ::LoadError
1180
+ false
1181
+ end
1182
+
607
1183
  ##
608
1184
  # Create a new client object for Environments.
609
1185
  #
@@ -617,6 +1193,11 @@ module Google
617
1193
  # You can also specify a different transport by passing `:rest` or `:grpc` in
618
1194
  # the `transport` parameter.
619
1195
  #
1196
+ # Raises an exception if the currently installed versioned client gem for the
1197
+ # given API version does not support the given transport of the Environments service.
1198
+ # You can determine whether the method will succeed by calling
1199
+ # {Google::Cloud::Dialogflow.environments_available?}.
1200
+ #
620
1201
  # ## About Environments
621
1202
  #
622
1203
  # Service for managing Environments.
@@ -638,6 +1219,37 @@ module Google
638
1219
  service_module.const_get(:Client).new(&block)
639
1220
  end
640
1221
 
1222
+ ##
1223
+ # Determines whether the Environments service is supported by the current client.
1224
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.environments}.
1225
+ # If false, that method will raise an exception. This could happen if the given
1226
+ # API version does not exist or does not support the Environments service,
1227
+ # or if the versioned client gem needs an update to support the Environments service.
1228
+ #
1229
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1230
+ # Defaults to `:v2`.
1231
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1232
+ # @return [boolean] Whether the service is available.
1233
+ #
1234
+ def self.environments_available? version: :v2, transport: :grpc
1235
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1236
+ package_name = Google::Cloud::Dialogflow
1237
+ .constants
1238
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1239
+ .first
1240
+ return false unless package_name
1241
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1242
+ return false unless service_module.const_defined? :Environments
1243
+ service_module = service_module.const_get :Environments
1244
+ if transport == :rest
1245
+ return false unless service_module.const_defined? :Rest
1246
+ service_module = service_module.const_get :Rest
1247
+ end
1248
+ service_module.const_defined? :Client
1249
+ rescue ::LoadError
1250
+ false
1251
+ end
1252
+
641
1253
  ##
642
1254
  # Create a new client object for KnowledgeBases.
643
1255
  #
@@ -651,6 +1263,11 @@ module Google
651
1263
  # You can also specify a different transport by passing `:rest` or `:grpc` in
652
1264
  # the `transport` parameter.
653
1265
  #
1266
+ # Raises an exception if the currently installed versioned client gem for the
1267
+ # given API version does not support the given transport of the KnowledgeBases service.
1268
+ # You can determine whether the method will succeed by calling
1269
+ # {Google::Cloud::Dialogflow.knowledge_bases_available?}.
1270
+ #
654
1271
  # ## About KnowledgeBases
655
1272
  #
656
1273
  # Service for managing
@@ -673,6 +1290,37 @@ module Google
673
1290
  service_module.const_get(:Client).new(&block)
674
1291
  end
675
1292
 
1293
+ ##
1294
+ # Determines whether the KnowledgeBases service is supported by the current client.
1295
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.knowledge_bases}.
1296
+ # If false, that method will raise an exception. This could happen if the given
1297
+ # API version does not exist or does not support the KnowledgeBases service,
1298
+ # or if the versioned client gem needs an update to support the KnowledgeBases service.
1299
+ #
1300
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1301
+ # Defaults to `:v2`.
1302
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1303
+ # @return [boolean] Whether the service is available.
1304
+ #
1305
+ def self.knowledge_bases_available? version: :v2, transport: :grpc
1306
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1307
+ package_name = Google::Cloud::Dialogflow
1308
+ .constants
1309
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1310
+ .first
1311
+ return false unless package_name
1312
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1313
+ return false unless service_module.const_defined? :KnowledgeBases
1314
+ service_module = service_module.const_get :KnowledgeBases
1315
+ if transport == :rest
1316
+ return false unless service_module.const_defined? :Rest
1317
+ service_module = service_module.const_get :Rest
1318
+ end
1319
+ service_module.const_defined? :Client
1320
+ rescue ::LoadError
1321
+ false
1322
+ end
1323
+
676
1324
  ##
677
1325
  # Create a new client object for Versions.
678
1326
  #
@@ -686,6 +1334,11 @@ module Google
686
1334
  # You can also specify a different transport by passing `:rest` or `:grpc` in
687
1335
  # the `transport` parameter.
688
1336
  #
1337
+ # Raises an exception if the currently installed versioned client gem for the
1338
+ # given API version does not support the given transport of the Versions service.
1339
+ # You can determine whether the method will succeed by calling
1340
+ # {Google::Cloud::Dialogflow.versions_available?}.
1341
+ #
689
1342
  # ## About Versions
690
1343
  #
691
1344
  # Service for managing Versions.
@@ -707,6 +1360,37 @@ module Google
707
1360
  service_module.const_get(:Client).new(&block)
708
1361
  end
709
1362
 
1363
+ ##
1364
+ # Determines whether the Versions service is supported by the current client.
1365
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.versions}.
1366
+ # If false, that method will raise an exception. This could happen if the given
1367
+ # API version does not exist or does not support the Versions service,
1368
+ # or if the versioned client gem needs an update to support the Versions service.
1369
+ #
1370
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
1371
+ # Defaults to `:v2`.
1372
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1373
+ # @return [boolean] Whether the service is available.
1374
+ #
1375
+ def self.versions_available? version: :v2, transport: :grpc
1376
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
1377
+ package_name = Google::Cloud::Dialogflow
1378
+ .constants
1379
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1380
+ .first
1381
+ return false unless package_name
1382
+ service_module = Google::Cloud::Dialogflow.const_get package_name
1383
+ return false unless service_module.const_defined? :Versions
1384
+ service_module = service_module.const_get :Versions
1385
+ if transport == :rest
1386
+ return false unless service_module.const_defined? :Rest
1387
+ service_module = service_module.const_get :Rest
1388
+ end
1389
+ service_module.const_defined? :Client
1390
+ rescue ::LoadError
1391
+ false
1392
+ end
1393
+
710
1394
  ##
711
1395
  # Configure the google-cloud-dialogflow library.
712
1396
  #
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-dialogflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.1
4
+ version: 1.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-08-09 00:00:00.000000000 Z
10
+ date: 2025-03-12 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: google-cloud-core
@@ -67,7 +66,6 @@ homepage: https://github.com/googleapis/google-cloud-ruby
67
66
  licenses:
68
67
  - Apache-2.0
69
68
  metadata: {}
70
- post_install_message:
71
69
  rdoc_options: []
72
70
  require_paths:
73
71
  - lib
@@ -75,15 +73,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
75
73
  requirements:
76
74
  - - ">="
77
75
  - !ruby/object:Gem::Version
78
- version: '2.7'
76
+ version: '3.0'
79
77
  required_rubygems_version: !ruby/object:Gem::Requirement
80
78
  requirements:
81
79
  - - ">="
82
80
  - !ruby/object:Gem::Version
83
81
  version: '0'
84
82
  requirements: []
85
- rubygems_version: 3.5.6
86
- signing_key:
83
+ rubygems_version: 3.6.5
87
84
  specification_version: 4
88
85
  summary: API Client library for the Dialogflow API
89
86
  test_files: []