=begin
#Daytona Toolbox API

#Daytona Toolbox API

The version of the OpenAPI document: v0.0.0-dev

Generated by: https://openapi-generator.tech
Generator version: 7.21.0

=end

require 'cgi'

module DaytonaToolboxApiClient
  class ComputerUseApi
    attr_accessor :api_client

    def initialize(api_client = ApiClient.default)
      @api_client = api_client
    end
    # Click mouse button
    # Click the mouse button at the specified coordinates
    # @param request [MouseClickRequest] Mouse click request
    # @param [Hash] opts the optional parameters
    # @return [MouseClickResponse]
    def click(request, opts = {})
      data, _status_code, _headers = click_with_http_info(request, opts)
      data
    end

    # Click mouse button
    # Click the mouse button at the specified coordinates
    # @param request [MouseClickRequest] Mouse click request
    # @param [Hash] opts the optional parameters
    # @return [Array<(MouseClickResponse, Integer, Hash)>] MouseClickResponse data, response status code and response headers
    def click_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.click ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.click"
      end
      # resource path
      local_var_path = '/computeruse/mouse/click'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'MouseClickResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.click",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#click\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Delete a recording
    # Delete a recording file by ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [nil]
    def delete_recording(id, opts = {})
      delete_recording_with_http_info(id, opts)
      nil
    end

    # Delete a recording
    # Delete a recording file by ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
    def delete_recording_with_http_info(id, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.delete_recording ...'
      end
      # verify the required parameter 'id' is set
      if @api_client.config.client_side_validation && id.nil?
        fail ArgumentError, "Missing the required parameter 'id' when calling ComputerUseApi.delete_recording"
      end
      # resource path
      local_var_path = '/computeruse/recordings/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['*/*']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type]

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.delete_recording",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#delete_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Download a recording
    # Download a recording by providing its ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [File]
    def download_recording(id, opts = {})
      data, _status_code, _headers = download_recording_with_http_info(id, opts)
      data
    end

    # Download a recording
    # Download a recording by providing its ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [Array<(File, Integer, Hash)>] File data, response status code and response headers
    def download_recording_with_http_info(id, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.download_recording ...'
      end
      # verify the required parameter 'id' is set
      if @api_client.config.client_side_validation && id.nil?
        fail ArgumentError, "Missing the required parameter 'id' when calling ComputerUseApi.download_recording"
      end
      # resource path
      local_var_path = '/computeruse/recordings/{id}/download'.sub('{' + 'id' + '}', CGI.escape(id.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/octet-stream']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'File'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.download_recording",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#download_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Drag mouse
    # Drag the mouse from start to end coordinates
    # @param request [MouseDragRequest] Mouse drag request
    # @param [Hash] opts the optional parameters
    # @return [MouseDragResponse]
    def drag(request, opts = {})
      data, _status_code, _headers = drag_with_http_info(request, opts)
      data
    end

    # Drag mouse
    # Drag the mouse from start to end coordinates
    # @param request [MouseDragRequest] Mouse drag request
    # @param [Hash] opts the optional parameters
    # @return [Array<(MouseDragResponse, Integer, Hash)>] MouseDragResponse data, response status code and response headers
    def drag_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.drag ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.drag"
      end
      # resource path
      local_var_path = '/computeruse/mouse/drag'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'MouseDragResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.drag",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#drag\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Find accessibility nodes
    # Search the AT-SPI tree for nodes matching a role/name/state filter and return a flat list.
    # @param request [FindAccessibilityNodesRequest] Find request
    # @param [Hash] opts the optional parameters
    # @return [AccessibilityNodesResponse]
    def find_accessibility_nodes(request, opts = {})
      data, _status_code, _headers = find_accessibility_nodes_with_http_info(request, opts)
      data
    end

    # Find accessibility nodes
    # Search the AT-SPI tree for nodes matching a role/name/state filter and return a flat list.
    # @param request [FindAccessibilityNodesRequest] Find request
    # @param [Hash] opts the optional parameters
    # @return [Array<(AccessibilityNodesResponse, Integer, Hash)>] AccessibilityNodesResponse data, response status code and response headers
    def find_accessibility_nodes_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.find_accessibility_nodes ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.find_accessibility_nodes"
      end
      # resource path
      local_var_path = '/computeruse/a11y/find'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'AccessibilityNodesResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.find_accessibility_nodes",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#find_accessibility_nodes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Focus an accessibility node
    # Move keyboard focus to the AT-SPI node identified by id (bus-name:object-path).
    # @param request [AccessibilityNodeRequest] Node focus request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def focus_accessibility_node(request, opts = {})
      data, _status_code, _headers = focus_accessibility_node_with_http_info(request, opts)
      data
    end

    # Focus an accessibility node
    # Move keyboard focus to the AT-SPI node identified by id (bus-name:object-path).
    # @param request [AccessibilityNodeRequest] Node focus request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def focus_accessibility_node_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.focus_accessibility_node ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.focus_accessibility_node"
      end
      # resource path
      local_var_path = '/computeruse/a11y/node/focus'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.focus_accessibility_node",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#focus_accessibility_node\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get accessibility tree
    # Fetch the AT-SPI accessibility tree for the focused application, a specific PID, or all registered applications.
    # @param [Hash] opts the optional parameters
    # @option opts [String] :scope Scope: focused | pid | all (default: focused)
    # @option opts [Integer] :pid Process ID when scope&#x3D;pid
    # @option opts [Integer] :max_depth Max tree depth (-1 unbounded, 0 root only; default -1)
    # @return [AccessibilityTreeResponse]
    def get_accessibility_tree(opts = {})
      data, _status_code, _headers = get_accessibility_tree_with_http_info(opts)
      data
    end

    # Get accessibility tree
    # Fetch the AT-SPI accessibility tree for the focused application, a specific PID, or all registered applications.
    # @param [Hash] opts the optional parameters
    # @option opts [String] :scope Scope: focused | pid | all (default: focused)
    # @option opts [Integer] :pid Process ID when scope&#x3D;pid
    # @option opts [Integer] :max_depth Max tree depth (-1 unbounded, 0 root only; default -1)
    # @return [Array<(AccessibilityTreeResponse, Integer, Hash)>] AccessibilityTreeResponse data, response status code and response headers
    def get_accessibility_tree_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_accessibility_tree ...'
      end
      # resource path
      local_var_path = '/computeruse/a11y/tree'

      # query parameters
      query_params = opts[:query_params] || {}
      query_params[:'scope'] = opts[:'scope'] if !opts[:'scope'].nil?
      query_params[:'pid'] = opts[:'pid'] if !opts[:'pid'].nil?
      query_params[:'maxDepth'] = opts[:'max_depth'] if !opts[:'max_depth'].nil?

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'AccessibilityTreeResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_accessibility_tree",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_accessibility_tree\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get computer use process status
    # Get the status of all computer use processes
    # @param [Hash] opts the optional parameters
    # @return [ComputerUseStatusResponse]
    def get_computer_use_status(opts = {})
      data, _status_code, _headers = get_computer_use_status_with_http_info(opts)
      data
    end

    # Get computer use process status
    # Get the status of all computer use processes
    # @param [Hash] opts the optional parameters
    # @return [Array<(ComputerUseStatusResponse, Integer, Hash)>] ComputerUseStatusResponse data, response status code and response headers
    def get_computer_use_status_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_computer_use_status ...'
      end
      # resource path
      local_var_path = '/computeruse/process-status'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ComputerUseStatusResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_computer_use_status",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_computer_use_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get computer use status
    # Get the current status of the computer use system
    # @param [Hash] opts the optional parameters
    # @return [ComputerUseStatusResponse]
    def get_computer_use_system_status(opts = {})
      data, _status_code, _headers = get_computer_use_system_status_with_http_info(opts)
      data
    end

    # Get computer use status
    # Get the current status of the computer use system
    # @param [Hash] opts the optional parameters
    # @return [Array<(ComputerUseStatusResponse, Integer, Hash)>] ComputerUseStatusResponse data, response status code and response headers
    def get_computer_use_system_status_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_computer_use_system_status ...'
      end
      # resource path
      local_var_path = '/computeruse/status'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ComputerUseStatusResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_computer_use_system_status",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_computer_use_system_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get display information
    # Get information about all available displays
    # @param [Hash] opts the optional parameters
    # @return [DisplayInfoResponse]
    def get_display_info(opts = {})
      data, _status_code, _headers = get_display_info_with_http_info(opts)
      data
    end

    # Get display information
    # Get information about all available displays
    # @param [Hash] opts the optional parameters
    # @return [Array<(DisplayInfoResponse, Integer, Hash)>] DisplayInfoResponse data, response status code and response headers
    def get_display_info_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_display_info ...'
      end
      # resource path
      local_var_path = '/computeruse/display/info'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'DisplayInfoResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_display_info",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_display_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get mouse position
    # Get the current mouse cursor position
    # @param [Hash] opts the optional parameters
    # @return [MousePositionResponse]
    def get_mouse_position(opts = {})
      data, _status_code, _headers = get_mouse_position_with_http_info(opts)
      data
    end

    # Get mouse position
    # Get the current mouse cursor position
    # @param [Hash] opts the optional parameters
    # @return [Array<(MousePositionResponse, Integer, Hash)>] MousePositionResponse data, response status code and response headers
    def get_mouse_position_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_mouse_position ...'
      end
      # resource path
      local_var_path = '/computeruse/mouse/position'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'MousePositionResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_mouse_position",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_mouse_position\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get process errors
    # Get errors for a specific computer use process
    # @param process_name [String] Process name to get errors for
    # @param [Hash] opts the optional parameters
    # @return [ProcessErrorsResponse]
    def get_process_errors(process_name, opts = {})
      data, _status_code, _headers = get_process_errors_with_http_info(process_name, opts)
      data
    end

    # Get process errors
    # Get errors for a specific computer use process
    # @param process_name [String] Process name to get errors for
    # @param [Hash] opts the optional parameters
    # @return [Array<(ProcessErrorsResponse, Integer, Hash)>] ProcessErrorsResponse data, response status code and response headers
    def get_process_errors_with_http_info(process_name, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_process_errors ...'
      end
      # verify the required parameter 'process_name' is set
      if @api_client.config.client_side_validation && process_name.nil?
        fail ArgumentError, "Missing the required parameter 'process_name' when calling ComputerUseApi.get_process_errors"
      end
      # resource path
      local_var_path = '/computeruse/process/{processName}/errors'.sub('{' + 'processName' + '}', CGI.escape(process_name.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ProcessErrorsResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_process_errors",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_process_errors\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get process logs
    # Get logs for a specific computer use process
    # @param process_name [String] Process name to get logs for
    # @param [Hash] opts the optional parameters
    # @return [ProcessLogsResponse]
    def get_process_logs(process_name, opts = {})
      data, _status_code, _headers = get_process_logs_with_http_info(process_name, opts)
      data
    end

    # Get process logs
    # Get logs for a specific computer use process
    # @param process_name [String] Process name to get logs for
    # @param [Hash] opts the optional parameters
    # @return [Array<(ProcessLogsResponse, Integer, Hash)>] ProcessLogsResponse data, response status code and response headers
    def get_process_logs_with_http_info(process_name, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_process_logs ...'
      end
      # verify the required parameter 'process_name' is set
      if @api_client.config.client_side_validation && process_name.nil?
        fail ArgumentError, "Missing the required parameter 'process_name' when calling ComputerUseApi.get_process_logs"
      end
      # resource path
      local_var_path = '/computeruse/process/{processName}/logs'.sub('{' + 'processName' + '}', CGI.escape(process_name.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ProcessLogsResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_process_logs",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_process_logs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get specific process status
    # Check if a specific computer use process is running
    # @param process_name [String] Process name to check
    # @param [Hash] opts the optional parameters
    # @return [ProcessStatusResponse]
    def get_process_status(process_name, opts = {})
      data, _status_code, _headers = get_process_status_with_http_info(process_name, opts)
      data
    end

    # Get specific process status
    # Check if a specific computer use process is running
    # @param process_name [String] Process name to check
    # @param [Hash] opts the optional parameters
    # @return [Array<(ProcessStatusResponse, Integer, Hash)>] ProcessStatusResponse data, response status code and response headers
    def get_process_status_with_http_info(process_name, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_process_status ...'
      end
      # verify the required parameter 'process_name' is set
      if @api_client.config.client_side_validation && process_name.nil?
        fail ArgumentError, "Missing the required parameter 'process_name' when calling ComputerUseApi.get_process_status"
      end
      # resource path
      local_var_path = '/computeruse/process/{processName}/status'.sub('{' + 'processName' + '}', CGI.escape(process_name.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ProcessStatusResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_process_status",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_process_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get recording details
    # Get details of a specific recording by ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [Recording]
    def get_recording(id, opts = {})
      data, _status_code, _headers = get_recording_with_http_info(id, opts)
      data
    end

    # Get recording details
    # Get details of a specific recording by ID
    # @param id [String] Recording ID
    # @param [Hash] opts the optional parameters
    # @return [Array<(Recording, Integer, Hash)>] Recording data, response status code and response headers
    def get_recording_with_http_info(id, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_recording ...'
      end
      # verify the required parameter 'id' is set
      if @api_client.config.client_side_validation && id.nil?
        fail ArgumentError, "Missing the required parameter 'id' when calling ComputerUseApi.get_recording"
      end
      # resource path
      local_var_path = '/computeruse/recordings/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'Recording'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_recording",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Get windows information
    # Get information about all open windows
    # @param [Hash] opts the optional parameters
    # @return [WindowsResponse]
    def get_windows(opts = {})
      data, _status_code, _headers = get_windows_with_http_info(opts)
      data
    end

    # Get windows information
    # Get information about all open windows
    # @param [Hash] opts the optional parameters
    # @return [Array<(WindowsResponse, Integer, Hash)>] WindowsResponse data, response status code and response headers
    def get_windows_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.get_windows ...'
      end
      # resource path
      local_var_path = '/computeruse/display/windows'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'WindowsResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.get_windows",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#get_windows\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Invoke an action on an accessibility node
    # Call an AT-SPI Action on the node. Leave action empty to invoke the node's primary (first) action.
    # @param request [AccessibilityInvokeRequest] Invoke request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def invoke_accessibility_node(request, opts = {})
      data, _status_code, _headers = invoke_accessibility_node_with_http_info(request, opts)
      data
    end

    # Invoke an action on an accessibility node
    # Call an AT-SPI Action on the node. Leave action empty to invoke the node&#39;s primary (first) action.
    # @param request [AccessibilityInvokeRequest] Invoke request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def invoke_accessibility_node_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.invoke_accessibility_node ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.invoke_accessibility_node"
      end
      # resource path
      local_var_path = '/computeruse/a11y/node/invoke'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.invoke_accessibility_node",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#invoke_accessibility_node\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # List all recordings
    # Get a list of all recordings (active and completed)
    # @param [Hash] opts the optional parameters
    # @return [ListRecordingsResponse]
    def list_recordings(opts = {})
      data, _status_code, _headers = list_recordings_with_http_info(opts)
      data
    end

    # List all recordings
    # Get a list of all recordings (active and completed)
    # @param [Hash] opts the optional parameters
    # @return [Array<(ListRecordingsResponse, Integer, Hash)>] ListRecordingsResponse data, response status code and response headers
    def list_recordings_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.list_recordings ...'
      end
      # resource path
      local_var_path = '/computeruse/recordings'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ListRecordingsResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.list_recordings",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#list_recordings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Move mouse cursor
    # Move the mouse cursor to the specified coordinates
    # @param request [MouseMoveRequest] Mouse move request
    # @param [Hash] opts the optional parameters
    # @return [MousePositionResponse]
    def move_mouse(request, opts = {})
      data, _status_code, _headers = move_mouse_with_http_info(request, opts)
      data
    end

    # Move mouse cursor
    # Move the mouse cursor to the specified coordinates
    # @param request [MouseMoveRequest] Mouse move request
    # @param [Hash] opts the optional parameters
    # @return [Array<(MousePositionResponse, Integer, Hash)>] MousePositionResponse data, response status code and response headers
    def move_mouse_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.move_mouse ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.move_mouse"
      end
      # resource path
      local_var_path = '/computeruse/mouse/move'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'MousePositionResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.move_mouse",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#move_mouse\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Press hotkey
    # Press a hotkey combination (e.g., ctrl+c, cmd+v)
    # @param request [KeyboardHotkeyRequest] Hotkey press request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def press_hotkey(request, opts = {})
      data, _status_code, _headers = press_hotkey_with_http_info(request, opts)
      data
    end

    # Press hotkey
    # Press a hotkey combination (e.g., ctrl+c, cmd+v)
    # @param request [KeyboardHotkeyRequest] Hotkey press request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def press_hotkey_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.press_hotkey ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.press_hotkey"
      end
      # resource path
      local_var_path = '/computeruse/keyboard/hotkey'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.press_hotkey",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#press_hotkey\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Press key
    # Press a key with optional modifiers
    # @param request [KeyboardPressRequest] Key press request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def press_key(request, opts = {})
      data, _status_code, _headers = press_key_with_http_info(request, opts)
      data
    end

    # Press key
    # Press a key with optional modifiers
    # @param request [KeyboardPressRequest] Key press request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def press_key_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.press_key ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.press_key"
      end
      # resource path
      local_var_path = '/computeruse/keyboard/key'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.press_key",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#press_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Restart specific process
    # Restart a specific computer use process
    # @param process_name [String] Process name to restart
    # @param [Hash] opts the optional parameters
    # @return [ProcessRestartResponse]
    def restart_process(process_name, opts = {})
      data, _status_code, _headers = restart_process_with_http_info(process_name, opts)
      data
    end

    # Restart specific process
    # Restart a specific computer use process
    # @param process_name [String] Process name to restart
    # @param [Hash] opts the optional parameters
    # @return [Array<(ProcessRestartResponse, Integer, Hash)>] ProcessRestartResponse data, response status code and response headers
    def restart_process_with_http_info(process_name, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.restart_process ...'
      end
      # verify the required parameter 'process_name' is set
      if @api_client.config.client_side_validation && process_name.nil?
        fail ArgumentError, "Missing the required parameter 'process_name' when calling ComputerUseApi.restart_process"
      end
      # resource path
      local_var_path = '/computeruse/process/{processName}/restart'.sub('{' + 'processName' + '}', CGI.escape(process_name.to_s))

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ProcessRestartResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.restart_process",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#restart_process\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Scroll mouse wheel
    # Scroll the mouse wheel at the specified coordinates
    # @param request [MouseScrollRequest] Mouse scroll request
    # @param [Hash] opts the optional parameters
    # @return [ScrollResponse]
    def scroll(request, opts = {})
      data, _status_code, _headers = scroll_with_http_info(request, opts)
      data
    end

    # Scroll mouse wheel
    # Scroll the mouse wheel at the specified coordinates
    # @param request [MouseScrollRequest] Mouse scroll request
    # @param [Hash] opts the optional parameters
    # @return [Array<(ScrollResponse, Integer, Hash)>] ScrollResponse data, response status code and response headers
    def scroll_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.scroll ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.scroll"
      end
      # resource path
      local_var_path = '/computeruse/mouse/scroll'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'ScrollResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.scroll",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#scroll\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Set the value of an accessibility node
    # Write the given value to the node via EditableText.SetTextContents or, for numeric controls, Value.CurrentValue.
    # @param request [AccessibilitySetValueRequest] Set value request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def set_accessibility_node_value(request, opts = {})
      data, _status_code, _headers = set_accessibility_node_value_with_http_info(request, opts)
      data
    end

    # Set the value of an accessibility node
    # Write the given value to the node via EditableText.SetTextContents or, for numeric controls, Value.CurrentValue.
    # @param request [AccessibilitySetValueRequest] Set value request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def set_accessibility_node_value_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.set_accessibility_node_value ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.set_accessibility_node_value"
      end
      # resource path
      local_var_path = '/computeruse/a11y/node/value'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.set_accessibility_node_value",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#set_accessibility_node_value\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Start computer use processes
    # Start all computer use processes and return their status
    # @param [Hash] opts the optional parameters
    # @return [ComputerUseStartResponse]
    def start_computer_use(opts = {})
      data, _status_code, _headers = start_computer_use_with_http_info(opts)
      data
    end

    # Start computer use processes
    # Start all computer use processes and return their status
    # @param [Hash] opts the optional parameters
    # @return [Array<(ComputerUseStartResponse, Integer, Hash)>] ComputerUseStartResponse data, response status code and response headers
    def start_computer_use_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.start_computer_use ...'
      end
      # resource path
      local_var_path = '/computeruse/start'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ComputerUseStartResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.start_computer_use",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#start_computer_use\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Start a new recording
    # Start a new screen recording session
    # @param [Hash] opts the optional parameters
    # @option opts [StartRecordingRequest] :request Recording options
    # @return [Recording]
    def start_recording(opts = {})
      data, _status_code, _headers = start_recording_with_http_info(opts)
      data
    end

    # Start a new recording
    # Start a new screen recording session
    # @param [Hash] opts the optional parameters
    # @option opts [StartRecordingRequest] :request Recording options
    # @return [Array<(Recording, Integer, Hash)>] Recording data, response status code and response headers
    def start_recording_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.start_recording ...'
      end
      # resource path
      local_var_path = '/computeruse/recordings/start'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request'])

      # return_type
      return_type = opts[:debug_return_type] || 'Recording'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.start_recording",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#start_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Stop computer use processes
    # Stop all computer use processes and return their status
    # @param [Hash] opts the optional parameters
    # @return [ComputerUseStopResponse]
    def stop_computer_use(opts = {})
      data, _status_code, _headers = stop_computer_use_with_http_info(opts)
      data
    end

    # Stop computer use processes
    # Stop all computer use processes and return their status
    # @param [Hash] opts the optional parameters
    # @return [Array<(ComputerUseStopResponse, Integer, Hash)>] ComputerUseStopResponse data, response status code and response headers
    def stop_computer_use_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.stop_computer_use ...'
      end
      # resource path
      local_var_path = '/computeruse/stop'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ComputerUseStopResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.stop_computer_use",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#stop_computer_use\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Stop a recording
    # Stop an active screen recording session
    # @param request [StopRecordingRequest] Recording ID to stop
    # @param [Hash] opts the optional parameters
    # @return [Recording]
    def stop_recording(request, opts = {})
      data, _status_code, _headers = stop_recording_with_http_info(request, opts)
      data
    end

    # Stop a recording
    # Stop an active screen recording session
    # @param request [StopRecordingRequest] Recording ID to stop
    # @param [Hash] opts the optional parameters
    # @return [Array<(Recording, Integer, Hash)>] Recording data, response status code and response headers
    def stop_recording_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.stop_recording ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.stop_recording"
      end
      # resource path
      local_var_path = '/computeruse/recordings/stop'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Recording'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.stop_recording",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#stop_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Take a compressed region screenshot
    # Take a compressed screenshot of a specific region of the screen
    # @param x [Integer] X coordinate of the region
    # @param y [Integer] Y coordinate of the region
    # @param width [Integer] Width of the region
    # @param height [Integer] Height of the region
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @option opts [String] :format Image format (png or jpeg)
    # @option opts [Integer] :quality JPEG quality (1-100)
    # @option opts [Float] :scale Scale factor (0.1-1.0)
    # @return [ScreenshotResponse]
    def take_compressed_region_screenshot(x, y, width, height, opts = {})
      data, _status_code, _headers = take_compressed_region_screenshot_with_http_info(x, y, width, height, opts)
      data
    end

    # Take a compressed region screenshot
    # Take a compressed screenshot of a specific region of the screen
    # @param x [Integer] X coordinate of the region
    # @param y [Integer] Y coordinate of the region
    # @param width [Integer] Width of the region
    # @param height [Integer] Height of the region
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @option opts [String] :format Image format (png or jpeg)
    # @option opts [Integer] :quality JPEG quality (1-100)
    # @option opts [Float] :scale Scale factor (0.1-1.0)
    # @return [Array<(ScreenshotResponse, Integer, Hash)>] ScreenshotResponse data, response status code and response headers
    def take_compressed_region_screenshot_with_http_info(x, y, width, height, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.take_compressed_region_screenshot ...'
      end
      # verify the required parameter 'x' is set
      if @api_client.config.client_side_validation && x.nil?
        fail ArgumentError, "Missing the required parameter 'x' when calling ComputerUseApi.take_compressed_region_screenshot"
      end
      # verify the required parameter 'y' is set
      if @api_client.config.client_side_validation && y.nil?
        fail ArgumentError, "Missing the required parameter 'y' when calling ComputerUseApi.take_compressed_region_screenshot"
      end
      # verify the required parameter 'width' is set
      if @api_client.config.client_side_validation && width.nil?
        fail ArgumentError, "Missing the required parameter 'width' when calling ComputerUseApi.take_compressed_region_screenshot"
      end
      # verify the required parameter 'height' is set
      if @api_client.config.client_side_validation && height.nil?
        fail ArgumentError, "Missing the required parameter 'height' when calling ComputerUseApi.take_compressed_region_screenshot"
      end
      # resource path
      local_var_path = '/computeruse/screenshot/region/compressed'

      # query parameters
      query_params = opts[:query_params] || {}
      query_params[:'x'] = x
      query_params[:'y'] = y
      query_params[:'width'] = width
      query_params[:'height'] = height
      query_params[:'showCursor'] = opts[:'show_cursor'] if !opts[:'show_cursor'].nil?
      query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
      query_params[:'quality'] = opts[:'quality'] if !opts[:'quality'].nil?
      query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ScreenshotResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.take_compressed_region_screenshot",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#take_compressed_region_screenshot\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Take a compressed screenshot
    # Take a compressed screenshot of the entire screen
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @option opts [String] :format Image format (png or jpeg)
    # @option opts [Integer] :quality JPEG quality (1-100)
    # @option opts [Float] :scale Scale factor (0.1-1.0)
    # @return [ScreenshotResponse]
    def take_compressed_screenshot(opts = {})
      data, _status_code, _headers = take_compressed_screenshot_with_http_info(opts)
      data
    end

    # Take a compressed screenshot
    # Take a compressed screenshot of the entire screen
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @option opts [String] :format Image format (png or jpeg)
    # @option opts [Integer] :quality JPEG quality (1-100)
    # @option opts [Float] :scale Scale factor (0.1-1.0)
    # @return [Array<(ScreenshotResponse, Integer, Hash)>] ScreenshotResponse data, response status code and response headers
    def take_compressed_screenshot_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.take_compressed_screenshot ...'
      end
      # resource path
      local_var_path = '/computeruse/screenshot/compressed'

      # query parameters
      query_params = opts[:query_params] || {}
      query_params[:'showCursor'] = opts[:'show_cursor'] if !opts[:'show_cursor'].nil?
      query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
      query_params[:'quality'] = opts[:'quality'] if !opts[:'quality'].nil?
      query_params[:'scale'] = opts[:'scale'] if !opts[:'scale'].nil?

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ScreenshotResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.take_compressed_screenshot",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#take_compressed_screenshot\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Take a region screenshot
    # Take a screenshot of a specific region of the screen
    # @param x [Integer] X coordinate of the region
    # @param y [Integer] Y coordinate of the region
    # @param width [Integer] Width of the region
    # @param height [Integer] Height of the region
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @return [ScreenshotResponse]
    def take_region_screenshot(x, y, width, height, opts = {})
      data, _status_code, _headers = take_region_screenshot_with_http_info(x, y, width, height, opts)
      data
    end

    # Take a region screenshot
    # Take a screenshot of a specific region of the screen
    # @param x [Integer] X coordinate of the region
    # @param y [Integer] Y coordinate of the region
    # @param width [Integer] Width of the region
    # @param height [Integer] Height of the region
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @return [Array<(ScreenshotResponse, Integer, Hash)>] ScreenshotResponse data, response status code and response headers
    def take_region_screenshot_with_http_info(x, y, width, height, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.take_region_screenshot ...'
      end
      # verify the required parameter 'x' is set
      if @api_client.config.client_side_validation && x.nil?
        fail ArgumentError, "Missing the required parameter 'x' when calling ComputerUseApi.take_region_screenshot"
      end
      # verify the required parameter 'y' is set
      if @api_client.config.client_side_validation && y.nil?
        fail ArgumentError, "Missing the required parameter 'y' when calling ComputerUseApi.take_region_screenshot"
      end
      # verify the required parameter 'width' is set
      if @api_client.config.client_side_validation && width.nil?
        fail ArgumentError, "Missing the required parameter 'width' when calling ComputerUseApi.take_region_screenshot"
      end
      # verify the required parameter 'height' is set
      if @api_client.config.client_side_validation && height.nil?
        fail ArgumentError, "Missing the required parameter 'height' when calling ComputerUseApi.take_region_screenshot"
      end
      # resource path
      local_var_path = '/computeruse/screenshot/region'

      # query parameters
      query_params = opts[:query_params] || {}
      query_params[:'x'] = x
      query_params[:'y'] = y
      query_params[:'width'] = width
      query_params[:'height'] = height
      query_params[:'showCursor'] = opts[:'show_cursor'] if !opts[:'show_cursor'].nil?

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ScreenshotResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.take_region_screenshot",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#take_region_screenshot\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Take a screenshot
    # Take a screenshot of the entire screen
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @return [ScreenshotResponse]
    def take_screenshot(opts = {})
      data, _status_code, _headers = take_screenshot_with_http_info(opts)
      data
    end

    # Take a screenshot
    # Take a screenshot of the entire screen
    # @param [Hash] opts the optional parameters
    # @option opts [Boolean] :show_cursor Whether to show cursor in screenshot
    # @return [Array<(ScreenshotResponse, Integer, Hash)>] ScreenshotResponse data, response status code and response headers
    def take_screenshot_with_http_info(opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.take_screenshot ...'
      end
      # resource path
      local_var_path = '/computeruse/screenshot'

      # query parameters
      query_params = opts[:query_params] || {}
      query_params[:'showCursor'] = opts[:'show_cursor'] if !opts[:'show_cursor'].nil?

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body]

      # return_type
      return_type = opts[:debug_return_type] || 'ScreenshotResponse'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.take_screenshot",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#take_screenshot\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end

    # Type text
    # Type text with optional delay between keystrokes
    # @param request [KeyboardTypeRequest] Text typing request
    # @param [Hash] opts the optional parameters
    # @return [Object]
    def type_text(request, opts = {})
      data, _status_code, _headers = type_text_with_http_info(request, opts)
      data
    end

    # Type text
    # Type text with optional delay between keystrokes
    # @param request [KeyboardTypeRequest] Text typing request
    # @param [Hash] opts the optional parameters
    # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
    def type_text_with_http_info(request, opts = {})
      if @api_client.config.debugging
        @api_client.config.logger.debug 'Calling API: ComputerUseApi.type_text ...'
      end
      # verify the required parameter 'request' is set
      if @api_client.config.client_side_validation && request.nil?
        fail ArgumentError, "Missing the required parameter 'request' when calling ComputerUseApi.type_text"
      end
      # resource path
      local_var_path = '/computeruse/keyboard/type'

      # query parameters
      query_params = opts[:query_params] || {}

      # header parameters
      header_params = opts[:header_params] || {}
      # HTTP header 'Accept' (if needed)
      header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
      # HTTP header 'Content-Type'
      content_type = @api_client.select_header_content_type(['application/json'])
      if !content_type.nil?
          header_params['Content-Type'] = content_type
      end

      # form parameters
      form_params = opts[:form_params] || {}

      # http body (model)
      post_body = opts[:debug_body] || @api_client.object_to_http_body(request)

      # return_type
      return_type = opts[:debug_return_type] || 'Object'

      # auth_names
      auth_names = opts[:debug_auth_names] || []

      new_options = opts.merge(
        :operation => :"ComputerUseApi.type_text",
        :header_params => header_params,
        :query_params => query_params,
        :form_params => form_params,
        :body => post_body,
        :auth_names => auth_names,
        :return_type => return_type
      )

      data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
      if @api_client.config.debugging
        @api_client.config.logger.debug "API called: ComputerUseApi#type_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
      end
      return data, status_code, headers
    end
  end
end
