lib/ibm_watson/assistant_v1.rb
def update_entity(workspace_id:, entity:, new_entity: nil, new_description: nil, new_metadata: nil, new_fuzzy_match: nil, new_values: nil)
      raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?

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

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

      params = {
        "version" => @version
      }

      data = {
        "entity" => new_entity,
        "description" => new_description,
        "metadata" => new_metadata,
        "fuzzy_match" => new_fuzzy_match,
        "values" => new_values
      }

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

      response = request(
        method: "POST",
        url: method_url,
        headers: headers,
        params: params,
        json: data,
        accept_json: true
      )
      response
    end
def update_entity(workspace_id:, entity:, new_entity: nil, new_description: nil, new_metadata: nil, new_fuzzy_match: nil, new_values: nil)
      raise ArgumentError.new("workspace_id must be provided") if workspace_id.nil?

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

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

      params = {
        "version" => @version
      }

      data = {
        "entity" => new_entity,
        "description" => new_description,
        "metadata" => new_metadata,
        "fuzzy_match" => new_fuzzy_match,
        "values" => new_values
      }

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

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

   This operation is limited to 1000 requests per 30 minutes. For more information,
   see **Rate limiting**.
 @param workspace_id [String] Unique identifier of the workspace.
 @param entity [String] The name of the entity.
 @param new_entity [String] The name of the entity. This string must conform to the following restrictions:
   - It can contain only Unicode alphanumeric, underscore, and hyphen characters.
   - It cannot begin with the reserved prefix `sys-`.
   - It must be no longer than 64 characters.
 @param new_description [String] The description of the entity. This string cannot contain carriage return,
   newline, or tab characters, and it must be no longer than 128 characters.
 @param new_metadata [Hash] Any metadata related to the entity.
 @param new_fuzzy_match [Boolean] Whether to use fuzzy matching for the entity.
 @param new_values [Array[CreateValue]] An array of objects describing the entity values.
 @return [IBMCloudSdkCore::DetailedResponse] A `IBMCloudSdkCore::DetailedResponse` object representing the response.