google-cloud-dialogflow-v2 0.12.0 → 0.15.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.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +1 -1
  3. data/AUTHENTICATION.md +7 -25
  4. data/README.md +1 -1
  5. data/lib/google/cloud/dialogflow/v2/agents/client.rb +1 -0
  6. data/lib/google/cloud/dialogflow/v2/answer_record_pb.rb +0 -1
  7. data/lib/google/cloud/dialogflow/v2/audio_config_pb.rb +0 -2
  8. data/lib/google/cloud/dialogflow/v2/conversation_dataset_pb.rb +92 -0
  9. data/lib/google/cloud/dialogflow/v2/conversation_dataset_services_pb.rb +81 -0
  10. data/lib/google/cloud/dialogflow/v2/conversation_datasets/client.rb +849 -0
  11. data/lib/google/cloud/dialogflow/v2/conversation_datasets/credentials.rb +52 -0
  12. data/lib/google/cloud/dialogflow/v2/conversation_datasets/operations.rb +767 -0
  13. data/lib/google/cloud/dialogflow/v2/conversation_datasets/paths.rb +69 -0
  14. data/lib/google/cloud/dialogflow/v2/conversation_datasets.rb +53 -0
  15. data/lib/google/cloud/dialogflow/v2/conversation_event_pb.rb +0 -1
  16. data/lib/google/cloud/dialogflow/v2/conversation_model_pb.rb +205 -0
  17. data/lib/google/cloud/dialogflow/v2/conversation_model_services_pb.rb +98 -0
  18. data/lib/google/cloud/dialogflow/v2/conversation_models/client.rb +1257 -0
  19. data/lib/google/cloud/dialogflow/v2/conversation_models/credentials.rb +52 -0
  20. data/lib/google/cloud/dialogflow/v2/conversation_models/operations.rb +767 -0
  21. data/lib/google/cloud/dialogflow/v2/conversation_models/paths.rb +179 -0
  22. data/lib/google/cloud/dialogflow/v2/conversation_models.rb +50 -0
  23. data/lib/google/cloud/dialogflow/v2/conversation_pb.rb +0 -1
  24. data/lib/google/cloud/dialogflow/v2/conversation_profile_pb.rb +31 -0
  25. data/lib/google/cloud/dialogflow/v2/conversation_profile_services_pb.rb +27 -0
  26. data/lib/google/cloud/dialogflow/v2/conversation_profiles/client.rb +250 -0
  27. data/lib/google/cloud/dialogflow/v2/conversation_profiles/operations.rb +767 -0
  28. data/lib/google/cloud/dialogflow/v2/conversation_profiles/paths.rb +31 -9
  29. data/lib/google/cloud/dialogflow/v2/conversation_profiles.rb +1 -0
  30. data/lib/google/cloud/dialogflow/v2/document_pb.rb +51 -0
  31. data/lib/google/cloud/dialogflow/v2/document_services_pb.rb +21 -0
  32. data/lib/google/cloud/dialogflow/v2/documents/client.rb +272 -2
  33. data/lib/google/cloud/dialogflow/v2/entity_types/client.rb +1 -0
  34. data/lib/google/cloud/dialogflow/v2/gcs_pb.rb +8 -1
  35. data/lib/google/cloud/dialogflow/v2/human_agent_assistant_event_pb.rb +0 -1
  36. data/lib/google/cloud/dialogflow/v2/intent_pb.rb +0 -2
  37. data/lib/google/cloud/dialogflow/v2/intents/client.rb +1 -0
  38. data/lib/google/cloud/dialogflow/v2/knowledge_base_pb.rb +1 -0
  39. data/lib/google/cloud/dialogflow/v2/knowledge_bases/client.rb +28 -1
  40. data/lib/google/cloud/dialogflow/v2/participant_pb.rb +22 -2
  41. data/lib/google/cloud/dialogflow/v2/participant_services_pb.rb +3 -0
  42. data/lib/google/cloud/dialogflow/v2/participants/client.rb +115 -7
  43. data/lib/google/cloud/dialogflow/v2/validation_result_pb.rb +0 -1
  44. data/lib/google/cloud/dialogflow/v2/version.rb +1 -1
  45. data/lib/google/cloud/dialogflow/v2/webhook_pb.rb +0 -1
  46. data/lib/google/cloud/dialogflow/v2.rb +4 -0
  47. data/proto_docs/google/api/resource.rb +10 -71
  48. data/proto_docs/google/cloud/dialogflow/v2/audio_config.rb +4 -1
  49. data/proto_docs/google/cloud/dialogflow/v2/conversation_dataset.rb +211 -0
  50. data/proto_docs/google/cloud/dialogflow/v2/conversation_model.rb +522 -0
  51. data/proto_docs/google/cloud/dialogflow/v2/conversation_profile.rb +100 -2
  52. data/proto_docs/google/cloud/dialogflow/v2/document.rb +157 -0
  53. data/proto_docs/google/cloud/dialogflow/v2/gcs.rb +50 -0
  54. data/proto_docs/google/cloud/dialogflow/v2/knowledge_base.rb +28 -0
  55. data/proto_docs/google/cloud/dialogflow/v2/participant.rb +123 -65
  56. metadata +21 -3
@@ -88,6 +88,9 @@ module Google
88
88
  # key-value pairs. Suggested use cases include storing a document's title,
89
89
  # an external URL distinct from the document's content_uri, etc.
90
90
  # The max size of a `key` or a `value` of the metadata is 1024 bytes.
91
+ # @!attribute [r] state
92
+ # @return [::Google::Cloud::Dialogflow::V2::Document::State]
93
+ # Output only. The current state of the document.
91
94
  class Document
92
95
  include ::Google::Protobuf::MessageExts
93
96
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -136,6 +139,30 @@ module Google
136
139
  # The entire document content as a whole can be used for query results.
137
140
  # Only for Contact Center Solutions on Dialogflow.
138
141
  ARTICLE_SUGGESTION = 3
142
+
143
+ # The document contains agent-facing Smart Reply entries.
144
+ AGENT_FACING_SMART_REPLY = 4
145
+ end
146
+
147
+ # Possible states of the document
148
+ module State
149
+ # The document state is unspecified.
150
+ STATE_UNSPECIFIED = 0
151
+
152
+ # The document creation is in progress.
153
+ CREATING = 1
154
+
155
+ # The document is active and ready to use.
156
+ ACTIVE = 2
157
+
158
+ # The document updation is in progress.
159
+ UPDATING = 3
160
+
161
+ # The document is reloading.
162
+ RELOADING = 4
163
+
164
+ # The document deletion is in progress.
165
+ DELETING = 5
139
166
  end
140
167
  end
141
168
 
@@ -163,6 +190,29 @@ module Google
163
190
  # @!attribute [rw] page_token
164
191
  # @return [::String]
165
192
  # The next_page_token value returned from a previous list request.
193
+ # @!attribute [rw] filter
194
+ # @return [::String]
195
+ # The filter expression used to filter documents returned by the list method.
196
+ # The expression has the following syntax:
197
+ #
198
+ # <field> <operator> <value> [AND <field> <operator> <value>] ...
199
+ #
200
+ # The following fields and operators are supported:
201
+ #
202
+ # * knowledge_types with has(:) operator
203
+ # * display_name with has(:) operator
204
+ # * state with equals(=) operator
205
+ #
206
+ # Examples:
207
+ #
208
+ # * "knowledge_types:FAQ" matches documents with FAQ knowledge type.
209
+ # * "display_name:customer" matches documents whose display name contains
210
+ # "customer".
211
+ # * "state=ACTIVE" matches documents with ACTIVE state.
212
+ # * "knowledge_types:FAQ AND state=ACTIVE" matches all active FAQ documents.
213
+ #
214
+ # For more information about filtering, see
215
+ # [API Filtering](https://aip.dev/160).
166
216
  class ListDocumentsRequest
167
217
  include ::Google::Protobuf::MessageExts
168
218
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -195,6 +245,68 @@ module Google
195
245
  extend ::Google::Protobuf::MessageExts::ClassMethods
196
246
  end
197
247
 
248
+ # Request message for {::Google::Cloud::Dialogflow::V2::Documents::Client#import_documents Documents.ImportDocuments}.
249
+ # @!attribute [rw] parent
250
+ # @return [::String]
251
+ # Required. The knowledge base to import documents into.
252
+ # Format: `projects/<Project ID>/locations/<Location
253
+ # ID>/knowledgeBases/<Knowledge Base ID>`.
254
+ # @!attribute [rw] gcs_source
255
+ # @return [::Google::Cloud::Dialogflow::V2::GcsSources]
256
+ # The Google Cloud Storage location for the documents.
257
+ # The path can include a wildcard.
258
+ #
259
+ # These URIs may have the forms
260
+ # `gs://<bucket-name>/<object-name>`.
261
+ # `gs://<bucket-name>/<object-path>/*.<extension>`.
262
+ # @!attribute [rw] document_template
263
+ # @return [::Google::Cloud::Dialogflow::V2::ImportDocumentTemplate]
264
+ # Required. Document template used for importing all the documents.
265
+ # @!attribute [rw] import_gcs_custom_metadata
266
+ # @return [::Boolean]
267
+ # Whether to import custom metadata from Google Cloud Storage.
268
+ # Only valid when the document source is Google Cloud Storage URI.
269
+ class ImportDocumentsRequest
270
+ include ::Google::Protobuf::MessageExts
271
+ extend ::Google::Protobuf::MessageExts::ClassMethods
272
+ end
273
+
274
+ # The template used for importing documents.
275
+ # @!attribute [rw] mime_type
276
+ # @return [::String]
277
+ # Required. The MIME type of the document.
278
+ # @!attribute [rw] knowledge_types
279
+ # @return [::Array<::Google::Cloud::Dialogflow::V2::Document::KnowledgeType>]
280
+ # Required. The knowledge type of document content.
281
+ # @!attribute [rw] metadata
282
+ # @return [::Google::Protobuf::Map{::String => ::String}]
283
+ # Metadata for the document. The metadata supports arbitrary
284
+ # key-value pairs. Suggested use cases include storing a document's title,
285
+ # an external URL distinct from the document's content_uri, etc.
286
+ # The max size of a `key` or a `value` of the metadata is 1024 bytes.
287
+ class ImportDocumentTemplate
288
+ include ::Google::Protobuf::MessageExts
289
+ extend ::Google::Protobuf::MessageExts::ClassMethods
290
+
291
+ # @!attribute [rw] key
292
+ # @return [::String]
293
+ # @!attribute [rw] value
294
+ # @return [::String]
295
+ class MetadataEntry
296
+ include ::Google::Protobuf::MessageExts
297
+ extend ::Google::Protobuf::MessageExts::ClassMethods
298
+ end
299
+ end
300
+
301
+ # Response message for {::Google::Cloud::Dialogflow::V2::Documents::Client#import_documents Documents.ImportDocuments}.
302
+ # @!attribute [rw] warnings
303
+ # @return [::Array<::Google::Rpc::Status>]
304
+ # Includes details about skipped documents or any other warnings.
305
+ class ImportDocumentsResponse
306
+ include ::Google::Protobuf::MessageExts
307
+ extend ::Google::Protobuf::MessageExts::ClassMethods
308
+ end
309
+
198
310
  # Request message for {::Google::Cloud::Dialogflow::V2::Documents::Client#delete_document Documents.DeleteDocument}.
199
311
  # @!attribute [rw] name
200
312
  # @return [::String]
@@ -233,15 +345,60 @@ module Google
233
345
  #
234
346
  # For documents stored in Google Cloud Storage, these URIs must have
235
347
  # the form `gs://<bucket-name>/<object-name>`.
348
+ # @!attribute [rw] import_gcs_custom_metadata
349
+ # @return [::Boolean]
350
+ # Optional. Whether to import custom metadata from Google Cloud Storage.
351
+ # Only valid when the document source is Google Cloud Storage URI.
352
+ # @!attribute [rw] smart_messaging_partial_update
353
+ # @return [::Boolean]
354
+ # Optional. When enabled, the reload request is to apply partial update to the smart
355
+ # messaging allowlist.
236
356
  class ReloadDocumentRequest
237
357
  include ::Google::Protobuf::MessageExts
238
358
  extend ::Google::Protobuf::MessageExts::ClassMethods
239
359
  end
240
360
 
361
+ # Request message for {::Google::Cloud::Dialogflow::V2::Documents::Client#export_document Documents.ExportDocument}.
362
+ # @!attribute [rw] name
363
+ # @return [::String]
364
+ # Required. The name of the document to export.
365
+ # Format: `projects/<Project ID>/locations/<Location
366
+ # ID>/knowledgeBases/<Knowledge Base ID>/documents/<Document ID>`.
367
+ # @!attribute [rw] gcs_destination
368
+ # @return [::Google::Cloud::Dialogflow::V2::GcsDestination]
369
+ # Cloud Storage file path to export the document.
370
+ # @!attribute [rw] export_full_content
371
+ # @return [::Boolean]
372
+ # When enabled, export the full content of the document including empirical
373
+ # probability.
374
+ # @!attribute [rw] smart_messaging_partial_update
375
+ # @return [::Boolean]
376
+ # When enabled, export the smart messaging allowlist document for partial
377
+ # update.
378
+ class ExportDocumentRequest
379
+ include ::Google::Protobuf::MessageExts
380
+ extend ::Google::Protobuf::MessageExts::ClassMethods
381
+ end
382
+
383
+ # Metadata related to the Export Data Operations (e.g. ExportDocument).
384
+ # @!attribute [rw] exported_gcs_destination
385
+ # @return [::Google::Cloud::Dialogflow::V2::GcsDestination]
386
+ # Cloud Storage file path of the exported data.
387
+ class ExportOperationMetadata
388
+ include ::Google::Protobuf::MessageExts
389
+ extend ::Google::Protobuf::MessageExts::ClassMethods
390
+ end
391
+
241
392
  # Metadata in google::longrunning::Operation for Knowledge operations.
242
393
  # @!attribute [r] state
243
394
  # @return [::Google::Cloud::Dialogflow::V2::KnowledgeOperationMetadata::State]
244
395
  # Output only. The current state of this operation.
396
+ # @!attribute [rw] knowledge_base
397
+ # @return [::String]
398
+ # The name of the knowledge base interacted with during the operation.
399
+ # @!attribute [rw] export_operation_metadata
400
+ # @return [::Google::Cloud::Dialogflow::V2::ExportOperationMetadata]
401
+ # Metadata for the Export Data Operation such as the destination of export.
245
402
  class KnowledgeOperationMetadata
246
403
  include ::Google::Protobuf::MessageExts
247
404
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -0,0 +1,50 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module Dialogflow
23
+ module V2
24
+ # Google Cloud Storage location for the inputs.
25
+ # @!attribute [rw] uris
26
+ # @return [::Array<::String>]
27
+ # Required. Google Cloud Storage URIs for the inputs. A URI is of the form:
28
+ # gs://bucket/object-prefix-or-name
29
+ # Whether a prefix or name is used depends on the use case.
30
+ class GcsSources
31
+ include ::Google::Protobuf::MessageExts
32
+ extend ::Google::Protobuf::MessageExts::ClassMethods
33
+ end
34
+
35
+ # Google Cloud Storage location for the output.
36
+ # @!attribute [rw] uri
37
+ # @return [::String]
38
+ # The Google Cloud Storage URIs for the output. A URI is of the
39
+ # form:
40
+ # gs://bucket/object-prefix-or-name
41
+ # Whether a prefix or name is used depends on the use case. The requesting
42
+ # user must have "write-permission" to the bucket.
43
+ class GcsDestination
44
+ include ::Google::Protobuf::MessageExts
45
+ extend ::Google::Protobuf::MessageExts::ClassMethods
46
+ end
47
+ end
48
+ end
49
+ end
50
+ end
@@ -63,6 +63,34 @@ module Google
63
63
  # @!attribute [rw] page_token
64
64
  # @return [::String]
65
65
  # The next_page_token value returned from a previous list request.
66
+ # @!attribute [rw] filter
67
+ # @return [::String]
68
+ # The filter expression used to filter knowledge bases returned by the list
69
+ # method. The expression has the following syntax:
70
+ #
71
+ # <field> <operator> <value> [AND <field> <operator> <value>] ...
72
+ #
73
+ # The following fields and operators are supported:
74
+ #
75
+ # * display_name with has(:) operator
76
+ # * language_code with equals(=) operator
77
+ #
78
+ # Examples:
79
+ #
80
+ # * 'language_code=en-us' matches knowledge bases with en-us language code.
81
+ # * 'display_name:articles' matches knowledge bases whose display name
82
+ # contains "articles".
83
+ # * 'display_name:"Best Articles"' matches knowledge bases whose display
84
+ # name contains "Best Articles".
85
+ # * 'language_code=en-gb AND display_name=articles' matches all knowledge
86
+ # bases whose display name contains "articles" and whose language code is
87
+ # "en-gb".
88
+ #
89
+ # Note: An empty filter string (i.e. "") is a no-op and will result in no
90
+ # filtering.
91
+ #
92
+ # For more information about filtering, see
93
+ # [API Filtering](https://aip.dev/160).
66
94
  class ListKnowledgeBasesRequest
67
95
  include ::Google::Protobuf::MessageExts
68
96
  extend ::Google::Protobuf::MessageExts::ClassMethods