ibm_watson 1.4.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (38) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +43 -6
  3. data/lib/ibm_watson/assistant_v1.rb +213 -195
  4. data/lib/ibm_watson/assistant_v2.rb +221 -20
  5. data/lib/ibm_watson/compare_comply_v1.rb +35 -21
  6. data/lib/ibm_watson/discovery_v1.rb +132 -13
  7. data/lib/ibm_watson/discovery_v2.rb +734 -21
  8. data/lib/ibm_watson/language_translator_v3.rb +205 -67
  9. data/lib/ibm_watson/natural_language_classifier_v1.rb +4 -2
  10. data/lib/ibm_watson/natural_language_understanding_v1.rb +21 -21
  11. data/lib/ibm_watson/personality_insights_v3.rb +27 -18
  12. data/lib/ibm_watson/speech_to_text_v1.rb +65 -53
  13. data/lib/ibm_watson/text_to_speech_v1.rb +124 -140
  14. data/lib/ibm_watson/tone_analyzer_v3.rb +12 -13
  15. data/lib/ibm_watson/version.rb +1 -1
  16. data/lib/ibm_watson/visual_recognition_v3.rb +33 -16
  17. data/lib/ibm_watson/visual_recognition_v4.rb +103 -17
  18. data/test/integration/test_assistant_v1.rb +9 -0
  19. data/test/integration/test_assistant_v2.rb +34 -0
  20. data/test/integration/test_discovery_v2.rb +132 -6
  21. data/test/integration/test_language_translator_v3.rb +5 -0
  22. data/test/integration/test_text_to_speech_v1.rb +3 -3
  23. data/test/integration/test_visual_recognition_v4.rb +9 -0
  24. data/test/unit/test_assistant_v1.rb +150 -99
  25. data/test/unit/test_assistant_v2.rb +153 -8
  26. data/test/unit/test_compare_comply_v1.rb +20 -20
  27. data/test/unit/test_discovery_v1.rb +125 -125
  28. data/test/unit/test_discovery_v2.rb +262 -29
  29. data/test/unit/test_language_translator_v3.rb +85 -24
  30. data/test/unit/test_natural_language_classifier_v1.rb +17 -17
  31. data/test/unit/test_natural_language_understanding_v1.rb +10 -10
  32. data/test/unit/test_personality_insights_v3.rb +14 -14
  33. data/test/unit/test_speech_to_text_v1.rb +97 -97
  34. data/test/unit/test_text_to_speech_v1.rb +48 -48
  35. data/test/unit/test_tone_analyzer_v3.rb +12 -12
  36. data/test/unit/test_visual_recognition_v3.rb +16 -16
  37. data/test/unit/test_visual_recognition_v4.rb +56 -38
  38. metadata +8 -7
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2d4c227c6c5c5022489eaf6a69b8b674ec91facde966f3e077b9c53c969ccd80
4
- data.tar.gz: 1eed5dfb21f288d25d555828a741c5836b6b25c984d7f2b1eb3de2a9f703f977
3
+ metadata.gz: 59e70245c69cc0c8ff09a9c024fbb73e4be55abb91f5c06dcdc46388de5fa5a1
4
+ data.tar.gz: '0378d428841351356f8053d32c8050ff0aea685e19549df088a1b38e4b2e6150'
5
5
  SHA512:
6
- metadata.gz: f8a58cdc4bc68c22395584350e43e47d3d93a82602d41443dfb7160f9887241d76616372ec8a77f596686b47a7216a26b710107776d19c601f54dd05e2a20089
7
- data.tar.gz: 5e80aa7bba94a5951ac4bbfae545c82a72f161f360b7e4b9633da07461d3ef679ceeb54880552216c84a33b7d8407599ac85035926f3b830fa9351664c70a4bf
6
+ metadata.gz: 5c855e9a0ef9b6e2e2e88ed485a2b3bfc693c249ecbf84b6ec8a7294a9b6222e421fb5ae1d3444ddb987337ce89e1cac0884cae5eb3494698f5b032a1acf29c9
7
+ data.tar.gz: a56164a62847bcbdc7b260d159c387f8476b1afb3bdf8937d8395e25e64fef4295f29745218e777f647e6202057c38cf633e821b7db9945aacbbc5def4770f3d
data/README.md CHANGED
@@ -1,13 +1,17 @@
1
1
  # IBM Watson Ruby SDK
2
2
 
3
- [![Build Status](https://travis-ci.org/watson-developer-cloud/ruby-sdk.svg)](https://travis-ci.org/watson-developer-cloud/ruby-sdk)
4
- [![Build status](https://ci.appveyor.com/api/projects/status/ir3k0ue138o4u67e?svg=true)](https://ci.appveyor.com/project/maxnussbaum/ruby-sdk)
3
+ [![Build and Test](https://github.com/watson-developer-cloud/ruby-sdk/workflows/Build%20and%20Test/badge.svg?branch=master)](https://github.com/watson-developer-cloud/ruby-sdk/actions?query=workflow%3A"Build+and+Test")
4
+ [![Deploy and Publish](https://github.com/watson-developer-cloud/ruby-sdk/workflows/Deploy%20and%20Publish/badge.svg?branch=master)](https://github.com/watson-developer-cloud/ruby-sdk/actions?query=workflow%3A%22Deploy+and+Publish%22)
5
5
  [![Slack](https://wdc-slack-inviter.mybluemix.net/badge.svg)](https://wdc-slack-inviter.mybluemix.net)
6
6
  [![codecov.io](https://codecov.io/github/watson-developer-cloud/ruby-sdk/coverage.svg)](https://codecov.io/github/watson-developer-cloud/ruby-sdk)
7
7
  [![Gem Version](https://badge.fury.io/rb/ibm_watson.svg)](https://badge.fury.io/rb/ibm_watson)
8
8
  [![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)
9
9
  [![CLA assistant](https://cla-assistant.io/readme/badge/watson-developer-cloud/ruby-sdk)](https://cla-assistant.io/watson-developer-cloud/ruby-sdk)
10
10
 
11
+ ## Deprecated builds
12
+ [![Build Status](https://travis-ci.org/watson-developer-cloud/ruby-sdk.svg)](https://travis-ci.org/watson-developer-cloud/ruby-sdk)
13
+ [![Build status](https://ci.appveyor.com/api/projects/status/ir3k0ue138o4u67e?svg=true)](https://ci.appveyor.com/project/maxnussbaum/ruby-sdk)
14
+
11
15
  Ruby gem to quickly get started with the various [IBM Watson][wdc] services.
12
16
 
13
17
  <details>
@@ -34,6 +38,21 @@ Ruby gem to quickly get started with the various [IBM Watson][wdc] services.
34
38
 
35
39
  </details>
36
40
 
41
+ ## ANNOUNCEMENTS!
42
+ ### Updating endpoint URLs from watsonplatform.net
43
+ Watson API endpoint URLs at watsonplatform.net are changing and will not work after 26 May 2021. Update your calls to use the newer endpoint URLs. For more information, see https://cloud.ibm.com/docs/watson?topic=watson-endpoint-change.
44
+
45
+ ### Personality Insights deprecation
46
+ IBM Watson™ Personality Insights is discontinued. For a period of one year from 1 December 2020, you will still be able to use Watson Personality Insights. However, as of 1 December 2021, the offering will no longer be available.
47
+
48
+ As an alternative, we encourage you to consider migrating to IBM Watson™ [Natural Language Understanding](https://cloud.ibm.com/docs/natural-language-understanding), a service on IBM Cloud® that uses deep learning to extract data and insights from text such as keywords, categories, sentiment, emotion, and syntax to provide insights for your business or industry. For more information, see About Natural Language Understanding.
49
+
50
+ ### Visual Recognition deprecation
51
+ IBM Watson™ Visual Recognition is discontinued. Existing instances are supported until 1 December 2021, but as of 7 January 2021, you can't create instances. Any instance that is provisioned on 1 December 2021 will be deleted.
52
+
53
+ ### Compare and Comply deprecation
54
+ IBM Watson™ Compare and Comply is discontinued. Existing instances are supported until 30 November 2021, but as of 1 December 2020, you can't create instances. Any instance that exists on 30 November 2021 will be deleted. Consider migrating to Watson Discovery Premium on IBM Cloud for your Compare and Comply use cases. To start the migration process, visit https://ibm.biz/contact-wdc-premium.
55
+
37
56
  ## Before you begin
38
57
 
39
58
  * You need an [IBM Cloud][ibm-cloud-onboarding] account.
@@ -106,7 +125,7 @@ The file downloaded will be called `ibm-credentials.env`. This is the name the S
106
125
  discovery = DiscoveryV1(version: "2018-08-01")
107
126
  ```
108
127
 
109
- And that's it!
128
+ And that's it!
110
129
 
111
130
  If you're using more than one service at a time in your code and get two different `ibm-credentials.env` files, just put the contents together in one `ibm-credentials.env` file and the SDK will handle assigning credentials to their appropriate services.
112
131
 
@@ -269,7 +288,7 @@ Result: "<response returned by service>"
269
288
 
270
289
  ### Transaction IDs
271
290
 
272
- Every SDK call will return a response which will contain a transaction ID, accessible via the `x-global-transaction-id` header. This transaction ID is useful for troubleshooting and accessing relevant logs from your service instance.
291
+ Every SDK call returns a response with a transaction ID in the `X-Global-Transaction-Id` header. Together the service instance region, this ID helps support teams troubleshoot issues from relevant logs.
273
292
 
274
293
  ```ruby
275
294
  require "ibm_watson"
@@ -289,6 +308,22 @@ rescue IBMCloudSdkCore::ApiException => e
289
308
  end
290
309
  ```
291
310
 
311
+ However, the transaction ID isn't available when the API doesn't return a response for some reason. In that case, you can set your own transaction ID in the request. For example, replace `<my-unique-transaction-id>` in the following example with a unique transaction ID.
312
+
313
+ ```ruby
314
+ require "ibm_watson"
315
+ include IBMWatson
316
+
317
+ assistant = AssistantV1.new(
318
+ authenticator: "<authenticator>"
319
+ version: "2017-04-21"
320
+ )
321
+
322
+ response = assistant.headers(
323
+ "X-Global-Transaction-Id" => "<my-unique-transaction-id>"
324
+ ).list_workspaces
325
+ ```
326
+
292
327
  ## Configuring the HTTP client
293
328
 
294
329
  To set client configs like timeout or proxy use the `configure_http_client` function and pass in the configurations.
@@ -398,8 +433,10 @@ If you have issues with the APIs or have a question about the Watson services, s
398
433
 
399
434
  Tested on:
400
435
 
401
- * MRI Ruby (RVM): 2.3.7, 2.4.4, 2.5.1
402
- * RubyInstaller (Windows x64): 2.3.3, 2.4.4, 2.5.1
436
+ * MRI Ruby (RVM): 2.5.1, 2.6.1
437
+ * RubyInstaller (Windows x64): 2.5.1, 2.6.1
438
+
439
+ 2.3.7 and 2.4.4 should still work but support will be deprecated in next major release.
403
440
 
404
441
  ## Contributing
405
442
 
@@ -13,7 +13,9 @@
13
13
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
14
  # See the License for the specific language governing permissions and
15
15
  # limitations under the License.
16
-
16
+ #
17
+ # IBM OpenAPI SDK Code Generator Version: 3.19.0-be3b4618-20201113-200858
18
+ #
17
19
  # The IBM Watson&trade; Assistant service combines machine learning, natural language
18
20
  # understanding, and an integrated dialog editor to create conversation flows between your
19
21
  # apps and your users.
@@ -34,22 +36,15 @@ module IBMWatson
34
36
  class AssistantV1 < IBMCloudSdkCore::BaseService
35
37
  include Concurrent::Async
36
38
  DEFAULT_SERVICE_NAME = "assistant"
37
- DEFAULT_SERVICE_URL = "https://gateway.watsonplatform.net/assistant/api"
39
+ DEFAULT_SERVICE_URL = "https://api.us-south.assistant.watson.cloud.ibm.com"
40
+ attr_accessor :version
38
41
  ##
39
42
  # @!method initialize(args)
40
43
  # Construct a new client for the Assistant service.
41
44
  #
42
45
  # @param args [Hash] The args to initialize with
43
- # @option args version [String] The API version date to use with the service, in
44
- # "YYYY-MM-DD" format. Whenever the API is changed in a backwards
45
- # incompatible way, a new minor version of the API is released.
46
- # The service uses the API version for the date you specify, or
47
- # the most recent version before that date. Note that you should
48
- # not programmatically specify the current date at runtime, in
49
- # case the API has been updated since your application's release.
50
- # Instead, specify a version date that is compatible with your
51
- # application, and don't change it until your application is
52
- # ready for a later version.
46
+ # @option args version [String] Release date of the API version you want to use. Specify dates in YYYY-MM-DD
47
+ # format. The current version is `2020-04-01`.
53
48
  # @option args service_url [String] The base service URL to use when contacting the service.
54
49
  # The base service_url may differ between IBM Cloud regions.
55
50
  # @option args authenticator [Object] The Authenticator instance to be configured for this service.
@@ -58,10 +53,10 @@ module IBMWatson
58
53
  def initialize(args = {})
59
54
  @__async_initialized__ = false
60
55
  defaults = {}
61
- defaults[:version] = nil
62
56
  defaults[:service_url] = DEFAULT_SERVICE_URL
63
57
  defaults[:service_name] = DEFAULT_SERVICE_NAME
64
58
  defaults[:authenticator] = nil
59
+ defaults[:version] = nil
65
60
  user_service_url = args[:service_url] unless args[:service_url].nil?
66
61
  args = defaults.merge(args)
67
62
  @version = args[:version]
@@ -85,8 +80,6 @@ module IBMWatson
85
80
  # API offers significant advantages, including ease of deployment, automatic state
86
81
  # management, versioning, and search capabilities. For more information, see the
87
82
  # [documentation](https://cloud.ibm.com/docs/assistant?topic=assistant-api-overview).
88
- #
89
- # There is no rate limit for this operation.
90
83
  # @param workspace_id [String] Unique identifier of the workspace.
91
84
  # @param input [MessageInput] An input object that includes the input text.
92
85
  # @param intents [Array[RuntimeIntent]] Intents to use when evaluating the user input. Include intents from the previous
@@ -107,6 +100,8 @@ module IBMWatson
107
100
  def message(workspace_id:, input: nil, intents: nil, entities: nil, alternate_intents: nil, context: nil, output: nil, nodes_visited_details: nil)
108
101
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
109
102
 
103
+ raise ArgumentError.new("version must be provided") if version.nil?
104
+
110
105
  headers = {
111
106
  }
112
107
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "message")
@@ -143,20 +138,22 @@ module IBMWatson
143
138
  #########################
144
139
 
145
140
  ##
146
- # @!method list_workspaces(page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
141
+ # @!method list_workspaces(page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
147
142
  # List workspaces.
148
143
  # List the workspaces associated with a Watson Assistant service instance.
149
- #
150
- # This operation is limited to 500 requests per 30 minutes. For more information,
151
- # see **Rate limiting**.
152
144
  # @param page_limit [Fixnum] The number of records to return in each page of results.
145
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
146
+ # request, regardless of the page limit. If this parameter is `true`, the
147
+ # `pagination` object in the response includes the `total` property.
153
148
  # @param sort [String] The attribute by which returned workspaces will be sorted. To reverse the sort
154
149
  # order, prefix the value with a minus sign (`-`).
155
150
  # @param cursor [String] A token identifying the page of results to retrieve.
156
151
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
157
152
  # the response.
158
153
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
159
- def list_workspaces(page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
154
+ def list_workspaces(page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
155
+ raise ArgumentError.new("version must be provided") if version.nil?
156
+
160
157
  headers = {
161
158
  }
162
159
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_workspaces")
@@ -165,6 +162,7 @@ module IBMWatson
165
162
  params = {
166
163
  "version" => @version,
167
164
  "page_limit" => page_limit,
165
+ "include_count" => include_count,
168
166
  "sort" => sort,
169
167
  "cursor" => cursor,
170
168
  "include_audit" => include_audit
@@ -183,33 +181,32 @@ module IBMWatson
183
181
  end
184
182
 
185
183
  ##
186
- # @!method create_workspace(name: nil, description: nil, language: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, intents: nil, entities: nil, dialog_nodes: nil, counterexamples: nil, webhooks: nil, include_audit: nil)
184
+ # @!method create_workspace(name: nil, description: nil, language: nil, dialog_nodes: nil, counterexamples: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, webhooks: nil, intents: nil, entities: nil, include_audit: nil)
187
185
  # Create workspace.
188
186
  # Create a workspace based on component objects. You must provide workspace
189
187
  # components defining the content of the new workspace.
190
- #
191
- # This operation is limited to 30 requests per 30 minutes. For more information, see
192
- # **Rate limiting**.
193
188
  # @param name [String] The name of the workspace. This string cannot contain carriage return, newline, or
194
189
  # tab characters.
195
190
  # @param description [String] The description of the workspace. This string cannot contain carriage return,
196
191
  # newline, or tab characters.
197
192
  # @param language [String] The language of the workspace.
193
+ # @param dialog_nodes [Array[DialogNode]] An array of objects describing the dialog nodes in the workspace.
194
+ # @param counterexamples [Array[Counterexample]] An array of objects defining input examples that have been marked as irrelevant
195
+ # input.
198
196
  # @param metadata [Hash] Any metadata related to the workspace.
199
197
  # @param learning_opt_out [Boolean] Whether training data from the workspace (including artifacts such as intents and
200
198
  # entities) can be used by IBM for general service improvements. `true` indicates
201
199
  # that workspace training data is not to be used.
202
200
  # @param system_settings [WorkspaceSystemSettings] Global settings for the workspace.
201
+ # @param webhooks [Array[Webhook]]
203
202
  # @param intents [Array[CreateIntent]] An array of objects defining the intents for the workspace.
204
203
  # @param entities [Array[CreateEntity]] An array of objects describing the entities for the workspace.
205
- # @param dialog_nodes [Array[DialogNode]] An array of objects describing the dialog nodes in the workspace.
206
- # @param counterexamples [Array[Counterexample]] An array of objects defining input examples that have been marked as irrelevant
207
- # input.
208
- # @param webhooks [Array[Webhook]]
209
204
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
210
205
  # the response.
211
206
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
212
- def create_workspace(name: nil, description: nil, language: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, intents: nil, entities: nil, dialog_nodes: nil, counterexamples: nil, webhooks: nil, include_audit: nil)
207
+ def create_workspace(name: nil, description: nil, language: nil, dialog_nodes: nil, counterexamples: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, webhooks: nil, intents: nil, entities: nil, include_audit: nil)
208
+ raise ArgumentError.new("version must be provided") if version.nil?
209
+
213
210
  headers = {
214
211
  }
215
212
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "create_workspace")
@@ -224,14 +221,14 @@ module IBMWatson
224
221
  "name" => name,
225
222
  "description" => description,
226
223
  "language" => language,
224
+ "dialog_nodes" => dialog_nodes,
225
+ "counterexamples" => counterexamples,
227
226
  "metadata" => metadata,
228
227
  "learning_opt_out" => learning_opt_out,
229
228
  "system_settings" => system_settings,
229
+ "webhooks" => webhooks,
230
230
  "intents" => intents,
231
- "entities" => entities,
232
- "dialog_nodes" => dialog_nodes,
233
- "counterexamples" => counterexamples,
234
- "webhooks" => webhooks
231
+ "entities" => entities
235
232
  }
236
233
 
237
234
  method_url = "/v1/workspaces"
@@ -251,10 +248,6 @@ module IBMWatson
251
248
  # @!method get_workspace(workspace_id:, export: nil, include_audit: nil, sort: nil)
252
249
  # Get information about a workspace.
253
250
  # Get information about a workspace, optionally including all workspace content.
254
- #
255
- # With **export**=`false`, this operation is limited to 6000 requests per 5 minutes.
256
- # With **export**=`true`, the limit is 20 requests per 30 minutes. For more
257
- # information, see **Rate limiting**.
258
251
  # @param workspace_id [String] Unique identifier of the workspace.
259
252
  # @param export [Boolean] Whether to include all element content in the returned data. If
260
253
  # **export**=`false`, the returned data includes only information about the element
@@ -268,6 +261,8 @@ module IBMWatson
268
261
  def get_workspace(workspace_id:, export: nil, include_audit: nil, sort: nil)
269
262
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
270
263
 
264
+ raise ArgumentError.new("version must be provided") if version.nil?
265
+
271
266
  headers = {
272
267
  }
273
268
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_workspace")
@@ -293,30 +288,27 @@ module IBMWatson
293
288
  end
294
289
 
295
290
  ##
296
- # @!method update_workspace(workspace_id:, name: nil, description: nil, language: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, intents: nil, entities: nil, dialog_nodes: nil, counterexamples: nil, webhooks: nil, append: nil, include_audit: nil)
291
+ # @!method update_workspace(workspace_id:, name: nil, description: nil, language: nil, dialog_nodes: nil, counterexamples: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, webhooks: nil, intents: nil, entities: nil, append: nil, include_audit: nil)
297
292
  # Update workspace.
298
293
  # Update an existing workspace with new or modified data. You must provide component
299
294
  # objects defining the content of the updated workspace.
300
- #
301
- # This operation is limited to 30 request per 30 minutes. For more information, see
302
- # **Rate limiting**.
303
295
  # @param workspace_id [String] Unique identifier of the workspace.
304
296
  # @param name [String] The name of the workspace. This string cannot contain carriage return, newline, or
305
297
  # tab characters.
306
298
  # @param description [String] The description of the workspace. This string cannot contain carriage return,
307
299
  # newline, or tab characters.
308
300
  # @param language [String] The language of the workspace.
301
+ # @param dialog_nodes [Array[DialogNode]] An array of objects describing the dialog nodes in the workspace.
302
+ # @param counterexamples [Array[Counterexample]] An array of objects defining input examples that have been marked as irrelevant
303
+ # input.
309
304
  # @param metadata [Hash] Any metadata related to the workspace.
310
305
  # @param learning_opt_out [Boolean] Whether training data from the workspace (including artifacts such as intents and
311
306
  # entities) can be used by IBM for general service improvements. `true` indicates
312
307
  # that workspace training data is not to be used.
313
308
  # @param system_settings [WorkspaceSystemSettings] Global settings for the workspace.
309
+ # @param webhooks [Array[Webhook]]
314
310
  # @param intents [Array[CreateIntent]] An array of objects defining the intents for the workspace.
315
311
  # @param entities [Array[CreateEntity]] An array of objects describing the entities for the workspace.
316
- # @param dialog_nodes [Array[DialogNode]] An array of objects describing the dialog nodes in the workspace.
317
- # @param counterexamples [Array[Counterexample]] An array of objects defining input examples that have been marked as irrelevant
318
- # input.
319
- # @param webhooks [Array[Webhook]]
320
312
  # @param append [Boolean] Whether the new data is to be appended to the existing data in the object. If
321
313
  # **append**=`false`, elements included in the new data completely replace the
322
314
  # corresponding existing elements, including all subelements. For example, if the
@@ -330,9 +322,11 @@ module IBMWatson
330
322
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
331
323
  # the response.
332
324
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
333
- def update_workspace(workspace_id:, name: nil, description: nil, language: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, intents: nil, entities: nil, dialog_nodes: nil, counterexamples: nil, webhooks: nil, append: nil, include_audit: nil)
325
+ def update_workspace(workspace_id:, name: nil, description: nil, language: nil, dialog_nodes: nil, counterexamples: nil, metadata: nil, learning_opt_out: nil, system_settings: nil, webhooks: nil, intents: nil, entities: nil, append: nil, include_audit: nil)
334
326
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
335
327
 
328
+ raise ArgumentError.new("version must be provided") if version.nil?
329
+
336
330
  headers = {
337
331
  }
338
332
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_workspace")
@@ -348,14 +342,14 @@ module IBMWatson
348
342
  "name" => name,
349
343
  "description" => description,
350
344
  "language" => language,
345
+ "dialog_nodes" => dialog_nodes,
346
+ "counterexamples" => counterexamples,
351
347
  "metadata" => metadata,
352
348
  "learning_opt_out" => learning_opt_out,
353
349
  "system_settings" => system_settings,
350
+ "webhooks" => webhooks,
354
351
  "intents" => intents,
355
- "entities" => entities,
356
- "dialog_nodes" => dialog_nodes,
357
- "counterexamples" => counterexamples,
358
- "webhooks" => webhooks
352
+ "entities" => entities
359
353
  }
360
354
 
361
355
  method_url = "/v1/workspaces/%s" % [ERB::Util.url_encode(workspace_id)]
@@ -375,14 +369,13 @@ module IBMWatson
375
369
  # @!method delete_workspace(workspace_id:)
376
370
  # Delete workspace.
377
371
  # Delete a workspace from the service instance.
378
- #
379
- # This operation is limited to 30 requests per 30 minutes. For more information, see
380
- # **Rate limiting**.
381
372
  # @param workspace_id [String] Unique identifier of the workspace.
382
373
  # @return [nil]
383
374
  def delete_workspace(workspace_id:)
384
375
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
385
376
 
377
+ raise ArgumentError.new("version must be provided") if version.nil?
378
+
386
379
  headers = {
387
380
  }
388
381
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_workspace")
@@ -408,27 +401,28 @@ module IBMWatson
408
401
  #########################
409
402
 
410
403
  ##
411
- # @!method list_intents(workspace_id:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
404
+ # @!method list_intents(workspace_id:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
412
405
  # List intents.
413
406
  # List the intents for a workspace.
414
- #
415
- # With **export**=`false`, this operation is limited to 2000 requests per 30
416
- # minutes. With **export**=`true`, the limit is 400 requests per 30 minutes. For
417
- # more information, see **Rate limiting**.
418
407
  # @param workspace_id [String] Unique identifier of the workspace.
419
408
  # @param export [Boolean] Whether to include all element content in the returned data. If
420
409
  # **export**=`false`, the returned data includes only information about the element
421
410
  # itself. If **export**=`true`, all content, including subelements, is included.
422
411
  # @param page_limit [Fixnum] The number of records to return in each page of results.
412
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
413
+ # request, regardless of the page limit. If this parameter is `true`, the
414
+ # `pagination` object in the response includes the `total` property.
423
415
  # @param sort [String] The attribute by which returned intents will be sorted. To reverse the sort order,
424
416
  # prefix the value with a minus sign (`-`).
425
417
  # @param cursor [String] A token identifying the page of results to retrieve.
426
418
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
427
419
  # the response.
428
420
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
429
- def list_intents(workspace_id:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
421
+ def list_intents(workspace_id:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
430
422
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
431
423
 
424
+ raise ArgumentError.new("version must be provided") if version.nil?
425
+
432
426
  headers = {
433
427
  }
434
428
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_intents")
@@ -438,6 +432,7 @@ module IBMWatson
438
432
  "version" => @version,
439
433
  "export" => export,
440
434
  "page_limit" => page_limit,
435
+ "include_count" => include_count,
441
436
  "sort" => sort,
442
437
  "cursor" => cursor,
443
438
  "include_audit" => include_audit
@@ -462,9 +457,6 @@ module IBMWatson
462
457
  #
463
458
  # If you want to create multiple intents with a single API call, consider using the
464
459
  # **[Update workspace](#update-workspace)** method instead.
465
- #
466
- # This operation is limited to 2000 requests per 30 minutes. For more information,
467
- # see **Rate limiting**.
468
460
  # @param workspace_id [String] Unique identifier of the workspace.
469
461
  # @param intent [String] The name of the intent. This string must conform to the following restrictions:
470
462
  # - It can contain only Unicode alphanumeric, underscore, hyphen, and dot
@@ -479,6 +471,8 @@ module IBMWatson
479
471
  def create_intent(workspace_id:, intent:, description: nil, examples: nil, include_audit: nil)
480
472
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
481
473
 
474
+ raise ArgumentError.new("version must be provided") if version.nil?
475
+
482
476
  raise ArgumentError.new("intent must be provided") if intent.nil?
483
477
 
484
478
  headers = {
@@ -514,10 +508,6 @@ module IBMWatson
514
508
  # @!method get_intent(workspace_id:, intent:, export: nil, include_audit: nil)
515
509
  # Get intent.
516
510
  # Get information about an intent, optionally including all intent content.
517
- #
518
- # With **export**=`false`, this operation is limited to 6000 requests per 5 minutes.
519
- # With **export**=`true`, the limit is 400 requests per 30 minutes. For more
520
- # information, see **Rate limiting**.
521
511
  # @param workspace_id [String] Unique identifier of the workspace.
522
512
  # @param intent [String] The intent name.
523
513
  # @param export [Boolean] Whether to include all element content in the returned data. If
@@ -531,6 +521,8 @@ module IBMWatson
531
521
 
532
522
  raise ArgumentError.new("intent must be provided") if intent.nil?
533
523
 
524
+ raise ArgumentError.new("version must be provided") if version.nil?
525
+
534
526
  headers = {
535
527
  }
536
528
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_intent")
@@ -562,9 +554,6 @@ module IBMWatson
562
554
  #
563
555
  # If you want to update multiple intents with a single API call, consider using the
564
556
  # **[Update workspace](#update-workspace)** method instead.
565
- #
566
- # This operation is limited to 2000 requests per 30 minutes. For more information,
567
- # see **Rate limiting**.
568
557
  # @param workspace_id [String] Unique identifier of the workspace.
569
558
  # @param intent [String] The intent name.
570
559
  # @param new_intent [String] The name of the intent. This string must conform to the following restrictions:
@@ -591,6 +580,8 @@ module IBMWatson
591
580
 
592
581
  raise ArgumentError.new("intent must be provided") if intent.nil?
593
582
 
583
+ raise ArgumentError.new("version must be provided") if version.nil?
584
+
594
585
  headers = {
595
586
  }
596
587
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_intent")
@@ -625,9 +616,6 @@ module IBMWatson
625
616
  # @!method delete_intent(workspace_id:, intent:)
626
617
  # Delete intent.
627
618
  # Delete an intent from a workspace.
628
- #
629
- # This operation is limited to 2000 requests per 30 minutes. For more information,
630
- # see **Rate limiting**.
631
619
  # @param workspace_id [String] Unique identifier of the workspace.
632
620
  # @param intent [String] The intent name.
633
621
  # @return [nil]
@@ -636,6 +624,8 @@ module IBMWatson
636
624
 
637
625
  raise ArgumentError.new("intent must be provided") if intent.nil?
638
626
 
627
+ raise ArgumentError.new("version must be provided") if version.nil?
628
+
639
629
  headers = {
640
630
  }
641
631
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_intent")
@@ -661,27 +651,29 @@ module IBMWatson
661
651
  #########################
662
652
 
663
653
  ##
664
- # @!method list_examples(workspace_id:, intent:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
654
+ # @!method list_examples(workspace_id:, intent:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
665
655
  # List user input examples.
666
656
  # List the user input examples for an intent, optionally including contextual entity
667
657
  # mentions.
668
- #
669
- # This operation is limited to 2500 requests per 30 minutes. For more information,
670
- # see **Rate limiting**.
671
658
  # @param workspace_id [String] Unique identifier of the workspace.
672
659
  # @param intent [String] The intent name.
673
660
  # @param page_limit [Fixnum] The number of records to return in each page of results.
661
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
662
+ # request, regardless of the page limit. If this parameter is `true`, the
663
+ # `pagination` object in the response includes the `total` property.
674
664
  # @param sort [String] The attribute by which returned examples will be sorted. To reverse the sort
675
665
  # order, prefix the value with a minus sign (`-`).
676
666
  # @param cursor [String] A token identifying the page of results to retrieve.
677
667
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
678
668
  # the response.
679
669
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
680
- def list_examples(workspace_id:, intent:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
670
+ def list_examples(workspace_id:, intent:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
681
671
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
682
672
 
683
673
  raise ArgumentError.new("intent must be provided") if intent.nil?
684
674
 
675
+ raise ArgumentError.new("version must be provided") if version.nil?
676
+
685
677
  headers = {
686
678
  }
687
679
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_examples")
@@ -690,6 +682,7 @@ module IBMWatson
690
682
  params = {
691
683
  "version" => @version,
692
684
  "page_limit" => page_limit,
685
+ "include_count" => include_count,
693
686
  "sort" => sort,
694
687
  "cursor" => cursor,
695
688
  "include_audit" => include_audit
@@ -714,9 +707,6 @@ module IBMWatson
714
707
  #
715
708
  # If you want to add multiple examples with a single API call, consider using the
716
709
  # **[Update intent](#update-intent)** method instead.
717
- #
718
- # This operation is limited to 1000 requests per 30 minutes. For more information,
719
- # see **Rate limiting**.
720
710
  # @param workspace_id [String] Unique identifier of the workspace.
721
711
  # @param intent [String] The intent name.
722
712
  # @param text [String] The text of a user input example. This string must conform to the following
@@ -732,6 +722,8 @@ module IBMWatson
732
722
 
733
723
  raise ArgumentError.new("intent must be provided") if intent.nil?
734
724
 
725
+ raise ArgumentError.new("version must be provided") if version.nil?
726
+
735
727
  raise ArgumentError.new("text must be provided") if text.nil?
736
728
 
737
729
  headers = {
@@ -766,9 +758,6 @@ module IBMWatson
766
758
  # @!method get_example(workspace_id:, intent:, text:, include_audit: nil)
767
759
  # Get user input example.
768
760
  # Get information about a user input example.
769
- #
770
- # This operation is limited to 6000 requests per 5 minutes. For more information,
771
- # see **Rate limiting**.
772
761
  # @param workspace_id [String] Unique identifier of the workspace.
773
762
  # @param intent [String] The intent name.
774
763
  # @param text [String] The text of the user input example.
@@ -782,6 +771,8 @@ module IBMWatson
782
771
 
783
772
  raise ArgumentError.new("text must be provided") if text.nil?
784
773
 
774
+ raise ArgumentError.new("version must be provided") if version.nil?
775
+
785
776
  headers = {
786
777
  }
787
778
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_example")
@@ -811,9 +802,6 @@ module IBMWatson
811
802
  #
812
803
  # If you want to update multiple examples with a single API call, consider using the
813
804
  # **[Update intent](#update-intent)** method instead.
814
- #
815
- # This operation is limited to 1000 requests per 30 minutes. For more information,
816
- # see **Rate limiting**.
817
805
  # @param workspace_id [String] Unique identifier of the workspace.
818
806
  # @param intent [String] The intent name.
819
807
  # @param text [String] The text of the user input example.
@@ -832,6 +820,8 @@ module IBMWatson
832
820
 
833
821
  raise ArgumentError.new("text must be provided") if text.nil?
834
822
 
823
+ raise ArgumentError.new("version must be provided") if version.nil?
824
+
835
825
  headers = {
836
826
  }
837
827
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_example")
@@ -864,9 +854,6 @@ module IBMWatson
864
854
  # @!method delete_example(workspace_id:, intent:, text:)
865
855
  # Delete user input example.
866
856
  # Delete a user input example from an intent.
867
- #
868
- # This operation is limited to 1000 requests per 30 minutes. For more information,
869
- # see **Rate limiting**.
870
857
  # @param workspace_id [String] Unique identifier of the workspace.
871
858
  # @param intent [String] The intent name.
872
859
  # @param text [String] The text of the user input example.
@@ -878,6 +865,8 @@ module IBMWatson
878
865
 
879
866
  raise ArgumentError.new("text must be provided") if text.nil?
880
867
 
868
+ raise ArgumentError.new("version must be provided") if version.nil?
869
+
881
870
  headers = {
882
871
  }
883
872
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_example")
@@ -903,24 +892,26 @@ module IBMWatson
903
892
  #########################
904
893
 
905
894
  ##
906
- # @!method list_counterexamples(workspace_id:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
895
+ # @!method list_counterexamples(workspace_id:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
907
896
  # List counterexamples.
908
897
  # List the counterexamples for a workspace. Counterexamples are examples that have
909
898
  # been marked as irrelevant input.
910
- #
911
- # This operation is limited to 2500 requests per 30 minutes. For more information,
912
- # see **Rate limiting**.
913
899
  # @param workspace_id [String] Unique identifier of the workspace.
914
900
  # @param page_limit [Fixnum] The number of records to return in each page of results.
901
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
902
+ # request, regardless of the page limit. If this parameter is `true`, the
903
+ # `pagination` object in the response includes the `total` property.
915
904
  # @param sort [String] The attribute by which returned counterexamples will be sorted. To reverse the
916
905
  # sort order, prefix the value with a minus sign (`-`).
917
906
  # @param cursor [String] A token identifying the page of results to retrieve.
918
907
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
919
908
  # the response.
920
909
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
921
- def list_counterexamples(workspace_id:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
910
+ def list_counterexamples(workspace_id:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
922
911
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
923
912
 
913
+ raise ArgumentError.new("version must be provided") if version.nil?
914
+
924
915
  headers = {
925
916
  }
926
917
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_counterexamples")
@@ -929,6 +920,7 @@ module IBMWatson
929
920
  params = {
930
921
  "version" => @version,
931
922
  "page_limit" => page_limit,
923
+ "include_count" => include_count,
932
924
  "sort" => sort,
933
925
  "cursor" => cursor,
934
926
  "include_audit" => include_audit
@@ -954,9 +946,6 @@ module IBMWatson
954
946
  #
955
947
  # If you want to add multiple counterexamples with a single API call, consider using
956
948
  # the **[Update workspace](#update-workspace)** method instead.
957
- #
958
- # This operation is limited to 1000 requests per 30 minutes. For more information,
959
- # see **Rate limiting**.
960
949
  # @param workspace_id [String] Unique identifier of the workspace.
961
950
  # @param text [String] The text of a user input marked as irrelevant input. This string must conform to
962
951
  # the following restrictions:
@@ -968,6 +957,8 @@ module IBMWatson
968
957
  def create_counterexample(workspace_id:, text:, include_audit: nil)
969
958
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
970
959
 
960
+ raise ArgumentError.new("version must be provided") if version.nil?
961
+
971
962
  raise ArgumentError.new("text must be provided") if text.nil?
972
963
 
973
964
  headers = {
@@ -1002,9 +993,6 @@ module IBMWatson
1002
993
  # Get counterexample.
1003
994
  # Get information about a counterexample. Counterexamples are examples that have
1004
995
  # been marked as irrelevant input.
1005
- #
1006
- # This operation is limited to 6000 requests per 5 minutes. For more information,
1007
- # see **Rate limiting**.
1008
996
  # @param workspace_id [String] Unique identifier of the workspace.
1009
997
  # @param text [String] The text of a user input counterexample (for example, `What are you wearing?`).
1010
998
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
@@ -1015,6 +1003,8 @@ module IBMWatson
1015
1003
 
1016
1004
  raise ArgumentError.new("text must be provided") if text.nil?
1017
1005
 
1006
+ raise ArgumentError.new("version must be provided") if version.nil?
1007
+
1018
1008
  headers = {
1019
1009
  }
1020
1010
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_counterexample")
@@ -1042,12 +1032,6 @@ module IBMWatson
1042
1032
  # Update counterexample.
1043
1033
  # Update the text of a counterexample. Counterexamples are examples that have been
1044
1034
  # marked as irrelevant input.
1045
- #
1046
- # If you want to update multiple counterexamples with a single API call, consider
1047
- # using the **[Update workspace](#update-workspace)** method instead.
1048
- #
1049
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1050
- # see **Rate limiting**.
1051
1035
  # @param workspace_id [String] Unique identifier of the workspace.
1052
1036
  # @param text [String] The text of a user input counterexample (for example, `What are you wearing?`).
1053
1037
  # @param new_text [String] The text of a user input marked as irrelevant input. This string must conform to
@@ -1062,6 +1046,8 @@ module IBMWatson
1062
1046
 
1063
1047
  raise ArgumentError.new("text must be provided") if text.nil?
1064
1048
 
1049
+ raise ArgumentError.new("version must be provided") if version.nil?
1050
+
1065
1051
  headers = {
1066
1052
  }
1067
1053
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_counterexample")
@@ -1094,9 +1080,6 @@ module IBMWatson
1094
1080
  # Delete counterexample.
1095
1081
  # Delete a counterexample from a workspace. Counterexamples are examples that have
1096
1082
  # been marked as irrelevant input.
1097
- #
1098
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1099
- # see **Rate limiting**.
1100
1083
  # @param workspace_id [String] Unique identifier of the workspace.
1101
1084
  # @param text [String] The text of a user input counterexample (for example, `What are you wearing?`).
1102
1085
  # @return [nil]
@@ -1105,6 +1088,8 @@ module IBMWatson
1105
1088
 
1106
1089
  raise ArgumentError.new("text must be provided") if text.nil?
1107
1090
 
1091
+ raise ArgumentError.new("version must be provided") if version.nil?
1092
+
1108
1093
  headers = {
1109
1094
  }
1110
1095
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_counterexample")
@@ -1130,27 +1115,28 @@ module IBMWatson
1130
1115
  #########################
1131
1116
 
1132
1117
  ##
1133
- # @!method list_entities(workspace_id:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1118
+ # @!method list_entities(workspace_id:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1134
1119
  # List entities.
1135
1120
  # List the entities for a workspace.
1136
- #
1137
- # With **export**=`false`, this operation is limited to 1000 requests per 30
1138
- # minutes. With **export**=`true`, the limit is 200 requests per 30 minutes. For
1139
- # more information, see **Rate limiting**.
1140
1121
  # @param workspace_id [String] Unique identifier of the workspace.
1141
1122
  # @param export [Boolean] Whether to include all element content in the returned data. If
1142
1123
  # **export**=`false`, the returned data includes only information about the element
1143
1124
  # itself. If **export**=`true`, all content, including subelements, is included.
1144
1125
  # @param page_limit [Fixnum] The number of records to return in each page of results.
1126
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
1127
+ # request, regardless of the page limit. If this parameter is `true`, the
1128
+ # `pagination` object in the response includes the `total` property.
1145
1129
  # @param sort [String] The attribute by which returned entities will be sorted. To reverse the sort
1146
1130
  # order, prefix the value with a minus sign (`-`).
1147
1131
  # @param cursor [String] A token identifying the page of results to retrieve.
1148
1132
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
1149
1133
  # the response.
1150
1134
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
1151
- def list_entities(workspace_id:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1135
+ def list_entities(workspace_id:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1152
1136
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
1153
1137
 
1138
+ raise ArgumentError.new("version must be provided") if version.nil?
1139
+
1154
1140
  headers = {
1155
1141
  }
1156
1142
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_entities")
@@ -1160,6 +1146,7 @@ module IBMWatson
1160
1146
  "version" => @version,
1161
1147
  "export" => export,
1162
1148
  "page_limit" => page_limit,
1149
+ "include_count" => include_count,
1163
1150
  "sort" => sort,
1164
1151
  "cursor" => cursor,
1165
1152
  "include_audit" => include_audit
@@ -1184,9 +1171,6 @@ module IBMWatson
1184
1171
  #
1185
1172
  # If you want to create multiple entities with a single API call, consider using the
1186
1173
  # **[Update workspace](#update-workspace)** method instead.
1187
- #
1188
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1189
- # see **Rate limiting**.
1190
1174
  # @param workspace_id [String] Unique identifier of the workspace.
1191
1175
  # @param entity [String] The name of the entity. This string must conform to the following restrictions:
1192
1176
  # - It can contain only Unicode alphanumeric, underscore, and hyphen characters.
@@ -1204,6 +1188,8 @@ module IBMWatson
1204
1188
  def create_entity(workspace_id:, entity:, description: nil, metadata: nil, fuzzy_match: nil, values: nil, include_audit: nil)
1205
1189
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
1206
1190
 
1191
+ raise ArgumentError.new("version must be provided") if version.nil?
1192
+
1207
1193
  raise ArgumentError.new("entity must be provided") if entity.nil?
1208
1194
 
1209
1195
  headers = {
@@ -1241,10 +1227,6 @@ module IBMWatson
1241
1227
  # @!method get_entity(workspace_id:, entity:, export: nil, include_audit: nil)
1242
1228
  # Get entity.
1243
1229
  # Get information about an entity, optionally including all entity content.
1244
- #
1245
- # With **export**=`false`, this operation is limited to 6000 requests per 5 minutes.
1246
- # With **export**=`true`, the limit is 200 requests per 30 minutes. For more
1247
- # information, see **Rate limiting**.
1248
1230
  # @param workspace_id [String] Unique identifier of the workspace.
1249
1231
  # @param entity [String] The name of the entity.
1250
1232
  # @param export [Boolean] Whether to include all element content in the returned data. If
@@ -1258,6 +1240,8 @@ module IBMWatson
1258
1240
 
1259
1241
  raise ArgumentError.new("entity must be provided") if entity.nil?
1260
1242
 
1243
+ raise ArgumentError.new("version must be provided") if version.nil?
1244
+
1261
1245
  headers = {
1262
1246
  }
1263
1247
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_entity")
@@ -1289,9 +1273,6 @@ module IBMWatson
1289
1273
  #
1290
1274
  # If you want to update multiple entities with a single API call, consider using the
1291
1275
  # **[Update workspace](#update-workspace)** method instead.
1292
- #
1293
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1294
- # see **Rate limiting**.
1295
1276
  # @param workspace_id [String] Unique identifier of the workspace.
1296
1277
  # @param entity [String] The name of the entity.
1297
1278
  # @param new_entity [String] The name of the entity. This string must conform to the following restrictions:
@@ -1319,6 +1300,8 @@ module IBMWatson
1319
1300
 
1320
1301
  raise ArgumentError.new("entity must be provided") if entity.nil?
1321
1302
 
1303
+ raise ArgumentError.new("version must be provided") if version.nil?
1304
+
1322
1305
  headers = {
1323
1306
  }
1324
1307
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_entity")
@@ -1355,9 +1338,6 @@ module IBMWatson
1355
1338
  # @!method delete_entity(workspace_id:, entity:)
1356
1339
  # Delete entity.
1357
1340
  # Delete an entity from a workspace, or disable a system entity.
1358
- #
1359
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1360
- # see **Rate limiting**.
1361
1341
  # @param workspace_id [String] Unique identifier of the workspace.
1362
1342
  # @param entity [String] The name of the entity.
1363
1343
  # @return [nil]
@@ -1366,6 +1346,8 @@ module IBMWatson
1366
1346
 
1367
1347
  raise ArgumentError.new("entity must be provided") if entity.nil?
1368
1348
 
1349
+ raise ArgumentError.new("version must be provided") if version.nil?
1350
+
1369
1351
  headers = {
1370
1352
  }
1371
1353
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_entity")
@@ -1395,9 +1377,6 @@ module IBMWatson
1395
1377
  # List entity mentions.
1396
1378
  # List mentions for a contextual entity. An entity mention is an occurrence of a
1397
1379
  # contextual entity in the context of an intent user input example.
1398
- #
1399
- # This operation is limited to 200 requests per 30 minutes. For more information,
1400
- # see **Rate limiting**.
1401
1380
  # @param workspace_id [String] Unique identifier of the workspace.
1402
1381
  # @param entity [String] The name of the entity.
1403
1382
  # @param export [Boolean] Whether to include all element content in the returned data. If
@@ -1411,6 +1390,8 @@ module IBMWatson
1411
1390
 
1412
1391
  raise ArgumentError.new("entity must be provided") if entity.nil?
1413
1392
 
1393
+ raise ArgumentError.new("version must be provided") if version.nil?
1394
+
1414
1395
  headers = {
1415
1396
  }
1416
1397
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_mentions")
@@ -1438,29 +1419,31 @@ module IBMWatson
1438
1419
  #########################
1439
1420
 
1440
1421
  ##
1441
- # @!method list_values(workspace_id:, entity:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1422
+ # @!method list_values(workspace_id:, entity:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1442
1423
  # List entity values.
1443
1424
  # List the values for an entity.
1444
- #
1445
- # This operation is limited to 2500 requests per 30 minutes. For more information,
1446
- # see **Rate limiting**.
1447
1425
  # @param workspace_id [String] Unique identifier of the workspace.
1448
1426
  # @param entity [String] The name of the entity.
1449
1427
  # @param export [Boolean] Whether to include all element content in the returned data. If
1450
1428
  # **export**=`false`, the returned data includes only information about the element
1451
1429
  # itself. If **export**=`true`, all content, including subelements, is included.
1452
1430
  # @param page_limit [Fixnum] The number of records to return in each page of results.
1431
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
1432
+ # request, regardless of the page limit. If this parameter is `true`, the
1433
+ # `pagination` object in the response includes the `total` property.
1453
1434
  # @param sort [String] The attribute by which returned entity values will be sorted. To reverse the sort
1454
1435
  # order, prefix the value with a minus sign (`-`).
1455
1436
  # @param cursor [String] A token identifying the page of results to retrieve.
1456
1437
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
1457
1438
  # the response.
1458
1439
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
1459
- def list_values(workspace_id:, entity:, export: nil, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1440
+ def list_values(workspace_id:, entity:, export: nil, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1460
1441
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
1461
1442
 
1462
1443
  raise ArgumentError.new("entity must be provided") if entity.nil?
1463
1444
 
1445
+ raise ArgumentError.new("version must be provided") if version.nil?
1446
+
1464
1447
  headers = {
1465
1448
  }
1466
1449
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_values")
@@ -1470,6 +1453,7 @@ module IBMWatson
1470
1453
  "version" => @version,
1471
1454
  "export" => export,
1472
1455
  "page_limit" => page_limit,
1456
+ "include_count" => include_count,
1473
1457
  "sort" => sort,
1474
1458
  "cursor" => cursor,
1475
1459
  "include_audit" => include_audit
@@ -1494,9 +1478,6 @@ module IBMWatson
1494
1478
  #
1495
1479
  # If you want to create multiple entity values with a single API call, consider
1496
1480
  # using the **[Update entity](#update-entity)** method instead.
1497
- #
1498
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1499
- # see **Rate limiting**.
1500
1481
  # @param workspace_id [String] Unique identifier of the workspace.
1501
1482
  # @param entity [String] The name of the entity.
1502
1483
  # @param value [String] The text of the entity value. This string must conform to the following
@@ -1522,6 +1503,8 @@ module IBMWatson
1522
1503
 
1523
1504
  raise ArgumentError.new("entity must be provided") if entity.nil?
1524
1505
 
1506
+ raise ArgumentError.new("version must be provided") if version.nil?
1507
+
1525
1508
  raise ArgumentError.new("value must be provided") if value.nil?
1526
1509
 
1527
1510
  headers = {
@@ -1559,9 +1542,6 @@ module IBMWatson
1559
1542
  # @!method get_value(workspace_id:, entity:, value:, export: nil, include_audit: nil)
1560
1543
  # Get entity value.
1561
1544
  # Get information about an entity value.
1562
- #
1563
- # This operation is limited to 6000 requests per 5 minutes. For more information,
1564
- # see **Rate limiting**.
1565
1545
  # @param workspace_id [String] Unique identifier of the workspace.
1566
1546
  # @param entity [String] The name of the entity.
1567
1547
  # @param value [String] The text of the entity value.
@@ -1578,6 +1558,8 @@ module IBMWatson
1578
1558
 
1579
1559
  raise ArgumentError.new("value must be provided") if value.nil?
1580
1560
 
1561
+ raise ArgumentError.new("version must be provided") if version.nil?
1562
+
1581
1563
  headers = {
1582
1564
  }
1583
1565
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_value")
@@ -1609,9 +1591,6 @@ module IBMWatson
1609
1591
  #
1610
1592
  # If you want to update multiple entity values with a single API call, consider
1611
1593
  # using the **[Update entity](#update-entity)** method instead.
1612
- #
1613
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1614
- # see **Rate limiting**.
1615
1594
  # @param workspace_id [String] Unique identifier of the workspace.
1616
1595
  # @param entity [String] The name of the entity.
1617
1596
  # @param value [String] The text of the entity value.
@@ -1650,6 +1629,8 @@ module IBMWatson
1650
1629
 
1651
1630
  raise ArgumentError.new("value must be provided") if value.nil?
1652
1631
 
1632
+ raise ArgumentError.new("version must be provided") if version.nil?
1633
+
1653
1634
  headers = {
1654
1635
  }
1655
1636
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_value")
@@ -1686,9 +1667,6 @@ module IBMWatson
1686
1667
  # @!method delete_value(workspace_id:, entity:, value:)
1687
1668
  # Delete entity value.
1688
1669
  # Delete a value from an entity.
1689
- #
1690
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1691
- # see **Rate limiting**.
1692
1670
  # @param workspace_id [String] Unique identifier of the workspace.
1693
1671
  # @param entity [String] The name of the entity.
1694
1672
  # @param value [String] The text of the entity value.
@@ -1700,6 +1678,8 @@ module IBMWatson
1700
1678
 
1701
1679
  raise ArgumentError.new("value must be provided") if value.nil?
1702
1680
 
1681
+ raise ArgumentError.new("version must be provided") if version.nil?
1682
+
1703
1683
  headers = {
1704
1684
  }
1705
1685
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_value")
@@ -1725,29 +1705,31 @@ module IBMWatson
1725
1705
  #########################
1726
1706
 
1727
1707
  ##
1728
- # @!method list_synonyms(workspace_id:, entity:, value:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1708
+ # @!method list_synonyms(workspace_id:, entity:, value:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1729
1709
  # List entity value synonyms.
1730
1710
  # List the synonyms for an entity value.
1731
- #
1732
- # This operation is limited to 2500 requests per 30 minutes. For more information,
1733
- # see **Rate limiting**.
1734
1711
  # @param workspace_id [String] Unique identifier of the workspace.
1735
1712
  # @param entity [String] The name of the entity.
1736
1713
  # @param value [String] The text of the entity value.
1737
1714
  # @param page_limit [Fixnum] The number of records to return in each page of results.
1715
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
1716
+ # request, regardless of the page limit. If this parameter is `true`, the
1717
+ # `pagination` object in the response includes the `total` property.
1738
1718
  # @param sort [String] The attribute by which returned entity value synonyms will be sorted. To reverse
1739
1719
  # the sort order, prefix the value with a minus sign (`-`).
1740
1720
  # @param cursor [String] A token identifying the page of results to retrieve.
1741
1721
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
1742
1722
  # the response.
1743
1723
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
1744
- def list_synonyms(workspace_id:, entity:, value:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1724
+ def list_synonyms(workspace_id:, entity:, value:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1745
1725
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
1746
1726
 
1747
1727
  raise ArgumentError.new("entity must be provided") if entity.nil?
1748
1728
 
1749
1729
  raise ArgumentError.new("value must be provided") if value.nil?
1750
1730
 
1731
+ raise ArgumentError.new("version must be provided") if version.nil?
1732
+
1751
1733
  headers = {
1752
1734
  }
1753
1735
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_synonyms")
@@ -1756,6 +1738,7 @@ module IBMWatson
1756
1738
  params = {
1757
1739
  "version" => @version,
1758
1740
  "page_limit" => page_limit,
1741
+ "include_count" => include_count,
1759
1742
  "sort" => sort,
1760
1743
  "cursor" => cursor,
1761
1744
  "include_audit" => include_audit
@@ -1781,9 +1764,6 @@ module IBMWatson
1781
1764
  # If you want to create multiple synonyms with a single API call, consider using the
1782
1765
  # **[Update entity](#update-entity)** or **[Update entity
1783
1766
  # value](#update-entity-value)** method instead.
1784
- #
1785
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1786
- # see **Rate limiting**.
1787
1767
  # @param workspace_id [String] Unique identifier of the workspace.
1788
1768
  # @param entity [String] The name of the entity.
1789
1769
  # @param value [String] The text of the entity value.
@@ -1800,6 +1780,8 @@ module IBMWatson
1800
1780
 
1801
1781
  raise ArgumentError.new("value must be provided") if value.nil?
1802
1782
 
1783
+ raise ArgumentError.new("version must be provided") if version.nil?
1784
+
1803
1785
  raise ArgumentError.new("synonym must be provided") if synonym.nil?
1804
1786
 
1805
1787
  headers = {
@@ -1833,9 +1815,6 @@ module IBMWatson
1833
1815
  # @!method get_synonym(workspace_id:, entity:, value:, synonym:, include_audit: nil)
1834
1816
  # Get entity value synonym.
1835
1817
  # Get information about a synonym of an entity value.
1836
- #
1837
- # This operation is limited to 6000 requests per 5 minutes. For more information,
1838
- # see **Rate limiting**.
1839
1818
  # @param workspace_id [String] Unique identifier of the workspace.
1840
1819
  # @param entity [String] The name of the entity.
1841
1820
  # @param value [String] The text of the entity value.
@@ -1852,6 +1831,8 @@ module IBMWatson
1852
1831
 
1853
1832
  raise ArgumentError.new("synonym must be provided") if synonym.nil?
1854
1833
 
1834
+ raise ArgumentError.new("version must be provided") if version.nil?
1835
+
1855
1836
  headers = {
1856
1837
  }
1857
1838
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_synonym")
@@ -1882,9 +1863,6 @@ module IBMWatson
1882
1863
  # If you want to update multiple synonyms with a single API call, consider using the
1883
1864
  # **[Update entity](#update-entity)** or **[Update entity
1884
1865
  # value](#update-entity-value)** method instead.
1885
- #
1886
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1887
- # see **Rate limiting**.
1888
1866
  # @param workspace_id [String] Unique identifier of the workspace.
1889
1867
  # @param entity [String] The name of the entity.
1890
1868
  # @param value [String] The text of the entity value.
@@ -1904,6 +1882,8 @@ module IBMWatson
1904
1882
 
1905
1883
  raise ArgumentError.new("synonym must be provided") if synonym.nil?
1906
1884
 
1885
+ raise ArgumentError.new("version must be provided") if version.nil?
1886
+
1907
1887
  headers = {
1908
1888
  }
1909
1889
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_synonym")
@@ -1935,9 +1915,6 @@ module IBMWatson
1935
1915
  # @!method delete_synonym(workspace_id:, entity:, value:, synonym:)
1936
1916
  # Delete entity value synonym.
1937
1917
  # Delete a synonym from an entity value.
1938
- #
1939
- # This operation is limited to 1000 requests per 30 minutes. For more information,
1940
- # see **Rate limiting**.
1941
1918
  # @param workspace_id [String] Unique identifier of the workspace.
1942
1919
  # @param entity [String] The name of the entity.
1943
1920
  # @param value [String] The text of the entity value.
@@ -1952,6 +1929,8 @@ module IBMWatson
1952
1929
 
1953
1930
  raise ArgumentError.new("synonym must be provided") if synonym.nil?
1954
1931
 
1932
+ raise ArgumentError.new("version must be provided") if version.nil?
1933
+
1955
1934
  headers = {
1956
1935
  }
1957
1936
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_synonym")
@@ -1977,23 +1956,25 @@ module IBMWatson
1977
1956
  #########################
1978
1957
 
1979
1958
  ##
1980
- # @!method list_dialog_nodes(workspace_id:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1959
+ # @!method list_dialog_nodes(workspace_id:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1981
1960
  # List dialog nodes.
1982
1961
  # List the dialog nodes for a workspace.
1983
- #
1984
- # This operation is limited to 2500 requests per 30 minutes. For more information,
1985
- # see **Rate limiting**.
1986
1962
  # @param workspace_id [String] Unique identifier of the workspace.
1987
1963
  # @param page_limit [Fixnum] The number of records to return in each page of results.
1964
+ # @param include_count [Boolean] Whether to include information about the number of records that satisfy the
1965
+ # request, regardless of the page limit. If this parameter is `true`, the
1966
+ # `pagination` object in the response includes the `total` property.
1988
1967
  # @param sort [String] The attribute by which returned dialog nodes will be sorted. To reverse the sort
1989
1968
  # order, prefix the value with a minus sign (`-`).
1990
1969
  # @param cursor [String] A token identifying the page of results to retrieve.
1991
1970
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
1992
1971
  # the response.
1993
1972
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
1994
- def list_dialog_nodes(workspace_id:, page_limit: nil, sort: nil, cursor: nil, include_audit: nil)
1973
+ def list_dialog_nodes(workspace_id:, page_limit: nil, include_count: nil, sort: nil, cursor: nil, include_audit: nil)
1995
1974
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
1996
1975
 
1976
+ raise ArgumentError.new("version must be provided") if version.nil?
1977
+
1997
1978
  headers = {
1998
1979
  }
1999
1980
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_dialog_nodes")
@@ -2002,6 +1983,7 @@ module IBMWatson
2002
1983
  params = {
2003
1984
  "version" => @version,
2004
1985
  "page_limit" => page_limit,
1986
+ "include_count" => include_count,
2005
1987
  "sort" => sort,
2006
1988
  "cursor" => cursor,
2007
1989
  "include_audit" => include_audit
@@ -2026,9 +2008,6 @@ module IBMWatson
2026
2008
  #
2027
2009
  # If you want to create multiple dialog nodes with a single API call, consider using
2028
2010
  # the **[Update workspace](#update-workspace)** method instead.
2029
- #
2030
- # This operation is limited to 500 requests per 30 minutes. For more information,
2031
- # see **Rate limiting**.
2032
2011
  # @param workspace_id [String] Unique identifier of the workspace.
2033
2012
  # @param dialog_node [String] The dialog node ID. This string must conform to the following restrictions:
2034
2013
  # - It can contain only Unicode alphanumeric, space, underscore, hyphen, and dot
@@ -2044,7 +2023,7 @@ module IBMWatson
2044
2023
  # @param output [DialogNodeOutput] The output of the dialog node. For more information about how to specify dialog
2045
2024
  # node output, see the
2046
2025
  # [documentation](https://cloud.ibm.com/docs/assistant?topic=assistant-dialog-overview#dialog-overview-responses).
2047
- # @param context [Hash] The context for the dialog node.
2026
+ # @param context [DialogNodeContext] The context for the dialog node.
2048
2027
  # @param metadata [Hash] The metadata for the dialog node.
2049
2028
  # @param next_step [DialogNodeNextStep] The next step to execute following this dialog node.
2050
2029
  # @param title [String] The alias used to identify the dialog node. This string must conform to the
@@ -2068,6 +2047,8 @@ module IBMWatson
2068
2047
  def create_dialog_node(workspace_id:, dialog_node:, description: nil, conditions: nil, parent: nil, previous_sibling: nil, output: nil, context: nil, metadata: nil, next_step: nil, title: nil, type: nil, event_name: nil, variable: nil, actions: nil, digress_in: nil, digress_out: nil, digress_out_slots: nil, user_label: nil, disambiguation_opt_out: nil, include_audit: nil)
2069
2048
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
2070
2049
 
2050
+ raise ArgumentError.new("version must be provided") if version.nil?
2051
+
2071
2052
  raise ArgumentError.new("dialog_node must be provided") if dialog_node.nil?
2072
2053
 
2073
2054
  headers = {
@@ -2119,9 +2100,6 @@ module IBMWatson
2119
2100
  # @!method get_dialog_node(workspace_id:, dialog_node:, include_audit: nil)
2120
2101
  # Get dialog node.
2121
2102
  # Get information about a dialog node.
2122
- #
2123
- # This operation is limited to 6000 requests per 5 minutes. For more information,
2124
- # see **Rate limiting**.
2125
2103
  # @param workspace_id [String] Unique identifier of the workspace.
2126
2104
  # @param dialog_node [String] The dialog node ID (for example, `get_order`).
2127
2105
  # @param include_audit [Boolean] Whether to include the audit properties (`created` and `updated` timestamps) in
@@ -2132,6 +2110,8 @@ module IBMWatson
2132
2110
 
2133
2111
  raise ArgumentError.new("dialog_node must be provided") if dialog_node.nil?
2134
2112
 
2113
+ raise ArgumentError.new("version must be provided") if version.nil?
2114
+
2135
2115
  headers = {
2136
2116
  }
2137
2117
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "get_dialog_node")
@@ -2161,9 +2141,6 @@ module IBMWatson
2161
2141
  #
2162
2142
  # If you want to update multiple dialog nodes with a single API call, consider using
2163
2143
  # the **[Update workspace](#update-workspace)** method instead.
2164
- #
2165
- # This operation is limited to 500 requests per 30 minutes. For more information,
2166
- # see **Rate limiting**.
2167
2144
  # @param workspace_id [String] Unique identifier of the workspace.
2168
2145
  # @param dialog_node [String] The dialog node ID (for example, `get_order`).
2169
2146
  # @param new_dialog_node [String] The dialog node ID. This string must conform to the following restrictions:
@@ -2180,7 +2157,7 @@ module IBMWatson
2180
2157
  # @param new_output [DialogNodeOutput] The output of the dialog node. For more information about how to specify dialog
2181
2158
  # node output, see the
2182
2159
  # [documentation](https://cloud.ibm.com/docs/assistant?topic=assistant-dialog-overview#dialog-overview-responses).
2183
- # @param new_context [Hash] The context for the dialog node.
2160
+ # @param new_context [DialogNodeContext] The context for the dialog node.
2184
2161
  # @param new_metadata [Hash] The metadata for the dialog node.
2185
2162
  # @param new_next_step [DialogNodeNextStep] The next step to execute following this dialog node.
2186
2163
  # @param new_title [String] The alias used to identify the dialog node. This string must conform to the
@@ -2206,6 +2183,8 @@ module IBMWatson
2206
2183
 
2207
2184
  raise ArgumentError.new("dialog_node must be provided") if dialog_node.nil?
2208
2185
 
2186
+ raise ArgumentError.new("version must be provided") if version.nil?
2187
+
2209
2188
  headers = {
2210
2189
  }
2211
2190
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_dialog_node")
@@ -2255,9 +2234,6 @@ module IBMWatson
2255
2234
  # @!method delete_dialog_node(workspace_id:, dialog_node:)
2256
2235
  # Delete dialog node.
2257
2236
  # Delete a dialog node from a workspace.
2258
- #
2259
- # This operation is limited to 500 requests per 30 minutes. For more information,
2260
- # see **Rate limiting**.
2261
2237
  # @param workspace_id [String] Unique identifier of the workspace.
2262
2238
  # @param dialog_node [String] The dialog node ID (for example, `get_order`).
2263
2239
  # @return [nil]
@@ -2266,6 +2242,8 @@ module IBMWatson
2266
2242
 
2267
2243
  raise ArgumentError.new("dialog_node must be provided") if dialog_node.nil?
2268
2244
 
2245
+ raise ArgumentError.new("version must be provided") if version.nil?
2246
+
2269
2247
  headers = {
2270
2248
  }
2271
2249
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "delete_dialog_node")
@@ -2294,10 +2272,6 @@ module IBMWatson
2294
2272
  # @!method list_logs(workspace_id:, sort: nil, filter: nil, page_limit: nil, cursor: nil)
2295
2273
  # List log events in a workspace.
2296
2274
  # List the events from the log of a specific workspace.
2297
- #
2298
- # If **cursor** is not specified, this operation is limited to 40 requests per 30
2299
- # minutes. If **cursor** is specified, the limit is 120 requests per minute. For
2300
- # more information, see **Rate limiting**.
2301
2275
  # @param workspace_id [String] Unique identifier of the workspace.
2302
2276
  # @param sort [String] How to sort the returned log events. You can sort by **request_timestamp**. To
2303
2277
  # reverse the sort order, prefix the parameter value with a minus sign (`-`).
@@ -2310,6 +2284,8 @@ module IBMWatson
2310
2284
  def list_logs(workspace_id:, sort: nil, filter: nil, page_limit: nil, cursor: nil)
2311
2285
  raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
2312
2286
 
2287
+ raise ArgumentError.new("version must be provided") if version.nil?
2288
+
2313
2289
  headers = {
2314
2290
  }
2315
2291
  sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "list_logs")
@@ -2339,10 +2315,6 @@ module IBMWatson
2339
2315
  # @!method list_all_logs(filter:, sort: nil, page_limit: nil, cursor: nil)
2340
2316
  # List log events in all workspaces.
2341
2317
  # List the events from the logs of all workspaces in the service instance.
2342
- #
2343
- # If **cursor** is not specified, this operation is limited to 40 requests per 30
2344
- # minutes. If **cursor** is specified, the limit is 120 requests per minute. For
2345
- # more information, see **Rate limiting**.
2346
2318
  # @param filter [String] A cacheable parameter that limits the results to those matching the specified
2347
2319
  # filter. You must specify a filter query that includes a value for `language`, as
2348
2320
  # well as a value for `request.context.system.assistant_id`, `workspace_id`, or
@@ -2354,6 +2326,8 @@ module IBMWatson
2354
2326
  # @param cursor [String] A token identifying the page of results to retrieve.
2355
2327
  # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
2356
2328
  def list_all_logs(filter:, sort: nil, page_limit: nil, cursor: nil)
2329
+ raise ArgumentError.new("version must be provided") if version.nil?
2330
+
2357
2331
  raise ArgumentError.new("filter must be provided") if filter.nil?
2358
2332
 
2359
2333
  headers = {
@@ -2394,12 +2368,11 @@ module IBMWatson
2394
2368
  # with a request that passes data. For more information about personal data and
2395
2369
  # customer IDs, see [Information
2396
2370
  # security](https://cloud.ibm.com/docs/assistant?topic=assistant-information-security#information-security).
2397
- #
2398
- # This operation is limited to 4 requests per minute. For more information, see
2399
- # **Rate limiting**.
2400
2371
  # @param customer_id [String] The customer ID for which all data is to be deleted.
2401
2372
  # @return [nil]
2402
2373
  def delete_user_data(customer_id:)
2374
+ raise ArgumentError.new("version must be provided") if version.nil?
2375
+
2403
2376
  raise ArgumentError.new("customer_id must be provided") if customer_id.nil?
2404
2377
 
2405
2378
  headers = {
@@ -2423,5 +2396,50 @@ module IBMWatson
2423
2396
  )
2424
2397
  nil
2425
2398
  end
2399
+ #########################
2400
+ # bulkClassify
2401
+ #########################
2402
+
2403
+ ##
2404
+ # @!method bulk_classify(workspace_id:, input: nil)
2405
+ # Identify intents and entities in multiple user utterances.
2406
+ # Send multiple user inputs to a workspace in a single request and receive
2407
+ # information about the intents and entities recognized in each input. This method
2408
+ # is useful for testing and comparing the performance of different workspaces.
2409
+ #
2410
+ # This method is available only with Premium plans.
2411
+ # @param workspace_id [String] Unique identifier of the workspace.
2412
+ # @param input [Array[BulkClassifyUtterance]] An array of input utterances to classify.
2413
+ # @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.
2414
+ def bulk_classify(workspace_id:, input: nil)
2415
+ raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?
2416
+
2417
+ raise ArgumentError.new("version must be provided") if version.nil?
2418
+
2419
+ headers = {
2420
+ }
2421
+ sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "bulk_classify")
2422
+ headers.merge!(sdk_headers)
2423
+
2424
+ params = {
2425
+ "version" => @version
2426
+ }
2427
+
2428
+ data = {
2429
+ "input" => input
2430
+ }
2431
+
2432
+ method_url = "/v1/workspaces/%s/bulk_classify" % [ERB::Util.url_encode(workspace_id)]
2433
+
2434
+ response = request(
2435
+ method: "POST",
2436
+ url: method_url,
2437
+ headers: headers,
2438
+ params: params,
2439
+ json: data,
2440
+ accept_json: true
2441
+ )
2442
+ response
2443
+ end
2426
2444
  end
2427
2445
  end