google-cloud-dialogflow-v2 0.11.1 → 0.11.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (63) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/lib/google/cloud/dialogflow/v2/agent_pb.rb +2 -2
  4. data/lib/google/cloud/dialogflow/v2/agent_services_pb.rb +39 -5
  5. data/lib/google/cloud/dialogflow/v2/agents/client.rb +252 -31
  6. data/lib/google/cloud/dialogflow/v2/agents/operations.rb +115 -12
  7. data/lib/google/cloud/dialogflow/v2/answer_record_pb.rb +2 -2
  8. data/lib/google/cloud/dialogflow/v2/answer_record_services_pb.rb +1 -1
  9. data/lib/google/cloud/dialogflow/v2/answer_records/client.rb +46 -6
  10. data/lib/google/cloud/dialogflow/v2/audio_config_pb.rb +3 -2
  11. data/lib/google/cloud/dialogflow/v2/context_pb.rb +2 -2
  12. data/lib/google/cloud/dialogflow/v2/context_services_pb.rb +1 -1
  13. data/lib/google/cloud/dialogflow/v2/contexts/client.rb +126 -18
  14. data/lib/google/cloud/dialogflow/v2/conversation_event_pb.rb +2 -2
  15. data/lib/google/cloud/dialogflow/v2/conversation_pb.rb +2 -2
  16. data/lib/google/cloud/dialogflow/v2/conversation_profile_pb.rb +4 -2
  17. data/lib/google/cloud/dialogflow/v2/conversation_profile_services_pb.rb +1 -1
  18. data/lib/google/cloud/dialogflow/v2/conversation_profiles/client.rb +106 -15
  19. data/lib/google/cloud/dialogflow/v2/conversation_profiles/paths.rb +19 -0
  20. data/lib/google/cloud/dialogflow/v2/conversation_services_pb.rb +1 -1
  21. data/lib/google/cloud/dialogflow/v2/conversations/client.rb +112 -15
  22. data/lib/google/cloud/dialogflow/v2/document_pb.rb +2 -2
  23. data/lib/google/cloud/dialogflow/v2/document_services_pb.rb +27 -10
  24. data/lib/google/cloud/dialogflow/v2/documents/client.rb +180 -27
  25. data/lib/google/cloud/dialogflow/v2/documents/operations.rb +115 -12
  26. data/lib/google/cloud/dialogflow/v2/entity_type_pb.rb +2 -2
  27. data/lib/google/cloud/dialogflow/v2/entity_type_services_pb.rb +45 -1
  28. data/lib/google/cloud/dialogflow/v2/entity_types/client.rb +284 -30
  29. data/lib/google/cloud/dialogflow/v2/entity_types/operations.rb +115 -12
  30. data/lib/google/cloud/dialogflow/v2/environment_pb.rb +2 -2
  31. data/lib/google/cloud/dialogflow/v2/environment_services_pb.rb +1 -1
  32. data/lib/google/cloud/dialogflow/v2/environments/client.rb +132 -18
  33. data/lib/google/cloud/dialogflow/v2/fulfillment_pb.rb +2 -2
  34. data/lib/google/cloud/dialogflow/v2/fulfillment_services_pb.rb +1 -1
  35. data/lib/google/cloud/dialogflow/v2/fulfillments/client.rb +40 -6
  36. data/lib/google/cloud/dialogflow/v2/gcs_pb.rb +2 -2
  37. data/lib/google/cloud/dialogflow/v2/human_agent_assistant_event_pb.rb +2 -2
  38. data/lib/google/cloud/dialogflow/v2/intent_pb.rb +2 -2
  39. data/lib/google/cloud/dialogflow/v2/intent_services_pb.rb +16 -1
  40. data/lib/google/cloud/dialogflow/v2/intents/client.rb +175 -21
  41. data/lib/google/cloud/dialogflow/v2/intents/operations.rb +115 -12
  42. data/lib/google/cloud/dialogflow/v2/knowledge_base_pb.rb +2 -2
  43. data/lib/google/cloud/dialogflow/v2/knowledge_base_services_pb.rb +1 -1
  44. data/lib/google/cloud/dialogflow/v2/knowledge_bases/client.rb +106 -15
  45. data/lib/google/cloud/dialogflow/v2/participant_pb.rb +2 -2
  46. data/lib/google/cloud/dialogflow/v2/participant_services_pb.rb +1 -1
  47. data/lib/google/cloud/dialogflow/v2/participants/client.rb +146 -21
  48. data/lib/google/cloud/dialogflow/v2/session_entity_type_pb.rb +2 -2
  49. data/lib/google/cloud/dialogflow/v2/session_entity_type_services_pb.rb +1 -1
  50. data/lib/google/cloud/dialogflow/v2/session_entity_types/client.rb +106 -15
  51. data/lib/google/cloud/dialogflow/v2/session_pb.rb +2 -2
  52. data/lib/google/cloud/dialogflow/v2/session_services_pb.rb +15 -1
  53. data/lib/google/cloud/dialogflow/v2/sessions/client.rb +58 -3
  54. data/lib/google/cloud/dialogflow/v2/validation_result_pb.rb +1 -1
  55. data/lib/google/cloud/dialogflow/v2/version.rb +1 -1
  56. data/lib/google/cloud/dialogflow/v2/version_pb.rb +2 -2
  57. data/lib/google/cloud/dialogflow/v2/version_services_pb.rb +1 -1
  58. data/lib/google/cloud/dialogflow/v2/versions/client.rb +106 -15
  59. data/lib/google/cloud/dialogflow/v2/webhook_pb.rb +2 -2
  60. data/proto_docs/google/cloud/dialogflow/v2/agent.rb +4 -3
  61. data/proto_docs/google/cloud/dialogflow/v2/conversation_profile.rb +25 -8
  62. data/proto_docs/google/cloud/dialogflow/v2/session.rb +38 -33
  63. metadata +6 -5
@@ -184,6 +184,27 @@ module Google
184
184
  #
185
185
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
186
186
  #
187
+ # @example Basic example
188
+ # require "google/cloud/dialogflow/v2"
189
+ #
190
+ # # Create a client object. The client can be reused for multiple calls.
191
+ # client = Google::Cloud::Dialogflow::V2::ConversationProfiles::Client.new
192
+ #
193
+ # # Create a request. To set request fields, pass in keyword arguments.
194
+ # request = Google::Cloud::Dialogflow::V2::ListConversationProfilesRequest.new
195
+ #
196
+ # # Call the list_conversation_profiles method.
197
+ # result = client.list_conversation_profiles request
198
+ #
199
+ # # The returned object is of type Gapic::PagedEnumerable. You can
200
+ # # iterate over all elements by calling #each, and the enumerable
201
+ # # will lazily make API calls to fetch subsequent pages. Other
202
+ # # methods are also available for managing paging directly.
203
+ # result.each do |response|
204
+ # # Each element is of type ::Google::Cloud::Dialogflow::V2::ConversationProfile.
205
+ # p response
206
+ # end
207
+ #
187
208
  def list_conversation_profiles request, options = nil
188
209
  raise ::ArgumentError, "request must be provided" if request.nil?
189
210
 
@@ -201,9 +222,11 @@ module Google
201
222
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
202
223
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
203
224
 
204
- header_params = {
205
- "parent" => request.parent
206
- }
225
+ header_params = {}
226
+ if request.parent
227
+ header_params["parent"] = request.parent
228
+ end
229
+
207
230
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
208
231
  metadata[:"x-goog-request-params"] ||= request_params_header
209
232
 
@@ -255,6 +278,21 @@ module Google
255
278
  #
256
279
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
257
280
  #
281
+ # @example Basic example
282
+ # require "google/cloud/dialogflow/v2"
283
+ #
284
+ # # Create a client object. The client can be reused for multiple calls.
285
+ # client = Google::Cloud::Dialogflow::V2::ConversationProfiles::Client.new
286
+ #
287
+ # # Create a request. To set request fields, pass in keyword arguments.
288
+ # request = Google::Cloud::Dialogflow::V2::GetConversationProfileRequest.new
289
+ #
290
+ # # Call the get_conversation_profile method.
291
+ # result = client.get_conversation_profile request
292
+ #
293
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::ConversationProfile.
294
+ # p result
295
+ #
258
296
  def get_conversation_profile request, options = nil
259
297
  raise ::ArgumentError, "request must be provided" if request.nil?
260
298
 
@@ -272,9 +310,11 @@ module Google
272
310
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
273
311
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
274
312
 
275
- header_params = {
276
- "name" => request.name
277
- }
313
+ header_params = {}
314
+ if request.name
315
+ header_params["name"] = request.name
316
+ end
317
+
278
318
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
279
319
  metadata[:"x-goog-request-params"] ||= request_params_header
280
320
 
@@ -330,6 +370,21 @@ module Google
330
370
  #
331
371
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
332
372
  #
373
+ # @example Basic example
374
+ # require "google/cloud/dialogflow/v2"
375
+ #
376
+ # # Create a client object. The client can be reused for multiple calls.
377
+ # client = Google::Cloud::Dialogflow::V2::ConversationProfiles::Client.new
378
+ #
379
+ # # Create a request. To set request fields, pass in keyword arguments.
380
+ # request = Google::Cloud::Dialogflow::V2::CreateConversationProfileRequest.new
381
+ #
382
+ # # Call the create_conversation_profile method.
383
+ # result = client.create_conversation_profile request
384
+ #
385
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::ConversationProfile.
386
+ # p result
387
+ #
333
388
  def create_conversation_profile request, options = nil
334
389
  raise ::ArgumentError, "request must be provided" if request.nil?
335
390
 
@@ -347,9 +402,11 @@ module Google
347
402
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
348
403
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
349
404
 
350
- header_params = {
351
- "parent" => request.parent
352
- }
405
+ header_params = {}
406
+ if request.parent
407
+ header_params["parent"] = request.parent
408
+ end
409
+
353
410
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
354
411
  metadata[:"x-goog-request-params"] ||= request_params_header
355
412
 
@@ -404,6 +461,21 @@ module Google
404
461
  #
405
462
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
406
463
  #
464
+ # @example Basic example
465
+ # require "google/cloud/dialogflow/v2"
466
+ #
467
+ # # Create a client object. The client can be reused for multiple calls.
468
+ # client = Google::Cloud::Dialogflow::V2::ConversationProfiles::Client.new
469
+ #
470
+ # # Create a request. To set request fields, pass in keyword arguments.
471
+ # request = Google::Cloud::Dialogflow::V2::UpdateConversationProfileRequest.new
472
+ #
473
+ # # Call the update_conversation_profile method.
474
+ # result = client.update_conversation_profile request
475
+ #
476
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::ConversationProfile.
477
+ # p result
478
+ #
407
479
  def update_conversation_profile request, options = nil
408
480
  raise ::ArgumentError, "request must be provided" if request.nil?
409
481
 
@@ -421,9 +493,11 @@ module Google
421
493
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
422
494
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
423
495
 
424
- header_params = {
425
- "conversation_profile.name" => request.conversation_profile.name
426
- }
496
+ header_params = {}
497
+ if request.conversation_profile&.name
498
+ header_params["conversation_profile.name"] = request.conversation_profile.name
499
+ end
500
+
427
501
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
428
502
  metadata[:"x-goog-request-params"] ||= request_params_header
429
503
 
@@ -474,6 +548,21 @@ module Google
474
548
  #
475
549
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
476
550
  #
551
+ # @example Basic example
552
+ # require "google/cloud/dialogflow/v2"
553
+ #
554
+ # # Create a client object. The client can be reused for multiple calls.
555
+ # client = Google::Cloud::Dialogflow::V2::ConversationProfiles::Client.new
556
+ #
557
+ # # Create a request. To set request fields, pass in keyword arguments.
558
+ # request = Google::Cloud::Dialogflow::V2::DeleteConversationProfileRequest.new
559
+ #
560
+ # # Call the delete_conversation_profile method.
561
+ # result = client.delete_conversation_profile request
562
+ #
563
+ # # The returned object is of type Google::Protobuf::Empty.
564
+ # p result
565
+ #
477
566
  def delete_conversation_profile request, options = nil
478
567
  raise ::ArgumentError, "request must be provided" if request.nil?
479
568
 
@@ -491,9 +580,11 @@ module Google
491
580
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
492
581
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
493
582
 
494
- header_params = {
495
- "name" => request.name
496
- }
583
+ header_params = {}
584
+ if request.name
585
+ header_params["name"] = request.name
586
+ end
587
+
497
588
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
498
589
  metadata[:"x-goog-request-params"] ||= request_params_header
499
590
 
@@ -60,6 +60,25 @@ module Google
60
60
  resource.call(**args)
61
61
  end
62
62
 
63
+ ##
64
+ # Create a fully-qualified CXSecuritySettings resource string.
65
+ #
66
+ # The resource will be in the following format:
67
+ #
68
+ # `projects/{project}/locations/{location}/securitySettings/{security_settings}`
69
+ #
70
+ # @param project [String]
71
+ # @param location [String]
72
+ # @param security_settings [String]
73
+ #
74
+ # @return [::String]
75
+ def cx_security_settings_path project:, location:, security_settings:
76
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
77
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
78
+
79
+ "projects/#{project}/locations/#{location}/securitySettings/#{security_settings}"
80
+ end
81
+
63
82
  ##
64
83
  # Create a fully-qualified ConversationModel resource string.
65
84
  #
@@ -27,7 +27,7 @@ module Google
27
27
  # Service for managing [Conversations][google.cloud.dialogflow.v2.Conversation].
28
28
  class Service
29
29
 
30
- include GRPC::GenericService
30
+ include ::GRPC::GenericService
31
31
 
32
32
  self.marshal_class_method = :encode
33
33
  self.unmarshal_class_method = :decode
@@ -209,6 +209,21 @@ module Google
209
209
  #
210
210
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
211
211
  #
212
+ # @example Basic example
213
+ # require "google/cloud/dialogflow/v2"
214
+ #
215
+ # # Create a client object. The client can be reused for multiple calls.
216
+ # client = Google::Cloud::Dialogflow::V2::Conversations::Client.new
217
+ #
218
+ # # Create a request. To set request fields, pass in keyword arguments.
219
+ # request = Google::Cloud::Dialogflow::V2::CreateConversationRequest.new
220
+ #
221
+ # # Call the create_conversation method.
222
+ # result = client.create_conversation request
223
+ #
224
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::Conversation.
225
+ # p result
226
+ #
212
227
  def create_conversation request, options = nil
213
228
  raise ::ArgumentError, "request must be provided" if request.nil?
214
229
 
@@ -226,9 +241,11 @@ module Google
226
241
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
227
242
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
228
243
 
229
- header_params = {
230
- "parent" => request.parent
231
- }
244
+ header_params = {}
245
+ if request.parent
246
+ header_params["parent"] = request.parent
247
+ end
248
+
232
249
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
233
250
  metadata[:"x-goog-request-params"] ||= request_params_header
234
251
 
@@ -301,6 +318,27 @@ module Google
301
318
  #
302
319
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
303
320
  #
321
+ # @example Basic example
322
+ # require "google/cloud/dialogflow/v2"
323
+ #
324
+ # # Create a client object. The client can be reused for multiple calls.
325
+ # client = Google::Cloud::Dialogflow::V2::Conversations::Client.new
326
+ #
327
+ # # Create a request. To set request fields, pass in keyword arguments.
328
+ # request = Google::Cloud::Dialogflow::V2::ListConversationsRequest.new
329
+ #
330
+ # # Call the list_conversations method.
331
+ # result = client.list_conversations request
332
+ #
333
+ # # The returned object is of type Gapic::PagedEnumerable. You can
334
+ # # iterate over all elements by calling #each, and the enumerable
335
+ # # will lazily make API calls to fetch subsequent pages. Other
336
+ # # methods are also available for managing paging directly.
337
+ # result.each do |response|
338
+ # # Each element is of type ::Google::Cloud::Dialogflow::V2::Conversation.
339
+ # p response
340
+ # end
341
+ #
304
342
  def list_conversations request, options = nil
305
343
  raise ::ArgumentError, "request must be provided" if request.nil?
306
344
 
@@ -318,9 +356,11 @@ module Google
318
356
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
319
357
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
320
358
 
321
- header_params = {
322
- "parent" => request.parent
323
- }
359
+ header_params = {}
360
+ if request.parent
361
+ header_params["parent"] = request.parent
362
+ end
363
+
324
364
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
325
365
  metadata[:"x-goog-request-params"] ||= request_params_header
326
366
 
@@ -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/v2"
417
+ #
418
+ # # Create a client object. The client can be reused for multiple calls.
419
+ # client = Google::Cloud::Dialogflow::V2::Conversations::Client.new
420
+ #
421
+ # # Create a request. To set request fields, pass in keyword arguments.
422
+ # request = Google::Cloud::Dialogflow::V2::GetConversationRequest.new
423
+ #
424
+ # # Call the get_conversation method.
425
+ # result = client.get_conversation request
426
+ #
427
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::Conversation.
428
+ # p result
429
+ #
375
430
  def get_conversation 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::V2::VERSION
390
445
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
391
446
 
392
- header_params = {
393
- "name" => request.name
394
- }
447
+ header_params = {}
448
+ if request.name
449
+ header_params["name"] = request.name
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
 
@@ -443,6 +500,21 @@ module Google
443
500
  #
444
501
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
445
502
  #
503
+ # @example Basic example
504
+ # require "google/cloud/dialogflow/v2"
505
+ #
506
+ # # Create a client object. The client can be reused for multiple calls.
507
+ # client = Google::Cloud::Dialogflow::V2::Conversations::Client.new
508
+ #
509
+ # # Create a request. To set request fields, pass in keyword arguments.
510
+ # request = Google::Cloud::Dialogflow::V2::CompleteConversationRequest.new
511
+ #
512
+ # # Call the complete_conversation method.
513
+ # result = client.complete_conversation request
514
+ #
515
+ # # The returned object is of type Google::Cloud::Dialogflow::V2::Conversation.
516
+ # p result
517
+ #
446
518
  def complete_conversation request, options = nil
447
519
  raise ::ArgumentError, "request must be provided" if request.nil?
448
520
 
@@ -460,9 +532,11 @@ module Google
460
532
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
461
533
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
462
534
 
463
- header_params = {
464
- "name" => request.name
465
- }
535
+ header_params = {}
536
+ if request.name
537
+ header_params["name"] = request.name
538
+ end
539
+
466
540
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
467
541
  metadata[:"x-goog-request-params"] ||= request_params_header
468
542
 
@@ -531,6 +605,27 @@ module Google
531
605
  #
532
606
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
533
607
  #
608
+ # @example Basic example
609
+ # require "google/cloud/dialogflow/v2"
610
+ #
611
+ # # Create a client object. The client can be reused for multiple calls.
612
+ # client = Google::Cloud::Dialogflow::V2::Conversations::Client.new
613
+ #
614
+ # # Create a request. To set request fields, pass in keyword arguments.
615
+ # request = Google::Cloud::Dialogflow::V2::ListMessagesRequest.new
616
+ #
617
+ # # Call the list_messages method.
618
+ # result = client.list_messages request
619
+ #
620
+ # # The returned object is of type Gapic::PagedEnumerable. You can
621
+ # # iterate over all elements by calling #each, and the enumerable
622
+ # # will lazily make API calls to fetch subsequent pages. Other
623
+ # # methods are also available for managing paging directly.
624
+ # result.each do |response|
625
+ # # Each element is of type ::Google::Cloud::Dialogflow::V2::Message.
626
+ # p response
627
+ # end
628
+ #
534
629
  def list_messages request, options = nil
535
630
  raise ::ArgumentError, "request must be provided" if request.nil?
536
631
 
@@ -548,9 +643,11 @@ module Google
548
643
  gapic_version: ::Google::Cloud::Dialogflow::V2::VERSION
549
644
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
550
645
 
551
- header_params = {
552
- "parent" => request.parent
553
- }
646
+ header_params = {}
647
+ if request.parent
648
+ header_params["parent"] = request.parent
649
+ end
650
+
554
651
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
555
652
  metadata[:"x-goog-request-params"] ||= request_params_header
556
653
 
@@ -1,8 +1,6 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/dialogflow/v2/document.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/client_pb'
8
6
  require 'google/api/field_behavior_pb'
@@ -11,6 +9,8 @@ require 'google/longrunning/operations_pb'
11
9
  require 'google/protobuf/field_mask_pb'
12
10
  require 'google/protobuf/timestamp_pb'
13
11
  require 'google/rpc/status_pb'
12
+ require 'google/protobuf'
13
+
14
14
  Google::Protobuf::DescriptorPool.generated_pool.build do
15
15
  add_file("google/cloud/dialogflow/v2/document.proto", :syntax => :proto3) do
16
16
  add_message "google.cloud.dialogflow.v2.Document" do
@@ -27,7 +27,7 @@ module Google
27
27
  # Service for managing knowledge [Documents][google.cloud.dialogflow.v2.Document].
28
28
  class Service
29
29
 
30
- include GRPC::GenericService
30
+ include ::GRPC::GenericService
31
31
 
32
32
  self.marshal_class_method = :encode
33
33
  self.unmarshal_class_method = :decode
@@ -39,29 +39,46 @@ module Google
39
39
  rpc :GetDocument, ::Google::Cloud::Dialogflow::V2::GetDocumentRequest, ::Google::Cloud::Dialogflow::V2::Document
40
40
  # Creates a new document.
41
41
  #
42
- # Operation <response: [Document][google.cloud.dialogflow.v2.Document],
43
- # metadata: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]>
42
+ # This method is a [long-running
43
+ # operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
44
+ # The returned `Operation` type has the following method-specific fields:
45
+ #
46
+ # - `metadata`: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]
47
+ # - `response`: [Document][google.cloud.dialogflow.v2.Document]
44
48
  rpc :CreateDocument, ::Google::Cloud::Dialogflow::V2::CreateDocumentRequest, ::Google::Longrunning::Operation
45
49
  # Deletes the specified document.
46
50
  #
47
- # Operation <response: [google.protobuf.Empty][google.protobuf.Empty],
48
- # metadata: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]>
51
+ # This method is a [long-running
52
+ # operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
53
+ # The returned `Operation` type has the following method-specific fields:
54
+ #
55
+ # - `metadata`: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]
56
+ # - `response`: An [Empty
57
+ # message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
49
58
  rpc :DeleteDocument, ::Google::Cloud::Dialogflow::V2::DeleteDocumentRequest, ::Google::Longrunning::Operation
50
59
  # Updates the specified document.
51
60
  #
52
- # Operation <response: [Document][google.cloud.dialogflow.v2.Document],
53
- # metadata: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]>
61
+ # This method is a [long-running
62
+ # operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
63
+ # The returned `Operation` type has the following method-specific fields:
64
+ #
65
+ # - `metadata`: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]
66
+ # - `response`: [Document][google.cloud.dialogflow.v2.Document]
54
67
  rpc :UpdateDocument, ::Google::Cloud::Dialogflow::V2::UpdateDocumentRequest, ::Google::Longrunning::Operation
55
68
  # Reloads the specified document from its specified source, content_uri or
56
69
  # content. The previously loaded content of the document will be deleted.
57
70
  # Note: Even when the content of the document has not changed, there still
58
71
  # may be side effects because of internal implementation changes.
59
72
  #
73
+ # This method is a [long-running
74
+ # operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
75
+ # The returned `Operation` type has the following method-specific fields:
76
+ #
77
+ # - `metadata`: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]
78
+ # - `response`: [Document][google.cloud.dialogflow.v2.Document]
79
+ #
60
80
  # Note: The `projects.agent.knowledgeBases.documents` resource is deprecated;
61
81
  # only use `projects.knowledgeBases.documents`.
62
- #
63
- # Operation <response: [Document][google.cloud.dialogflow.v2.Document],
64
- # metadata: [KnowledgeOperationMetadata][google.cloud.dialogflow.v2.KnowledgeOperationMetadata]>
65
82
  rpc :ReloadDocument, ::Google::Cloud::Dialogflow::V2::ReloadDocumentRequest, ::Google::Longrunning::Operation
66
83
  end
67
84