class DocuSign_eSign::EmailArchiveApi

Attributes

api_client[RW]

Public Class Methods

new(api_client = EmailArchiveApi.default) click to toggle source
# File lib/docusign_esign/api/email_archive_api.rb, line 44
def initialize(api_client = EmailArchiveApi.default)
  @api_client = api_client
end

Public Instance Methods

create_bcc_email_archive(account_id, bcc_email_archive) click to toggle source

Creates a blind carbon copy email archive entry

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive (optional parameter) @return [BccEmailArchive]

# File lib/docusign_esign/api/email_archive_api.rb, line 53
def create_bcc_email_archive(account_id, bcc_email_archive)
  data, _status_code, _headers = create_bcc_email_archive_with_http_info(account_id,  bcc_email_archive)
  return data
end
create_bcc_email_archive_with_http_info(account_id, bcc_email_archive) click to toggle source

Creates a blind carbon copy email archive entry

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive (optional parameter) @return [Array<(BccEmailArchive, Fixnum, Hash)>] BccEmailArchive data, response status code and response headers

# File lib/docusign_esign/api/email_archive_api.rb, line 63
def create_bcc_email_archive_with_http_info(account_id, bcc_email_archive)
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailArchiveApi.create_bcc_email_archive ..."
  end
  # verify the required parameter 'account_id' is set
  fail ArgumentError, "Missing the required parameter 'account_id' when calling EmailArchiveApi.create_bcc_email_archive" if account_id.nil?
  # resource path
  local_var_path = "/v2.1/accounts/{accountId}/settings/bcc_email_archives".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)

  # query parameters
  query_params = {}

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

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(bcc_email_archive)
  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 => 'BccEmailArchive')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailArchiveApi#create_bcc_email_archive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_bcc_email_archive(account_id, bcc_email_archive_id) click to toggle source

Delete a blind carbon copy email archive for an account.

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive_id @return [nil]

# File lib/docusign_esign/api/email_archive_api.rb, line 104
def delete_bcc_email_archive(account_id, bcc_email_archive_id)
  delete_bcc_email_archive_with_http_info(account_id, bcc_email_archive_id)
  return nil
end
delete_bcc_email_archive_with_http_info(account_id, bcc_email_archive_id) click to toggle source

Delete a blind carbon copy email archive for an account.

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive_id @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/docusign_esign/api/email_archive_api.rb, line 114
def delete_bcc_email_archive_with_http_info(account_id, bcc_email_archive_id)
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailArchiveApi.delete_bcc_email_archive ..."
  end
  # verify the required parameter 'account_id' is set
  fail ArgumentError, "Missing the required parameter 'account_id' when calling EmailArchiveApi.delete_bcc_email_archive" if account_id.nil?
  # verify the required parameter 'bcc_email_archive_id' is set
  fail ArgumentError, "Missing the required parameter 'bcc_email_archive_id' when calling EmailArchiveApi.delete_bcc_email_archive" if bcc_email_archive_id.nil?
  # resource path
  local_var_path = "/v2.1/accounts/{accountId}/settings/bcc_email_archives/{bccEmailArchiveId}".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'bccEmailArchiveId' + '}', bcc_email_archive_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailArchiveApi#delete_bcc_email_archive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_bcc_email_archive_history_list(account_id, bcc_email_archive_id, options = DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions.default) click to toggle source

Get the blind carbon copy email archive history entries for the specified archive

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive_id @param DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions Options for modifying the behavior of the function. @return [BccEmailArchiveHistoryList]

# File lib/docusign_esign/api/email_archive_api.rb, line 157
def get_bcc_email_archive_history_list(account_id, bcc_email_archive_id, options = DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions.default)
  data, _status_code, _headers = get_bcc_email_archive_history_list_with_http_info(account_id, bcc_email_archive_id, options)
  return data
end
get_bcc_email_archive_history_list_with_http_info(account_id, bcc_email_archive_id, options = DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions.default) click to toggle source

Get the blind carbon copy email archive history entries for the specified archive

@param account_id The external account number (int) or account ID Guid. @param bcc_email_archive_id @param DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions Options for modifying the behavior of the function. @return [Array<(BccEmailArchiveHistoryList, Fixnum, Hash)>] BccEmailArchiveHistoryList data, response status code and response headers

# File lib/docusign_esign/api/email_archive_api.rb, line 168
def get_bcc_email_archive_history_list_with_http_info(account_id, bcc_email_archive_id, options = DocuSign_eSign::GetBCCEmailArchiveHistoryListOptions.default)
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailArchiveApi.get_bcc_email_archive_history_list ..."
  end
  # verify the required parameter 'account_id' is set
  fail ArgumentError, "Missing the required parameter 'account_id' when calling EmailArchiveApi.get_bcc_email_archive_history_list" if account_id.nil?
  # verify the required parameter 'bcc_email_archive_id' is set
  fail ArgumentError, "Missing the required parameter 'bcc_email_archive_id' when calling EmailArchiveApi.get_bcc_email_archive_history_list" if bcc_email_archive_id.nil?
  # resource path
  local_var_path = "/v2.1/accounts/{accountId}/settings/bcc_email_archives/{bccEmailArchiveId}".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s).sub('{' + 'bccEmailArchiveId' + '}', bcc_email_archive_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'count'] = options.count if !options.count.nil?
  query_params[:'start_position'] = options.start_position if !options.start_position.nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['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 => 'BccEmailArchiveHistoryList')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailArchiveApi#get_bcc_email_archive_history_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_bcc_email_archive_list(account_id, options = DocuSign_eSign::GetBCCEmailArchiveListOptions.default) click to toggle source

Get the blind carbon copy email archive entries owned by the specified account

@param account_id The external account number (int) or account ID Guid. @param DocuSign_eSign::GetBCCEmailArchiveListOptions Options for modifying the behavior of the function. @return [BccEmailArchiveList]

# File lib/docusign_esign/api/email_archive_api.rb, line 213
def get_bcc_email_archive_list(account_id, options = DocuSign_eSign::GetBCCEmailArchiveListOptions.default)
  data, _status_code, _headers = get_bcc_email_archive_list_with_http_info(account_id, options)
  return data
end
get_bcc_email_archive_list_with_http_info(account_id, options = DocuSign_eSign::GetBCCEmailArchiveListOptions.default) click to toggle source

Get the blind carbon copy email archive entries owned by the specified account

@param account_id The external account number (int) or account ID Guid. @param DocuSign_eSign::GetBCCEmailArchiveListOptions Options for modifying the behavior of the function. @return [Array<(BccEmailArchiveList, Fixnum, Hash)>] BccEmailArchiveList data, response status code and response headers

# File lib/docusign_esign/api/email_archive_api.rb, line 223
def get_bcc_email_archive_list_with_http_info(account_id, options = DocuSign_eSign::GetBCCEmailArchiveListOptions.default)
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EmailArchiveApi.get_bcc_email_archive_list ..."
  end
  # verify the required parameter 'account_id' is set
  fail ArgumentError, "Missing the required parameter 'account_id' when calling EmailArchiveApi.get_bcc_email_archive_list" if account_id.nil?
  # resource path
  local_var_path = "/v2.1/accounts/{accountId}/settings/bcc_email_archives".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'count'] = options.count if !options.count.nil?
  query_params[:'start_position'] = options.start_position if !options.start_position.nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['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 => 'BccEmailArchiveList')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EmailArchiveApi#get_bcc_email_archive_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end