lib/ibm_watson/assistant_v1.rb
def update_intent(workspace_id:, intent:, new_intent: nil, new_description: nil, new_examples: nil)
      raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?

      raise ArgumentError.new("intent must be provided") if intent.nil?

      headers = {
      }
      sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_intent")
      headers.merge!(sdk_headers)

      params = {
        "version" => @version
      }

      data = {
        "intent" => new_intent,
        "description" => new_description,
        "examples" => new_examples
      }

      method_url = "/v1/workspaces/%s/intents/%s" % [ERB::Util.url_encode(workspace_id), ERB::Util.url_encode(intent)]

      response = request(
        method: "POST",
        url: method_url,
        headers: headers,
        params: params,
        json: data,
        accept_json: true
      )
      response
    end
def update_intent(workspace_id:, intent:, new_intent: nil, new_description: nil, new_examples: nil)
      raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?

      raise ArgumentError.new("intent must be provided") if intent.nil?

      headers = {
      }
      sdk_headers = Common.new.get_sdk_headers("conversation", "V1", "update_intent")
      headers.merge!(sdk_headers)

      params = {
        "version" => @version
      }

      data = {
        "intent" => new_intent,
        "description" => new_description,
        "examples" => new_examples
      }

      method_url = "/v1/workspaces/%s/intents/%s" % [ERB::Util.url_encode(workspace_id), ERB::Util.url_encode(intent)]

      response = request(
        method: "POST",
        url: method_url,
        headers: headers,
        params: params,
        json: data,
        accept_json: true
      )
      response
    end
@!method update_intent(workspace_id:, intent:, new_intent: nil, new_description: nil, new_examples: nil)
 Update intent.
 Update an existing intent with new or modified data. You must provide component
   objects defining the content of the updated intent.

   This operation is limited to 2000 requests per 30 minutes. For more information,
   see **Rate limiting**.
 @param workspace_id [String] Unique identifier of the workspace.
 @param intent [String] The intent name.
 @param new_intent [String] The name of the intent. This string must conform to the following restrictions:
   - It can contain only Unicode alphanumeric, underscore, hyphen, and dot
   characters.
   - It cannot begin with the reserved prefix `sys-`.
   - It must be no longer than 128 characters.
 @param new_description [String] The description of the intent. This string cannot contain carriage return,
   newline, or tab characters, and it must be no longer than 128 characters.
 @param new_examples [Array[Example]] An array of user input examples for the intent.
 @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.