class asposeemailcloud::EmailClientApi

Attributes

api_client[RW]

Public Class Methods

new(api_client = ApiClient.default) click to toggle source
# File src/asposeemailcloud/api/email_client_api.rb, line 19
def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Public Instance Methods

email_client_append_message(opts = {}) click to toggle source

Append message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [String] :mail_path @option opts [BOOLEAN] :mark_as_sent (default to false) @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 33
def email_client_append_message(opts = {})
  data, _status_code, _headers = email_client_append_message_with_http_info(opts)
  return data
end
email_client_append_message_with_http_info(opts = {}) click to toggle source

Append message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [String] :mail_path @option opts [BOOLEAN] :mark_as_sent @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 48
def email_client_append_message_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_append_message ..."
  end
  # resource path
  local_var_path = "/email/client/Append"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'mailPath'] = opts[:'mail_path'] if !opts[:'mail_path'].nil?
  query_params[:'markAsSent'] = opts[:'mark_as_sent'] if !opts[:'mark_as_sent'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_append_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_append_mime_message(opts = {}) click to toggle source

Append mime message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [String] :base64_mime_message @option opts [BOOLEAN] :mark_as_sent (default to false) @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 100
def email_client_append_mime_message(opts = {})
  data, _status_code, _headers = email_client_append_mime_message_with_http_info(opts)
  return data
end
email_client_append_mime_message_with_http_info(opts = {}) click to toggle source

Append mime message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [String] :base64_mime_message @option opts [BOOLEAN] :mark_as_sent @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 115
def email_client_append_mime_message_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_append_mime_message ..."
  end
  # resource path
  local_var_path = "/email/client/AppendMime"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'markAsSent'] = opts[:'mark_as_sent'] if !opts[:'mark_as_sent'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'base64_mime_message'])
  auth_names = []
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_append_mime_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_create_folder(opts = {}) click to toggle source

Create folder

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :parent_folder @option opts [String] :name @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 165
def email_client_create_folder(opts = {})
  data, _status_code, _headers = email_client_create_folder_with_http_info(opts)
  return data
end
email_client_create_folder_with_http_info(opts = {}) click to toggle source

Create folder

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :parent_folder @option opts [String] :name @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 179
def email_client_create_folder_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_create_folder ..."
  end
  # resource path
  local_var_path = "/email/client/CreateFolder"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'parentFolder'] = opts[:'parent_folder'] if !opts[:'parent_folder'].nil?
  query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_create_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_delete_folder(opts = {}) click to toggle source

Delete folder

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [BOOLEAN] :delete_permanently (default to false) @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 229
def email_client_delete_folder(opts = {})
  data, _status_code, _headers = email_client_delete_folder_with_http_info(opts)
  return data
end
email_client_delete_folder_with_http_info(opts = {}) click to toggle source

Delete folder

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [BOOLEAN] :delete_permanently @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 243
def email_client_delete_folder_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_delete_folder ..."
  end
  # resource path
  local_var_path = "/email/client/DeleteFolder"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'deletePermanently'] = opts[:'delete_permanently'] if !opts[:'delete_permanently'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_delete_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_delete_message(opts = {}) click to toggle source

Delete message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @option opts [BOOLEAN] :delete_permanently (default to false) @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 293
def email_client_delete_message(opts = {})
  data, _status_code, _headers = email_client_delete_message_with_http_info(opts)
  return data
end
email_client_delete_message_with_http_info(opts = {}) click to toggle source

Delete message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @option opts [BOOLEAN] :delete_permanently @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 307
def email_client_delete_message_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_delete_message ..."
  end
  # resource path
  local_var_path = "/email/client/DeleteMessage"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'messageId'] = opts[:'message_id'] if !opts[:'message_id'].nil?
  query_params[:'deletePermanently'] = opts[:'delete_permanently'] if !opts[:'delete_permanently'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_delete_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_fetch_message(opts = {}) click to toggle source

Fetch message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @return [MimeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 356
def email_client_fetch_message(opts = {})
  data, _status_code, _headers = email_client_fetch_message_with_http_info(opts)
  return data
end
email_client_fetch_message_with_http_info(opts = {}) click to toggle source

Fetch message

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @return [Array<(MimeResponse, Fixnum, Hash)>] MimeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 369
def email_client_fetch_message_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_fetch_message ..."
  end
  # resource path
  local_var_path = "/email/client/Fetch"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'messageId'] = opts[:'message_id'] if !opts[:'message_id'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'MimeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_fetch_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_list_folders(opts = {}) click to toggle source

List folders

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :parent_folder @return [ListFoldersResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 417
def email_client_list_folders(opts = {})
  data, _status_code, _headers = email_client_list_folders_with_http_info(opts)
  return data
end
email_client_list_folders_with_http_info(opts = {}) click to toggle source

List folders

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :parent_folder @return [Array<(ListFoldersResponse, Fixnum, Hash)>] ListFoldersResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 430
def email_client_list_folders_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_list_folders ..."
  end
  # resource path
  local_var_path = "/email/client/ListFolders"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'parentFolder'] = opts[:'parent_folder'] if !opts[:'parent_folder'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListFoldersResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_list_folders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_list_messages(opts = {}) click to toggle source

List messages

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [BOOLEAN] :recursive (default to false) @option opts [String] :query_string @return [ListResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 480
def email_client_list_messages(opts = {})
  data, _status_code, _headers = email_client_list_messages_with_http_info(opts)
  return data
end
email_client_list_messages_with_http_info(opts = {}) click to toggle source

List messages

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :folder @option opts [BOOLEAN] :recursive @option opts [String] :query_string @return [Array<(ListResponse, Fixnum, Hash)>] ListResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 495
def email_client_list_messages_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_list_messages ..."
  end
  # resource path
  local_var_path = "/email/client/ListMessages"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'recursive'] = opts[:'recursive'] if !opts[:'recursive'].nil?
  query_params[:'queryString'] = opts[:'query_string'] if !opts[:'query_string'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_list_messages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_save_mail_account(storage, account_name, host, port, login, password, security_options, protocol_type, description, opts = {}) click to toggle source

Save mail account

@param storage @param account_name @param host @param port @param login @param password @param security_options @param protocol_type @param description @param [Hash] opts the optional parameters @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 550
def email_client_save_mail_account(storage, account_name, host, port, login, password, security_options, protocol_type, description, opts = {})
  data, _status_code, _headers = email_client_save_mail_account_with_http_info(storage, account_name, host, port, login, password, security_options, protocol_type, description, opts)
  return data
end
email_client_save_mail_account_with_http_info(storage, account_name, host, port, login, password, security_options, protocol_type, description, opts = {}) click to toggle source

Save mail account

@param storage @param account_name @param host @param port @param login @param password @param security_options @param protocol_type @param description @param [Hash] opts the optional parameters @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 568
def email_client_save_mail_account_with_http_info(storage, account_name, host, port, login, password, security_options, protocol_type, description, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_save_mail_account ..."
  end
  # verify the required parameter 'storage' is set
  if @api_client.config.client_side_validation && storage.nil?
    fail ArgumentError, "Missing the required parameter 'storage' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'account_name' is set
  if @api_client.config.client_side_validation && account_name.nil?
    fail ArgumentError, "Missing the required parameter 'account_name' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'host' is set
  if @api_client.config.client_side_validation && host.nil?
    fail ArgumentError, "Missing the required parameter 'host' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'port' is set
  if @api_client.config.client_side_validation && port.nil?
    fail ArgumentError, "Missing the required parameter 'port' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'login' is set
  if @api_client.config.client_side_validation && login.nil?
    fail ArgumentError, "Missing the required parameter 'login' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'password' is set
  if @api_client.config.client_side_validation && password.nil?
    fail ArgumentError, "Missing the required parameter 'password' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'security_options' is set
  if @api_client.config.client_side_validation && security_options.nil?
    fail ArgumentError, "Missing the required parameter 'security_options' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'protocol_type' is set
  if @api_client.config.client_side_validation && protocol_type.nil?
    fail ArgumentError, "Missing the required parameter 'protocol_type' when calling EmailClientApi.email_client_save_mail_account"
  end
  # verify the required parameter 'description' is set
  if @api_client.config.client_side_validation && description.nil?
    fail ArgumentError, "Missing the required parameter 'description' when calling EmailClientApi.email_client_save_mail_account"
  end
  # resource path
  local_var_path = "/email/client/SaveMailAccount"

  # query parameters
  query_params = {}
  query_params[:'storage'] = storage
  query_params[:'accountName'] = account_name
  query_params[:'host'] = host
  query_params[:'port'] = port
  query_params[:'login'] = login
  query_params[:'password'] = password
  query_params[:'securityOptions'] = security_options
  query_params[:'protocolType'] = protocol_type
  query_params[:'description'] = description

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_save_mail_account\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_save_mail_o_auth_account(storage, account_name, host, port, login, client_id, client_secret, refresh_token, security_options, protocol_type, description, opts = {}) click to toggle source

Save mail oauth account

@param storage @param account_name @param host @param port @param login @param client_id @param client_secret @param refresh_token @param security_options @param protocol_type @param description @param [Hash] opts the optional parameters @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 664
def email_client_save_mail_o_auth_account(storage, account_name, host, port, login, client_id, client_secret, refresh_token, security_options, protocol_type, description, opts = {})
  data, _status_code, _headers = email_client_save_mail_o_auth_account_with_http_info(storage, account_name, host, port, login, client_id, client_secret, refresh_token, security_options, protocol_type, description, opts)
  return data
end
email_client_save_mail_o_auth_account_with_http_info(storage, account_name, host, port, login, client_id, client_secret, refresh_token, security_options, protocol_type, description, opts = {}) click to toggle source

Save mail oauth account

@param storage @param account_name @param host @param port @param login @param client_id @param client_secret @param refresh_token @param security_options @param protocol_type @param description @param [Hash] opts the optional parameters @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 684
def email_client_save_mail_o_auth_account_with_http_info(storage, account_name, host, port, login, client_id, client_secret, refresh_token, security_options, protocol_type, description, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_save_mail_o_auth_account ..."
  end
  # verify the required parameter 'storage' is set
  if @api_client.config.client_side_validation && storage.nil?
    fail ArgumentError, "Missing the required parameter 'storage' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'account_name' is set
  if @api_client.config.client_side_validation && account_name.nil?
    fail ArgumentError, "Missing the required parameter 'account_name' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'host' is set
  if @api_client.config.client_side_validation && host.nil?
    fail ArgumentError, "Missing the required parameter 'host' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'port' is set
  if @api_client.config.client_side_validation && port.nil?
    fail ArgumentError, "Missing the required parameter 'port' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'login' is set
  if @api_client.config.client_side_validation && login.nil?
    fail ArgumentError, "Missing the required parameter 'login' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'client_id' is set
  if @api_client.config.client_side_validation && client_id.nil?
    fail ArgumentError, "Missing the required parameter 'client_id' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'client_secret' is set
  if @api_client.config.client_side_validation && client_secret.nil?
    fail ArgumentError, "Missing the required parameter 'client_secret' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'refresh_token' is set
  if @api_client.config.client_side_validation && refresh_token.nil?
    fail ArgumentError, "Missing the required parameter 'refresh_token' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'security_options' is set
  if @api_client.config.client_side_validation && security_options.nil?
    fail ArgumentError, "Missing the required parameter 'security_options' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'protocol_type' is set
  if @api_client.config.client_side_validation && protocol_type.nil?
    fail ArgumentError, "Missing the required parameter 'protocol_type' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # verify the required parameter 'description' is set
  if @api_client.config.client_side_validation && description.nil?
    fail ArgumentError, "Missing the required parameter 'description' when calling EmailClientApi.email_client_save_mail_o_auth_account"
  end
  # resource path
  local_var_path = "/email/client/SaveMailOAuthAccount"

  # query parameters
  query_params = {}
  query_params[:'storage'] = storage
  query_params[:'accountName'] = account_name
  query_params[:'host'] = host
  query_params[:'port'] = port
  query_params[:'login'] = login
  query_params[:'clientId'] = client_id
  query_params[:'clientSecret'] = client_secret
  query_params[:'refreshToken'] = refresh_token
  query_params[:'securityOptions'] = security_options
  query_params[:'protocolType'] = protocol_type
  query_params[:'description'] = description

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_save_mail_o_auth_account\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_send(opts = {}) click to toggle source

Send

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :mail_path @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 783
def email_client_send(opts = {})
  data, _status_code, _headers = email_client_send_with_http_info(opts)
  return data
end
email_client_send_mime(opts = {}) click to toggle source

Send Mime

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :base64_mime_message @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 844
def email_client_send_mime(opts = {})
  data, _status_code, _headers = email_client_send_mime_with_http_info(opts)
  return data
end
email_client_send_mime_with_http_info(opts = {}) click to toggle source

Send Mime

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :base64_mime_message @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 857
def email_client_send_mime_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_send_mime ..."
  end
  # resource path
  local_var_path = "/email/client/SendMime"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'base64_mime_message'])
  auth_names = []
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_send_mime\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_send_with_http_info(opts = {}) click to toggle source

Send

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :mail_path @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 796
def email_client_send_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_send ..."
  end
  # resource path
  local_var_path = "/email/client/Send"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'mailPath'] = opts[:'mail_path'] if !opts[:'mail_path'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_send\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
email_client_set_read_flag(opts = {}) click to toggle source

Set read flag

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @option opts [BOOLEAN] :is_read (default to false) @return [SaaSposeResponse]

# File src/asposeemailcloud/api/email_client_api.rb, line 905
def email_client_set_read_flag(opts = {})
  data, _status_code, _headers = email_client_set_read_flag_with_http_info(opts)
  return data
end
email_client_set_read_flag_with_http_info(opts = {}) click to toggle source

Set read flag

@param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :account_name1 @option opts [String] :account_name2 @option opts [String] :message_id @option opts [BOOLEAN] :is_read @return [Array<(SaaSposeResponse, Fixnum, Hash)>] SaaSposeResponse data, response status code and response headers

# File src/asposeemailcloud/api/email_client_api.rb, line 919
def email_client_set_read_flag_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailClientApi.email_client_set_read_flag ..."
  end
  # resource path
  local_var_path = "/email/client/SetReadFlag"

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'accountName1'] = opts[:'account_name1'] if !opts[:'account_name1'].nil?
  query_params[:'accountName2'] = opts[:'account_name2'] if !opts[:'account_name2'].nil?
  query_params[:'messageId'] = opts[:'message_id'] if !opts[:'message_id'].nil?
  query_params[:'isRead'] = opts[:'is_read'] if !opts[:'is_read'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'SaaSposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailClientApi#email_client_set_read_flag\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end