google-cloud-dialogflow-cx-v3 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/dialogflow/cx/v3/agents/client.rb +200 -27
- data/lib/google/cloud/dialogflow/cx/v3/agents/operations.rb +115 -12
- data/lib/google/cloud/dialogflow/cx/v3/changelogs/client.rb +46 -6
- data/lib/google/cloud/dialogflow/cx/v3/deployments/client.rb +46 -6
- data/lib/google/cloud/dialogflow/cx/v3/entity_types/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/environments/client.rb +226 -27
- data/lib/google/cloud/dialogflow/cx/v3/environments/operations.rb +115 -12
- data/lib/google/cloud/dialogflow/cx/v3/experiments/client.rb +146 -21
- data/lib/google/cloud/dialogflow/cx/v3/flows/client.rb +227 -30
- data/lib/google/cloud/dialogflow/cx/v3/flows/operations.rb +115 -12
- data/lib/google/cloud/dialogflow/cx/v3/intents/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/pages/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/security_settings_service/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/session_entity_types/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/sessions/client.rb +84 -9
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/client.rb +280 -36
- data/lib/google/cloud/dialogflow/cx/v3/test_cases/operations.rb +115 -12
- data/lib/google/cloud/dialogflow/cx/v3/transition_route_groups/client.rb +106 -15
- data/lib/google/cloud/dialogflow/cx/v3/version.rb +1 -1
- data/lib/google/cloud/dialogflow/cx/v3/versions/client.rb +140 -18
- data/lib/google/cloud/dialogflow/cx/v3/versions/operations.rb +115 -12
- data/lib/google/cloud/dialogflow/cx/v3/webhooks/client.rb +106 -15
- metadata +2 -2
@@ -200,6 +200,27 @@ module Google
|
|
200
200
|
#
|
201
201
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
202
202
|
#
|
203
|
+
# @example Basic example
|
204
|
+
# require "google/cloud/dialogflow/cx/v3"
|
205
|
+
#
|
206
|
+
# # Create a client object. The client can be reused for multiple calls.
|
207
|
+
# client = Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroups::Client.new
|
208
|
+
#
|
209
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
210
|
+
# request = Google::Cloud::Dialogflow::CX::V3::ListTransitionRouteGroupsRequest.new
|
211
|
+
#
|
212
|
+
# # Call the list_transition_route_groups method.
|
213
|
+
# result = client.list_transition_route_groups request
|
214
|
+
#
|
215
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
216
|
+
# # iterate over all elements by calling #each, and the enumerable
|
217
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
218
|
+
# # methods are also available for managing paging directly.
|
219
|
+
# result.each do |response|
|
220
|
+
# # Each element is of type ::Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroup.
|
221
|
+
# p response
|
222
|
+
# end
|
223
|
+
#
|
203
224
|
def list_transition_route_groups request, options = nil
|
204
225
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
205
226
|
|
@@ -217,9 +238,11 @@ module Google
|
|
217
238
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
218
239
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
219
240
|
|
220
|
-
header_params = {
|
221
|
-
|
222
|
-
|
241
|
+
header_params = {}
|
242
|
+
if request.parent
|
243
|
+
header_params["parent"] = request.parent
|
244
|
+
end
|
245
|
+
|
223
246
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
224
247
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
225
248
|
|
@@ -284,6 +307,21 @@ module Google
|
|
284
307
|
#
|
285
308
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
286
309
|
#
|
310
|
+
# @example Basic example
|
311
|
+
# require "google/cloud/dialogflow/cx/v3"
|
312
|
+
#
|
313
|
+
# # Create a client object. The client can be reused for multiple calls.
|
314
|
+
# client = Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroups::Client.new
|
315
|
+
#
|
316
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
317
|
+
# request = Google::Cloud::Dialogflow::CX::V3::GetTransitionRouteGroupRequest.new
|
318
|
+
#
|
319
|
+
# # Call the get_transition_route_group method.
|
320
|
+
# result = client.get_transition_route_group request
|
321
|
+
#
|
322
|
+
# # The returned object is of type Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroup.
|
323
|
+
# p result
|
324
|
+
#
|
287
325
|
def get_transition_route_group request, options = nil
|
288
326
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
289
327
|
|
@@ -301,9 +339,11 @@ module Google
|
|
301
339
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
302
340
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
303
341
|
|
304
|
-
header_params = {
|
305
|
-
|
306
|
-
|
342
|
+
header_params = {}
|
343
|
+
if request.name
|
344
|
+
header_params["name"] = request.name
|
345
|
+
end
|
346
|
+
|
307
347
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
308
348
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
309
349
|
|
@@ -372,6 +412,21 @@ module Google
|
|
372
412
|
#
|
373
413
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
374
414
|
#
|
415
|
+
# @example Basic example
|
416
|
+
# require "google/cloud/dialogflow/cx/v3"
|
417
|
+
#
|
418
|
+
# # Create a client object. The client can be reused for multiple calls.
|
419
|
+
# client = Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroups::Client.new
|
420
|
+
#
|
421
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
422
|
+
# request = Google::Cloud::Dialogflow::CX::V3::CreateTransitionRouteGroupRequest.new
|
423
|
+
#
|
424
|
+
# # Call the create_transition_route_group method.
|
425
|
+
# result = client.create_transition_route_group request
|
426
|
+
#
|
427
|
+
# # The returned object is of type Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroup.
|
428
|
+
# p result
|
429
|
+
#
|
375
430
|
def create_transition_route_group request, options = nil
|
376
431
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
377
432
|
|
@@ -389,9 +444,11 @@ module Google
|
|
389
444
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
390
445
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
391
446
|
|
392
|
-
header_params = {
|
393
|
-
|
394
|
-
|
447
|
+
header_params = {}
|
448
|
+
if request.parent
|
449
|
+
header_params["parent"] = request.parent
|
450
|
+
end
|
451
|
+
|
395
452
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
396
453
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
397
454
|
|
@@ -458,6 +515,21 @@ module Google
|
|
458
515
|
#
|
459
516
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
460
517
|
#
|
518
|
+
# @example Basic example
|
519
|
+
# require "google/cloud/dialogflow/cx/v3"
|
520
|
+
#
|
521
|
+
# # Create a client object. The client can be reused for multiple calls.
|
522
|
+
# client = Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroups::Client.new
|
523
|
+
#
|
524
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
525
|
+
# request = Google::Cloud::Dialogflow::CX::V3::UpdateTransitionRouteGroupRequest.new
|
526
|
+
#
|
527
|
+
# # Call the update_transition_route_group method.
|
528
|
+
# result = client.update_transition_route_group request
|
529
|
+
#
|
530
|
+
# # The returned object is of type Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroup.
|
531
|
+
# p result
|
532
|
+
#
|
461
533
|
def update_transition_route_group request, options = nil
|
462
534
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
463
535
|
|
@@ -475,9 +547,11 @@ module Google
|
|
475
547
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
476
548
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
477
549
|
|
478
|
-
header_params = {
|
479
|
-
|
480
|
-
|
550
|
+
header_params = {}
|
551
|
+
if request.transition_route_group&.name
|
552
|
+
header_params["transition_route_group.name"] = request.transition_route_group.name
|
553
|
+
end
|
554
|
+
|
481
555
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
482
556
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
483
557
|
|
@@ -540,6 +614,21 @@ module Google
|
|
540
614
|
#
|
541
615
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
542
616
|
#
|
617
|
+
# @example Basic example
|
618
|
+
# require "google/cloud/dialogflow/cx/v3"
|
619
|
+
#
|
620
|
+
# # Create a client object. The client can be reused for multiple calls.
|
621
|
+
# client = Google::Cloud::Dialogflow::CX::V3::TransitionRouteGroups::Client.new
|
622
|
+
#
|
623
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
624
|
+
# request = Google::Cloud::Dialogflow::CX::V3::DeleteTransitionRouteGroupRequest.new
|
625
|
+
#
|
626
|
+
# # Call the delete_transition_route_group method.
|
627
|
+
# result = client.delete_transition_route_group request
|
628
|
+
#
|
629
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
630
|
+
# p result
|
631
|
+
#
|
543
632
|
def delete_transition_route_group request, options = nil
|
544
633
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
545
634
|
|
@@ -557,9 +646,11 @@ module Google
|
|
557
646
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
558
647
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
559
648
|
|
560
|
-
header_params = {
|
561
|
-
|
562
|
-
|
649
|
+
header_params = {}
|
650
|
+
if request.name
|
651
|
+
header_params["name"] = request.name
|
652
|
+
end
|
653
|
+
|
563
654
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
564
655
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
565
656
|
|
@@ -198,6 +198,27 @@ module Google
|
|
198
198
|
#
|
199
199
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
200
200
|
#
|
201
|
+
# @example Basic example
|
202
|
+
# require "google/cloud/dialogflow/cx/v3"
|
203
|
+
#
|
204
|
+
# # Create a client object. The client can be reused for multiple calls.
|
205
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
206
|
+
#
|
207
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
208
|
+
# request = Google::Cloud::Dialogflow::CX::V3::ListVersionsRequest.new
|
209
|
+
#
|
210
|
+
# # Call the list_versions method.
|
211
|
+
# result = client.list_versions request
|
212
|
+
#
|
213
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
214
|
+
# # iterate over all elements by calling #each, and the enumerable
|
215
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
216
|
+
# # methods are also available for managing paging directly.
|
217
|
+
# result.each do |response|
|
218
|
+
# # Each element is of type ::Google::Cloud::Dialogflow::CX::V3::Version.
|
219
|
+
# p response
|
220
|
+
# end
|
221
|
+
#
|
201
222
|
def list_versions request, options = nil
|
202
223
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
203
224
|
|
@@ -215,9 +236,11 @@ module Google
|
|
215
236
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
216
237
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
217
238
|
|
218
|
-
header_params = {
|
219
|
-
|
220
|
-
|
239
|
+
header_params = {}
|
240
|
+
if request.parent
|
241
|
+
header_params["parent"] = request.parent
|
242
|
+
end
|
243
|
+
|
221
244
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
222
245
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
223
246
|
|
@@ -269,6 +292,21 @@ module Google
|
|
269
292
|
#
|
270
293
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
271
294
|
#
|
295
|
+
# @example Basic example
|
296
|
+
# require "google/cloud/dialogflow/cx/v3"
|
297
|
+
#
|
298
|
+
# # Create a client object. The client can be reused for multiple calls.
|
299
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
300
|
+
#
|
301
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
302
|
+
# request = Google::Cloud::Dialogflow::CX::V3::GetVersionRequest.new
|
303
|
+
#
|
304
|
+
# # Call the get_version method.
|
305
|
+
# result = client.get_version request
|
306
|
+
#
|
307
|
+
# # The returned object is of type Google::Cloud::Dialogflow::CX::V3::Version.
|
308
|
+
# p result
|
309
|
+
#
|
272
310
|
def get_version request, options = nil
|
273
311
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
274
312
|
|
@@ -286,9 +324,11 @@ module Google
|
|
286
324
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
287
325
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
288
326
|
|
289
|
-
header_params = {
|
290
|
-
|
291
|
-
|
327
|
+
header_params = {}
|
328
|
+
if request.name
|
329
|
+
header_params["name"] = request.name
|
330
|
+
end
|
331
|
+
|
292
332
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
293
333
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
294
334
|
|
@@ -348,6 +388,28 @@ module Google
|
|
348
388
|
#
|
349
389
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
350
390
|
#
|
391
|
+
# @example Basic example
|
392
|
+
# require "google/cloud/dialogflow/cx/v3"
|
393
|
+
#
|
394
|
+
# # Create a client object. The client can be reused for multiple calls.
|
395
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
396
|
+
#
|
397
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
398
|
+
# request = Google::Cloud::Dialogflow::CX::V3::CreateVersionRequest.new
|
399
|
+
#
|
400
|
+
# # Call the create_version method.
|
401
|
+
# result = client.create_version request
|
402
|
+
#
|
403
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
404
|
+
# # object to check the status of an operation, cancel it, or wait
|
405
|
+
# # for results. Here is how to block until completion:
|
406
|
+
# result.wait_until_done! timeout: 60
|
407
|
+
# if result.response?
|
408
|
+
# p result.response
|
409
|
+
# else
|
410
|
+
# puts "Error!"
|
411
|
+
# end
|
412
|
+
#
|
351
413
|
def create_version request, options = nil
|
352
414
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
353
415
|
|
@@ -365,9 +427,11 @@ module Google
|
|
365
427
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
366
428
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
367
429
|
|
368
|
-
header_params = {
|
369
|
-
|
370
|
-
|
430
|
+
header_params = {}
|
431
|
+
if request.parent
|
432
|
+
header_params["parent"] = request.parent
|
433
|
+
end
|
434
|
+
|
371
435
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
372
436
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
373
437
|
|
@@ -420,6 +484,21 @@ module Google
|
|
420
484
|
#
|
421
485
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
422
486
|
#
|
487
|
+
# @example Basic example
|
488
|
+
# require "google/cloud/dialogflow/cx/v3"
|
489
|
+
#
|
490
|
+
# # Create a client object. The client can be reused for multiple calls.
|
491
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
492
|
+
#
|
493
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
494
|
+
# request = Google::Cloud::Dialogflow::CX::V3::UpdateVersionRequest.new
|
495
|
+
#
|
496
|
+
# # Call the update_version method.
|
497
|
+
# result = client.update_version request
|
498
|
+
#
|
499
|
+
# # The returned object is of type Google::Cloud::Dialogflow::CX::V3::Version.
|
500
|
+
# p result
|
501
|
+
#
|
423
502
|
def update_version request, options = nil
|
424
503
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
425
504
|
|
@@ -437,9 +516,11 @@ module Google
|
|
437
516
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
438
517
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
439
518
|
|
440
|
-
header_params = {
|
441
|
-
|
442
|
-
|
519
|
+
header_params = {}
|
520
|
+
if request.version&.name
|
521
|
+
header_params["version.name"] = request.version.name
|
522
|
+
end
|
523
|
+
|
443
524
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
444
525
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
445
526
|
|
@@ -490,6 +571,21 @@ module Google
|
|
490
571
|
#
|
491
572
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
492
573
|
#
|
574
|
+
# @example Basic example
|
575
|
+
# require "google/cloud/dialogflow/cx/v3"
|
576
|
+
#
|
577
|
+
# # Create a client object. The client can be reused for multiple calls.
|
578
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
579
|
+
#
|
580
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
581
|
+
# request = Google::Cloud::Dialogflow::CX::V3::DeleteVersionRequest.new
|
582
|
+
#
|
583
|
+
# # Call the delete_version method.
|
584
|
+
# result = client.delete_version request
|
585
|
+
#
|
586
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
587
|
+
# p result
|
588
|
+
#
|
493
589
|
def delete_version request, options = nil
|
494
590
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
495
591
|
|
@@ -507,9 +603,11 @@ module Google
|
|
507
603
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
508
604
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
509
605
|
|
510
|
-
header_params = {
|
511
|
-
|
512
|
-
|
606
|
+
header_params = {}
|
607
|
+
if request.name
|
608
|
+
header_params["name"] = request.name
|
609
|
+
end
|
610
|
+
|
513
611
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
514
612
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
515
613
|
|
@@ -574,6 +672,28 @@ module Google
|
|
574
672
|
#
|
575
673
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
576
674
|
#
|
675
|
+
# @example Basic example
|
676
|
+
# require "google/cloud/dialogflow/cx/v3"
|
677
|
+
#
|
678
|
+
# # Create a client object. The client can be reused for multiple calls.
|
679
|
+
# client = Google::Cloud::Dialogflow::CX::V3::Versions::Client.new
|
680
|
+
#
|
681
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
682
|
+
# request = Google::Cloud::Dialogflow::CX::V3::LoadVersionRequest.new
|
683
|
+
#
|
684
|
+
# # Call the load_version method.
|
685
|
+
# result = client.load_version request
|
686
|
+
#
|
687
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
688
|
+
# # object to check the status of an operation, cancel it, or wait
|
689
|
+
# # for results. Here is how to block until completion:
|
690
|
+
# result.wait_until_done! timeout: 60
|
691
|
+
# if result.response?
|
692
|
+
# p result.response
|
693
|
+
# else
|
694
|
+
# puts "Error!"
|
695
|
+
# end
|
696
|
+
#
|
577
697
|
def load_version request, options = nil
|
578
698
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
579
699
|
|
@@ -591,9 +711,11 @@ module Google
|
|
591
711
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
592
712
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
593
713
|
|
594
|
-
header_params = {
|
595
|
-
|
596
|
-
|
714
|
+
header_params = {}
|
715
|
+
if request.name
|
716
|
+
header_params["name"] = request.name
|
717
|
+
end
|
718
|
+
|
597
719
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
598
720
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
599
721
|
|
@@ -144,6 +144,27 @@ module Google
|
|
144
144
|
#
|
145
145
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
146
146
|
#
|
147
|
+
# @example Basic example
|
148
|
+
# require "google/longrunning"
|
149
|
+
#
|
150
|
+
# # Create a client object. The client can be reused for multiple calls.
|
151
|
+
# client = Google::Longrunning::Operations::Client.new
|
152
|
+
#
|
153
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
154
|
+
# request = Google::Longrunning::ListOperationsRequest.new
|
155
|
+
#
|
156
|
+
# # Call the list_operations method.
|
157
|
+
# result = client.list_operations request
|
158
|
+
#
|
159
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
160
|
+
# # iterate over all elements by calling #each, and the enumerable
|
161
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
162
|
+
# # methods are also available for managing paging directly.
|
163
|
+
# result.each do |response|
|
164
|
+
# # Each element is of type ::Google::Longrunning::Operation.
|
165
|
+
# p response
|
166
|
+
# end
|
167
|
+
#
|
147
168
|
def list_operations request, options = nil
|
148
169
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
149
170
|
|
@@ -161,9 +182,11 @@ module Google
|
|
161
182
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
162
183
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
163
184
|
|
164
|
-
header_params = {
|
165
|
-
|
166
|
-
|
185
|
+
header_params = {}
|
186
|
+
if request.name
|
187
|
+
header_params["name"] = request.name
|
188
|
+
end
|
189
|
+
|
167
190
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
168
191
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
169
192
|
|
@@ -216,6 +239,28 @@ module Google
|
|
216
239
|
#
|
217
240
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
218
241
|
#
|
242
|
+
# @example Basic example
|
243
|
+
# require "google/longrunning"
|
244
|
+
#
|
245
|
+
# # Create a client object. The client can be reused for multiple calls.
|
246
|
+
# client = Google::Longrunning::Operations::Client.new
|
247
|
+
#
|
248
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
249
|
+
# request = Google::Longrunning::GetOperationRequest.new
|
250
|
+
#
|
251
|
+
# # Call the get_operation method.
|
252
|
+
# result = client.get_operation request
|
253
|
+
#
|
254
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
255
|
+
# # object to check the status of an operation, cancel it, or wait
|
256
|
+
# # for results. Here is how to block until completion:
|
257
|
+
# result.wait_until_done! timeout: 60
|
258
|
+
# if result.response?
|
259
|
+
# p result.response
|
260
|
+
# else
|
261
|
+
# puts "Error!"
|
262
|
+
# end
|
263
|
+
#
|
219
264
|
def get_operation request, options = nil
|
220
265
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
221
266
|
|
@@ -233,9 +278,11 @@ module Google
|
|
233
278
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
234
279
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
235
280
|
|
236
|
-
header_params = {
|
237
|
-
|
238
|
-
|
281
|
+
header_params = {}
|
282
|
+
if request.name
|
283
|
+
header_params["name"] = request.name
|
284
|
+
end
|
285
|
+
|
239
286
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
240
287
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
241
288
|
|
@@ -288,6 +335,21 @@ module Google
|
|
288
335
|
#
|
289
336
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
290
337
|
#
|
338
|
+
# @example Basic example
|
339
|
+
# require "google/longrunning"
|
340
|
+
#
|
341
|
+
# # Create a client object. The client can be reused for multiple calls.
|
342
|
+
# client = Google::Longrunning::Operations::Client.new
|
343
|
+
#
|
344
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
345
|
+
# request = Google::Longrunning::DeleteOperationRequest.new
|
346
|
+
#
|
347
|
+
# # Call the delete_operation method.
|
348
|
+
# result = client.delete_operation request
|
349
|
+
#
|
350
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
351
|
+
# p result
|
352
|
+
#
|
291
353
|
def delete_operation request, options = nil
|
292
354
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
293
355
|
|
@@ -305,9 +367,11 @@ module Google
|
|
305
367
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
306
368
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
307
369
|
|
308
|
-
header_params = {
|
309
|
-
|
310
|
-
|
370
|
+
header_params = {}
|
371
|
+
if request.name
|
372
|
+
header_params["name"] = request.name
|
373
|
+
end
|
374
|
+
|
311
375
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
312
376
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
313
377
|
|
@@ -365,6 +429,21 @@ module Google
|
|
365
429
|
#
|
366
430
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
367
431
|
#
|
432
|
+
# @example Basic example
|
433
|
+
# require "google/longrunning"
|
434
|
+
#
|
435
|
+
# # Create a client object. The client can be reused for multiple calls.
|
436
|
+
# client = Google::Longrunning::Operations::Client.new
|
437
|
+
#
|
438
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
439
|
+
# request = Google::Longrunning::CancelOperationRequest.new
|
440
|
+
#
|
441
|
+
# # Call the cancel_operation method.
|
442
|
+
# result = client.cancel_operation request
|
443
|
+
#
|
444
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
445
|
+
# p result
|
446
|
+
#
|
368
447
|
def cancel_operation request, options = nil
|
369
448
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
370
449
|
|
@@ -382,9 +461,11 @@ module Google
|
|
382
461
|
gapic_version: ::Google::Cloud::Dialogflow::CX::V3::VERSION
|
383
462
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
384
463
|
|
385
|
-
header_params = {
|
386
|
-
|
387
|
-
|
464
|
+
header_params = {}
|
465
|
+
if request.name
|
466
|
+
header_params["name"] = request.name
|
467
|
+
end
|
468
|
+
|
388
469
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
389
470
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
390
471
|
|
@@ -445,6 +526,28 @@ module Google
|
|
445
526
|
#
|
446
527
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
447
528
|
#
|
529
|
+
# @example Basic example
|
530
|
+
# require "google/longrunning"
|
531
|
+
#
|
532
|
+
# # Create a client object. The client can be reused for multiple calls.
|
533
|
+
# client = Google::Longrunning::Operations::Client.new
|
534
|
+
#
|
535
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
536
|
+
# request = Google::Longrunning::WaitOperationRequest.new
|
537
|
+
#
|
538
|
+
# # Call the wait_operation method.
|
539
|
+
# result = client.wait_operation request
|
540
|
+
#
|
541
|
+
# # The returned object is of type Gapic::Operation. You can use this
|
542
|
+
# # object to check the status of an operation, cancel it, or wait
|
543
|
+
# # for results. Here is how to block until completion:
|
544
|
+
# result.wait_until_done! timeout: 60
|
545
|
+
# if result.response?
|
546
|
+
# p result.response
|
547
|
+
# else
|
548
|
+
# puts "Error!"
|
549
|
+
# end
|
550
|
+
#
|
448
551
|
def wait_operation request, options = nil
|
449
552
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
450
553
|
|