class AsposePdfCloud::PdfApi

Attributes

api_client[RW]

Public Class Methods

new(app_key, app_sid, api_client = ApiClient.default) click to toggle source
# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28
def initialize(app_key, app_sid, api_client = ApiClient.default)
  @api_client = api_client
  @api_client.config.app_key = app_key
  @api_client.config.app_sid = app_sid
end

Public Instance Methods

copy_file(src_path, dest_path, opts = {}) click to toggle source

Copy file

@param src_path Source file path e.g. '/folder/file.ext' @param dest_path Destination file path @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @option opts [String] :version_id File version ID to copy @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 44
def copy_file(src_path, dest_path, opts = {})
  @api_client.request_token_if_needed
  copy_file_with_http_info(src_path, dest_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      copy_file_with_http_info(src_path, dest_path, opts)
    else
      raise
    end
  return nil
end
copy_file_with_http_info(src_path, dest_path, opts = {}) click to toggle source

Copy file

@param src_path Source file path e.g. &#39;/folder/file.ext&#39; @param dest_path Destination file path @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @option opts [String] :version_id File version ID to copy @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 66
def copy_file_with_http_info(src_path, dest_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.copy_file ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.copy_file"
  end
  # verify the required parameter 'dest_path' is set
  if @api_client.config.client_side_validation && dest_path.nil?
    fail ArgumentError, "Missing the required parameter 'dest_path' when calling PdfApi.copy_file"
  end
  # resource path
  local_var_path = "/pdf/storage/file/copy/{srcPath}".sub('{' + 'srcPath' + '}', src_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'destPath'] = dest_path
  query_params[:'srcStorageName'] = opts[:'src_storage_name'] if !opts[:'src_storage_name'].nil?
  query_params[:'destStorageName'] = opts[:'dest_storage_name'] if !opts[:'dest_storage_name'].nil?
  query_params[:'versionId'] = opts[:'version_id'] if !opts[:'version_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#copy_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
copy_folder(src_path, dest_path, opts = {}) click to toggle source

Copy folder

@param src_path Source folder path e.g. &#39;/src&#39; @param dest_path Destination folder path e.g. &#39;/dst&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 124
def copy_folder(src_path, dest_path, opts = {})
  @api_client.request_token_if_needed
  copy_folder_with_http_info(src_path, dest_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      copy_folder_with_http_info(src_path, dest_path, opts)
    else
      raise
    end
  return nil
end
copy_folder_with_http_info(src_path, dest_path, opts = {}) click to toggle source

Copy folder

@param src_path Source folder path e.g. &#39;/src&#39; @param dest_path Destination folder path e.g. &#39;/dst&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 145
def copy_folder_with_http_info(src_path, dest_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.copy_folder ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.copy_folder"
  end
  # verify the required parameter 'dest_path' is set
  if @api_client.config.client_side_validation && dest_path.nil?
    fail ArgumentError, "Missing the required parameter 'dest_path' when calling PdfApi.copy_folder"
  end
  # resource path
  local_var_path = "/pdf/storage/folder/copy/{srcPath}".sub('{' + 'srcPath' + '}', src_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'destPath'] = dest_path
  query_params[:'srcStorageName'] = opts[:'src_storage_name'] if !opts[:'src_storage_name'].nil?
  query_params[:'destStorageName'] = opts[:'dest_storage_name'] if !opts[:'dest_storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#copy_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
create_folder(path, opts = {}) click to toggle source

Create the folder

@param path Folder path to create e.g. &#39;folder_1/folder_2/&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 200
def create_folder(path, opts = {})
  @api_client.request_token_if_needed
  create_folder_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      create_folder_with_http_info(path, opts)
    else
      raise
    end
  return nil
end
create_folder_with_http_info(path, opts = {}) click to toggle source

Create the folder

@param path Folder path to create e.g. &#39;folder_1/folder_2/&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 219
def create_folder_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.create_folder ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.create_folder"
  end
  # resource path
  local_var_path = "/pdf/storage/folder/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#create_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_annotation(name, annotation_id, opts = {}) click to toggle source

Delete document annotation by ID

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 270
def delete_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
delete_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Delete document annotation by ID

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 291
def delete_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.delete_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_bookmark(name, bookmark_path, opts = {}) click to toggle source

Delete document bookmark by ID.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 348
def delete_bookmark(name, bookmark_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_bookmark_with_http_info(name, bookmark_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_bookmark_with_http_info(name, bookmark_path, opts)
    else
      raise
    end
  return data
end
delete_bookmark_with_http_info(name, bookmark_path, opts = {}) click to toggle source

Delete document bookmark by ID.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 369
def delete_bookmark_with_http_info(name, bookmark_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_bookmark ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_bookmark"
  end
  # verify the required parameter 'bookmark_path' is set
  if @api_client.config.client_side_validation && bookmark_path.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark_path' when calling PdfApi.delete_bookmark"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/bookmark/{bookmarkPath}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'bookmarkPath' + '}', bookmark_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_bookmark\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_document_annotations(name, opts = {}) click to toggle source

Delete all annotations from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 425
def delete_document_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_document_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_document_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
delete_document_annotations_with_http_info(name, opts = {}) click to toggle source

Delete all annotations from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 445
def delete_document_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_document_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_document_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_document_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_document_bookmarks(name, opts = {}) click to toggle source

Delete all document bookmarks.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 497
def delete_document_bookmarks(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_document_bookmarks_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_document_bookmarks_with_http_info(name, opts)
    else
      raise
    end
  return data
end
delete_document_bookmarks_with_http_info(name, opts = {}) click to toggle source

Delete all document bookmarks.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 517
def delete_document_bookmarks_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_document_bookmarks ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_document_bookmarks"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/tree".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_document_bookmarks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_document_stamps(name, opts = {}) click to toggle source

Delete all stamps from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 641
def delete_document_stamps(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_document_stamps_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_document_stamps_with_http_info(name, opts)
    else
      raise
    end
  return data
end
delete_document_stamps_with_http_info(name, opts = {}) click to toggle source

Delete all stamps from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 661
def delete_document_stamps_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_document_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_document_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/stamps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_document_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_document_tables(name, opts = {}) click to toggle source

Delete all tables from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 713
def delete_document_tables(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_document_tables_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_document_tables_with_http_info(name, opts)
    else
      raise
    end
  return data
end
delete_document_tables_with_http_info(name, opts = {}) click to toggle source

Delete all tables from the document

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 733
def delete_document_tables_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_document_tables ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_document_tables"
  end
  # resource path
  local_var_path = "/pdf/{name}/tables".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_document_tables\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_field(name, field_name, opts = {}) click to toggle source

Delete document field by name.

@param name The document name. @param field_name The field name/ @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 786
def delete_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
delete_field_with_http_info(name, field_name, opts = {}) click to toggle source

Delete document field by name.

@param name The document name. @param field_name The field name/ @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 807
def delete_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.delete_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_file(path, opts = {}) click to toggle source

Delete file

@param path File path e.g. &#39;/folder/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID to delete @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 863
def delete_file(path, opts = {})
  @api_client.request_token_if_needed
  delete_file_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      delete_file_with_http_info(path, opts)
    else
      raise
    end
  return nil
end
delete_file_with_http_info(path, opts = {}) click to toggle source

Delete file

@param path File path e.g. &#39;/folder/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID to delete @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 883
def delete_file_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_file ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.delete_file"
  end
  # resource path
  local_var_path = "/pdf/storage/file/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_name'].nil?
  query_params[:'versionId'] = opts[:'version_id'] if !opts[:'version_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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: PdfApi#delete_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_folder(path, opts = {}) click to toggle source

Delete folder

@param path Folder path e.g. &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [BOOLEAN] :recursive Enable to delete folders, subfolders and files (default to false) @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 934
def delete_folder(path, opts = {})
  @api_client.request_token_if_needed
  delete_folder_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      delete_folder_with_http_info(path, opts)
    else
      raise
    end
  return nil
end
delete_folder_with_http_info(path, opts = {}) click to toggle source

Delete folder

@param path Folder path e.g. &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [BOOLEAN] :recursive Enable to delete folders, subfolders and files @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 954
def delete_folder_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_folder ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.delete_folder"
  end
  # resource path
  local_var_path = "/pdf/storage/folder/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_name'].nil?
  query_params[:'recursive'] = opts[:'recursive'] if !opts[:'recursive'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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: PdfApi#delete_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_image(name, image_id, opts = {}) click to toggle source

Delete image from document page.

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1006
def delete_image(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_image_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_image_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
delete_image_with_http_info(name, image_id, opts = {}) click to toggle source

Delete image from document page.

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1027
def delete_image_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_image ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_image"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.delete_image"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_page(name, page_number, opts = {}) click to toggle source

Delete document page by its number.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1162
def delete_page(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_page_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_page_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
delete_page_annotations(name, page_number, opts = {}) click to toggle source

Delete all annotations from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1240
def delete_page_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_page_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_page_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
delete_page_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Delete all annotations from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1261
def delete_page_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_page_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_page_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.delete_page_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_page_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_page_stamps(name, page_number, opts = {}) click to toggle source

Delete all stamps from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1396
def delete_page_stamps(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_page_stamps_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_page_stamps_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
delete_page_stamps_with_http_info(name, page_number, opts = {}) click to toggle source

Delete all stamps from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1417
def delete_page_stamps_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_page_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_page_stamps"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.delete_page_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamps".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_page_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_page_tables(name, page_number, opts = {}) click to toggle source

Delete all tables from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1474
def delete_page_tables(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_page_tables_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_page_tables_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
delete_page_tables_with_http_info(name, page_number, opts = {}) click to toggle source

Delete all tables from the page

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1495
def delete_page_tables_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_page_tables ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_page_tables"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.delete_page_tables"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/tables".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_page_tables\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_page_with_http_info(name, page_number, opts = {}) click to toggle source

Delete document page by its number.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1183
def delete_page_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_page"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.delete_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_properties(name, opts = {}) click to toggle source

Delete custom document properties.

@param name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1551
def delete_properties(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_properties_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_properties_with_http_info(name, opts)
    else
      raise
    end
  return data
end
delete_properties_with_http_info(name, opts = {}) click to toggle source

Delete custom document properties.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1571
def delete_properties_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_properties ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_properties"
  end
  # resource path
  local_var_path = "/pdf/{name}/documentproperties".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_property(name, property_name, opts = {}) click to toggle source

Delete document property.

@param name @param property_name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1624
def delete_property(name, property_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_property_with_http_info(name, property_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_property_with_http_info(name, property_name, opts)
    else
      raise
    end
  return data
end
delete_property_with_http_info(name, property_name, opts = {}) click to toggle source

Delete document property.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1645
def delete_property_with_http_info(name, property_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_property ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_property"
  end
  # verify the required parameter 'property_name' is set
  if @api_client.config.client_side_validation && property_name.nil?
    fail ArgumentError, "Missing the required parameter 'property_name' when calling PdfApi.delete_property"
  end
  # resource path
  local_var_path = "/pdf/{name}/documentproperties/{propertyName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'propertyName' + '}', property_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_property\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_stamp(name, stamp_id, opts = {}) click to toggle source

Delete document stamp by ID

@param name The document name. @param stamp_id The stamp ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1702
def delete_stamp(name, stamp_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_stamp_with_http_info(name, stamp_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_stamp_with_http_info(name, stamp_id, opts)
    else
      raise
    end
  return data
end
delete_stamp_with_http_info(name, stamp_id, opts = {}) click to toggle source

Delete document stamp by ID

@param name The document name. @param stamp_id The stamp ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1723
def delete_stamp_with_http_info(name, stamp_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_stamp ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_stamp"
  end
  # verify the required parameter 'stamp_id' is set
  if @api_client.config.client_side_validation && stamp_id.nil?
    fail ArgumentError, "Missing the required parameter 'stamp_id' when calling PdfApi.delete_stamp"
  end
  # resource path
  local_var_path = "/pdf/{name}/stamps/{stampId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'stampId' + '}', stamp_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_stamp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
delete_table(name, table_id, opts = {}) click to toggle source

Delete document table by ID

@param name The document name. @param table_id The table ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1780
def delete_table(name, table_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = delete_table_with_http_info(name, table_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = delete_table_with_http_info(name, table_id, opts)
    else
      raise
    end
  return data
end
delete_table_with_http_info(name, table_id, opts = {}) click to toggle source

Delete document table by ID

@param name The document name. @param table_id The table ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1801
def delete_table_with_http_info(name, table_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.delete_table ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.delete_table"
  end
  # verify the required parameter 'table_id' is set
  if @api_client.config.client_side_validation && table_id.nil?
    fail ArgumentError, "Missing the required parameter 'table_id' when calling PdfApi.delete_table"
  end
  # resource path
  local_var_path = "/pdf/{name}/tables/{tableId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'tableId' + '}', table_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#delete_table\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
download_file(path, opts = {}) click to toggle source

Download file

@param path File path e.g. &#39;/folder/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID to download @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1857
def download_file(path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = download_file_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = download_file_with_http_info(path, opts)
    else
      raise
    end
  return data
end
download_file_with_http_info(path, opts = {}) click to toggle source

Download file

@param path File path e.g. &#39;/folder/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID to download @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1877
def download_file_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.download_file ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.download_file"
  end
  # resource path
  local_var_path = "/pdf/storage/file/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_name'].nil?
  query_params[:'versionId'] = opts[:'version_id'] if !opts[:'version_id'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#download_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_bookmark(name, bookmark_path, opts = {}) click to toggle source

Read document bookmark.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [BookmarkResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1930
def get_bookmark(name, bookmark_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_bookmark_with_http_info(name, bookmark_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_bookmark_with_http_info(name, bookmark_path, opts)
    else
      raise
    end
  return data
end
get_bookmark_with_http_info(name, bookmark_path, opts = {}) click to toggle source

Read document bookmark.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(BookmarkResponse, Fixnum, Hash)>] BookmarkResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 1951
def get_bookmark_with_http_info(name, bookmark_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_bookmark ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_bookmark"
  end
  # verify the required parameter 'bookmark_path' is set
  if @api_client.config.client_side_validation && bookmark_path.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark_path' when calling PdfApi.get_bookmark"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/bookmark/{bookmarkPath}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'bookmarkPath' + '}', bookmark_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'BookmarkResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_bookmark\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_bookmarks(name, bookmark_path, opts = {}) click to toggle source

Read document bookmarks node list.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [BookmarksResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2008
def get_bookmarks(name, bookmark_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_bookmarks_with_http_info(name, bookmark_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_bookmarks_with_http_info(name, bookmark_path, opts)
    else
      raise
    end
  return data
end
get_bookmarks_with_http_info(name, bookmark_path, opts = {}) click to toggle source

Read document bookmarks node list.

@param name The document name. @param bookmark_path The bookmark path. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(BookmarksResponse, Fixnum, Hash)>] BookmarksResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2029
def get_bookmarks_with_http_info(name, bookmark_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_bookmarks ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_bookmarks"
  end
  # verify the required parameter 'bookmark_path' is set
  if @api_client.config.client_side_validation && bookmark_path.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark_path' when calling PdfApi.get_bookmarks"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/list/{bookmarkPath}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'bookmarkPath' + '}', bookmark_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'BookmarksResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_bookmarks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_caret_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page caret annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CaretAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2086
def get_caret_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_caret_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_caret_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_caret_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page caret annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CaretAnnotationResponse, Fixnum, Hash)>] CaretAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2107
def get_caret_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_caret_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_caret_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_caret_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/caret/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CaretAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_caret_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_check_box_field(name, field_name, opts = {}) click to toggle source

Read document checkbox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CheckBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2164
def get_check_box_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_check_box_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_check_box_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_check_box_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document checkbox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CheckBoxFieldResponse, Fixnum, Hash)>] CheckBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2185
def get_check_box_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_check_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_check_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_check_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/checkbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CheckBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_check_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_circle_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page circle annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CircleAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2242
def get_circle_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_circle_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_circle_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_circle_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page circle annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CircleAnnotationResponse, Fixnum, Hash)>] CircleAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2263
def get_circle_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_circle_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_circle_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_circle_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/circle/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CircleAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_circle_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_combo_box_field(name, field_name, opts = {}) click to toggle source

Read document combobox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ComboBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2320
def get_combo_box_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_combo_box_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_combo_box_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_combo_box_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document combobox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ComboBoxFieldResponse, Fixnum, Hash)>] ComboBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2341
def get_combo_box_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_combo_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_combo_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_combo_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/combobox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ComboBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_combo_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_disc_usage(opts = {}) click to toggle source

Get disc usage

@param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [DiscUsage]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2395
def get_disc_usage(opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_disc_usage_with_http_info(opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_disc_usage_with_http_info(opts)
    else
      raise
    end
  return data
end
get_disc_usage_with_http_info(opts = {}) click to toggle source

Get disc usage

@param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [Array<(DiscUsage, Fixnum, Hash)>] DiscUsage data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2413
def get_disc_usage_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_disc_usage ..."
  end
  # resource path
  local_var_path = "/pdf/storage/disc"

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DiscUsage')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_disc_usage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document(name, opts = {}) click to toggle source

Read common document info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [DocumentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2460
def get_document(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_annotations(name, opts = {}) click to toggle source

Read document page annotations. Returns only FreeTextAnnotations, TextAnnotations, other annotations will implemented next releases.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AnnotationsInfoResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2532
def get_document_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_annotations_with_http_info(name, opts = {}) click to toggle source

Read document page annotations. Returns only FreeTextAnnotations, TextAnnotations, other annotations will implemented next releases.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AnnotationsInfoResponse, Fixnum, Hash)>] AnnotationsInfoResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2552
def get_document_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AnnotationsInfoResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_attachment_by_index(name, attachment_index, opts = {}) click to toggle source

Read document attachment info by its index.

@param name The document name. @param attachment_index The attachment index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AttachmentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2605
def get_document_attachment_by_index(name, attachment_index, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_attachment_by_index_with_http_info(name, attachment_index, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_attachment_by_index_with_http_info(name, attachment_index, opts)
    else
      raise
    end
  return data
end
get_document_attachment_by_index_with_http_info(name, attachment_index, opts = {}) click to toggle source

Read document attachment info by its index.

@param name The document name. @param attachment_index The attachment index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AttachmentResponse, Fixnum, Hash)>] AttachmentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2626
def get_document_attachment_by_index_with_http_info(name, attachment_index, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_attachment_by_index ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_attachment_by_index"
  end
  # verify the required parameter 'attachment_index' is set
  if @api_client.config.client_side_validation && attachment_index.nil?
    fail ArgumentError, "Missing the required parameter 'attachment_index' when calling PdfApi.get_document_attachment_by_index"
  end
  # resource path
  local_var_path = "/pdf/{name}/attachments/{attachmentIndex}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'attachmentIndex' + '}', attachment_index.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AttachmentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_attachment_by_index\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_attachments(name, opts = {}) click to toggle source

Read document attachments info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AttachmentsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2682
def get_document_attachments(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_attachments_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_attachments_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_attachments_with_http_info(name, opts = {}) click to toggle source

Read document attachments info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AttachmentsResponse, Fixnum, Hash)>] AttachmentsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2702
def get_document_attachments_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_attachments ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_attachments"
  end
  # resource path
  local_var_path = "/pdf/{name}/attachments".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AttachmentsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_attachments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_bookmarks(name, opts = {}) click to toggle source

Read document bookmarks tree.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [BookmarksResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2754
def get_document_bookmarks(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_bookmarks_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_bookmarks_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_bookmarks_with_http_info(name, opts = {}) click to toggle source

Read document bookmarks tree.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(BookmarksResponse, Fixnum, Hash)>] BookmarksResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2774
def get_document_bookmarks_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_bookmarks ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_bookmarks"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/tree".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'BookmarksResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_bookmarks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_caret_annotations(name, opts = {}) click to toggle source

Read document caret annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CaretAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2826
def get_document_caret_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_caret_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_caret_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_caret_annotations_with_http_info(name, opts = {}) click to toggle source

Read document caret annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CaretAnnotationsResponse, Fixnum, Hash)>] CaretAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2846
def get_document_caret_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_caret_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_caret_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/caret".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CaretAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_caret_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_check_box_fields(name, opts = {}) click to toggle source

Read document checkbox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CheckBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2898
def get_document_check_box_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_check_box_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_check_box_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_check_box_fields_with_http_info(name, opts = {}) click to toggle source

Read document checkbox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CheckBoxFieldsResponse, Fixnum, Hash)>] CheckBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2918
def get_document_check_box_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_check_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_check_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/checkbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CheckBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_check_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_circle_annotations(name, opts = {}) click to toggle source

Read document circle annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CircleAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2970
def get_document_circle_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_circle_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_circle_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_circle_annotations_with_http_info(name, opts = {}) click to toggle source

Read document circle annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CircleAnnotationsResponse, Fixnum, Hash)>] CircleAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2990
def get_document_circle_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_circle_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_circle_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/circle".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CircleAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_circle_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_combo_box_fields(name, opts = {}) click to toggle source

Read document combobox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ComboBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3042
def get_document_combo_box_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_combo_box_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_combo_box_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_combo_box_fields_with_http_info(name, opts = {}) click to toggle source

Read document combobox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ComboBoxFieldsResponse, Fixnum, Hash)>] ComboBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3062
def get_document_combo_box_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_combo_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_combo_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/combobox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ComboBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_combo_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_display_properties(name, opts = {}) click to toggle source

Read document display properties.

@param name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [DisplayPropertiesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3114
def get_document_display_properties(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_display_properties_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_display_properties_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_display_properties_with_http_info(name, opts = {}) click to toggle source

Read document display properties.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3134
def get_document_display_properties_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_display_properties ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_display_properties"
  end
  # resource path
  local_var_path = "/pdf/{name}/displayproperties".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DisplayPropertiesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_display_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_file_attachment_annotations(name, opts = {}) click to toggle source

Read document FileAttachment annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FileAttachmentAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3186
def get_document_file_attachment_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_file_attachment_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_file_attachment_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_file_attachment_annotations_with_http_info(name, opts = {}) click to toggle source

Read document FileAttachment annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FileAttachmentAnnotationsResponse, Fixnum, Hash)>] FileAttachmentAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3206
def get_document_file_attachment_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_file_attachment_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_file_attachment_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/fileattachment".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FileAttachmentAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_file_attachment_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_free_text_annotations(name, opts = {}) click to toggle source

Read document free text annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FreeTextAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3258
def get_document_free_text_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_free_text_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_free_text_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_free_text_annotations_with_http_info(name, opts = {}) click to toggle source

Read document free text annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FreeTextAnnotationsResponse, Fixnum, Hash)>] FreeTextAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3278
def get_document_free_text_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_free_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_free_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/freetext".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FreeTextAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_free_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_highlight_annotations(name, opts = {}) click to toggle source

Read document highlight annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [HighlightAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3330
def get_document_highlight_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_highlight_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_highlight_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_highlight_annotations_with_http_info(name, opts = {}) click to toggle source

Read document highlight annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(HighlightAnnotationsResponse, Fixnum, Hash)>] HighlightAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3350
def get_document_highlight_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_highlight_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_highlight_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/highlight".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'HighlightAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_highlight_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_ink_annotations(name, opts = {}) click to toggle source

Read document ink annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [InkAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3402
def get_document_ink_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_ink_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_ink_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_ink_annotations_with_http_info(name, opts = {}) click to toggle source

Read document ink annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(InkAnnotationsResponse, Fixnum, Hash)>] InkAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3422
def get_document_ink_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_ink_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_ink_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/ink".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'InkAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_ink_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_line_annotations(name, opts = {}) click to toggle source

Read document line annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [LineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3474
def get_document_line_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_line_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_line_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_line_annotations_with_http_info(name, opts = {}) click to toggle source

Read document line annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(LineAnnotationsResponse, Fixnum, Hash)>] LineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3494
def get_document_line_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/line".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'LineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_list_box_fields(name, opts = {}) click to toggle source

Read document listbox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ListBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3546
def get_document_list_box_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_list_box_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_list_box_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_list_box_fields_with_http_info(name, opts = {}) click to toggle source

Read document listbox fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ListBoxFieldsResponse, Fixnum, Hash)>] ListBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3566
def get_document_list_box_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_list_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_list_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/listbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ListBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_list_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_movie_annotations(name, opts = {}) click to toggle source

Read document movie annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [MovieAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3618
def get_document_movie_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_movie_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_movie_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_movie_annotations_with_http_info(name, opts = {}) click to toggle source

Read document movie annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(MovieAnnotationsResponse, Fixnum, Hash)>] MovieAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3638
def get_document_movie_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_movie_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_movie_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/movie".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'MovieAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_movie_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_poly_line_annotations(name, opts = {}) click to toggle source

Read document polyline annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolyLineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3690
def get_document_poly_line_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_poly_line_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_poly_line_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_poly_line_annotations_with_http_info(name, opts = {}) click to toggle source

Read document polyline annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolyLineAnnotationsResponse, Fixnum, Hash)>] PolyLineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3710
def get_document_poly_line_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_poly_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_poly_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polyline".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolyLineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_poly_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_polygon_annotations(name, opts = {}) click to toggle source

Read document polygon annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolygonAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3762
def get_document_polygon_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_polygon_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_polygon_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_polygon_annotations_with_http_info(name, opts = {}) click to toggle source

Read document polygon annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolygonAnnotationsResponse, Fixnum, Hash)>] PolygonAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3782
def get_document_polygon_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_polygon_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_polygon_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polygon".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolygonAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_polygon_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_popup_annotations(name, opts = {}) click to toggle source

Read document popup annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PopupAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3834
def get_document_popup_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_popup_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_popup_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_popup_annotations_by_parent(name, annotation_id, opts = {}) click to toggle source

Read document popup annotations by parent id.

@param name The document name. @param annotation_id The parent annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PopupAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3907
def get_document_popup_annotations_by_parent(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_popup_annotations_by_parent_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_popup_annotations_by_parent_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_document_popup_annotations_by_parent_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document popup annotations by parent id.

@param name The document name. @param annotation_id The parent annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PopupAnnotationsResponse, Fixnum, Hash)>] PopupAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3928
def get_document_popup_annotations_by_parent_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_popup_annotations_by_parent ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_popup_annotations_by_parent"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_document_popup_annotations_by_parent"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/{annotationId}/popup".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PopupAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_popup_annotations_by_parent\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_popup_annotations_with_http_info(name, opts = {}) click to toggle source

Read document popup annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PopupAnnotationsResponse, Fixnum, Hash)>] PopupAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3854
def get_document_popup_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_popup_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_popup_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/popup".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PopupAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_popup_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_properties(name, opts = {}) click to toggle source

Read document properties.

@param name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [DocumentPropertiesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 3984
def get_document_properties(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_properties_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_properties_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_properties_with_http_info(name, opts = {}) click to toggle source

Read document properties.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4004
def get_document_properties_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_properties ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_properties"
  end
  # resource path
  local_var_path = "/pdf/{name}/documentproperties".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPropertiesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_property(name, property_name, opts = {}) click to toggle source

Read document property by name.

@param name @param property_name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [DocumentPropertyResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4057
def get_document_property(name, property_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_property_with_http_info(name, property_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_property_with_http_info(name, property_name, opts)
    else
      raise
    end
  return data
end
get_document_property_with_http_info(name, property_name, opts = {}) click to toggle source

Read document property by name.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4078
def get_document_property_with_http_info(name, property_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_property ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_property"
  end
  # verify the required parameter 'property_name' is set
  if @api_client.config.client_side_validation && property_name.nil?
    fail ArgumentError, "Missing the required parameter 'property_name' when calling PdfApi.get_document_property"
  end
  # resource path
  local_var_path = "/pdf/{name}/documentproperties/{propertyName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'propertyName' + '}', property_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPropertyResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_property\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_radio_button_fields(name, opts = {}) click to toggle source

Read document radiobutton fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RadioButtonFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4134
def get_document_radio_button_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_radio_button_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_radio_button_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_radio_button_fields_with_http_info(name, opts = {}) click to toggle source

Read document radiobutton fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RadioButtonFieldsResponse, Fixnum, Hash)>] RadioButtonFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4154
def get_document_radio_button_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_radio_button_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_radio_button_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/radiobutton".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RadioButtonFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_radio_button_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_redaction_annotations(name, opts = {}) click to toggle source

Read document redaction annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RedactionAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4206
def get_document_redaction_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_redaction_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_redaction_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_redaction_annotations_with_http_info(name, opts = {}) click to toggle source

Read document redaction annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RedactionAnnotationsResponse, Fixnum, Hash)>] RedactionAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4226
def get_document_redaction_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_redaction_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_redaction_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/redaction".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RedactionAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_redaction_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_screen_annotations(name, opts = {}) click to toggle source

Read document screen annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ScreenAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4278
def get_document_screen_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_screen_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_screen_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_screen_annotations_with_http_info(name, opts = {}) click to toggle source

Read document screen annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ScreenAnnotationsResponse, Fixnum, Hash)>] ScreenAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4298
def get_document_screen_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_screen_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_screen_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/screen".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ScreenAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_screen_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_signature_fields(name, opts = {}) click to toggle source

Read document signature fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SignatureFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4350
def get_document_signature_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_signature_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_signature_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_signature_fields_with_http_info(name, opts = {}) click to toggle source

Read document signature fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SignatureFieldsResponse, Fixnum, Hash)>] SignatureFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4370
def get_document_signature_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_signature_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_signature_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/signature".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SignatureFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_signature_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_sound_annotations(name, opts = {}) click to toggle source

Read document sound annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SoundAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4422
def get_document_sound_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_sound_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_sound_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_sound_annotations_with_http_info(name, opts = {}) click to toggle source

Read document sound annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SoundAnnotationsResponse, Fixnum, Hash)>] SoundAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4442
def get_document_sound_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_sound_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_sound_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/sound".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SoundAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_sound_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_square_annotations(name, opts = {}) click to toggle source

Read document square annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquareAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4494
def get_document_square_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_square_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_square_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_square_annotations_with_http_info(name, opts = {}) click to toggle source

Read document square annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquareAnnotationsResponse, Fixnum, Hash)>] SquareAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4514
def get_document_square_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_square_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_square_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/square".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquareAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_square_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_squiggly_annotations(name, opts = {}) click to toggle source

Read document squiggly annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquigglyAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4566
def get_document_squiggly_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_squiggly_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_squiggly_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_squiggly_annotations_with_http_info(name, opts = {}) click to toggle source

Read document squiggly annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquigglyAnnotationsResponse, Fixnum, Hash)>] SquigglyAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4586
def get_document_squiggly_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_squiggly_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_squiggly_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/squiggly".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquigglyAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_squiggly_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_stamp_annotations(name, opts = {}) click to toggle source

Read document stamp annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4638
def get_document_stamp_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_stamp_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_stamp_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_stamp_annotations_with_http_info(name, opts = {}) click to toggle source

Read document stamp annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampAnnotationsResponse, Fixnum, Hash)>] StampAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4658
def get_document_stamp_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_stamp_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_stamp_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/stamp".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StampAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_stamp_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_stamps(name, opts = {}) click to toggle source

Read document stamps.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampsInfoResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4710
def get_document_stamps(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_stamps_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_stamps_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_stamps_with_http_info(name, opts = {}) click to toggle source

Read document stamps.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampsInfoResponse, Fixnum, Hash)>] StampsInfoResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4730
def get_document_stamps_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/stamps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StampsInfoResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_strike_out_annotations(name, opts = {}) click to toggle source

Read document StrikeOut annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StrikeOutAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4782
def get_document_strike_out_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_strike_out_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_strike_out_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_strike_out_annotations_with_http_info(name, opts = {}) click to toggle source

Read document StrikeOut annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StrikeOutAnnotationsResponse, Fixnum, Hash)>] StrikeOutAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4802
def get_document_strike_out_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_strike_out_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_strike_out_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/strikeout".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StrikeOutAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_strike_out_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_tables(name, opts = {}) click to toggle source

Read document tables.

@param name @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [TablesRecognizedResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4854
def get_document_tables(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_tables_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_tables_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_tables_with_http_info(name, opts = {}) click to toggle source

Read document tables.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4874
def get_document_tables_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_tables ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_tables"
  end
  # resource path
  local_var_path = "/pdf/{name}/tables".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TablesRecognizedResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_tables\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_text_annotations(name, opts = {}) click to toggle source

Read document text annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4926
def get_document_text_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_text_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_text_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_text_annotations_with_http_info(name, opts = {}) click to toggle source

Read document text annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextAnnotationsResponse, Fixnum, Hash)>] TextAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4946
def get_document_text_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/text".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_text_box_fields(name, opts = {}) click to toggle source

Read document text box fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 4998
def get_document_text_box_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_text_box_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_text_box_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_text_box_fields_with_http_info(name, opts = {}) click to toggle source

Read document text box fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextBoxFieldsResponse, Fixnum, Hash)>] TextBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5018
def get_document_text_box_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_text_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_text_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/textbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_text_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_underline_annotations(name, opts = {}) click to toggle source

Read document underline annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [UnderlineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5070
def get_document_underline_annotations(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_document_underline_annotations_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_document_underline_annotations_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_document_underline_annotations_with_http_info(name, opts = {}) click to toggle source

Read document underline annotations.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(UnderlineAnnotationsResponse, Fixnum, Hash)>] UnderlineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5090
def get_document_underline_annotations_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document_underline_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document_underline_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/underline".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'UnderlineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document_underline_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_document_with_http_info(name, opts = {}) click to toggle source

Read common document info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(DocumentResponse, Fixnum, Hash)>] DocumentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 2480
def get_document_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_document"
  end
  # resource path
  local_var_path = "/pdf/{name}".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_download_document_attachment_by_index(name, attachment_index, opts = {}) click to toggle source

Download document attachment content by its index.

@param name The document name. @param attachment_index The attachment index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5143
def get_download_document_attachment_by_index(name, attachment_index, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_download_document_attachment_by_index_with_http_info(name, attachment_index, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_download_document_attachment_by_index_with_http_info(name, attachment_index, opts)
    else
      raise
    end
  return data
end
get_download_document_attachment_by_index_with_http_info(name, attachment_index, opts = {}) click to toggle source

Download document attachment content by its index.

@param name The document name. @param attachment_index The attachment index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5164
def get_download_document_attachment_by_index_with_http_info(name, attachment_index, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_download_document_attachment_by_index ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_download_document_attachment_by_index"
  end
  # verify the required parameter 'attachment_index' is set
  if @api_client.config.client_side_validation && attachment_index.nil?
    fail ArgumentError, "Missing the required parameter 'attachment_index' when calling PdfApi.get_download_document_attachment_by_index"
  end
  # resource path
  local_var_path = "/pdf/{name}/attachments/{attachmentIndex}/download".sub('{' + 'name' + '}', name.to_s).sub('{' + 'attachmentIndex' + '}', attachment_index.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_download_document_attachment_by_index\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_epub_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert EPUB file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.epub) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5219
def get_epub_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_epub_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_epub_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_epub_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert EPUB file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.epub) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5238
def get_epub_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_epub_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_epub_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/epub"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_epub_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_export_fields_from_pdf_to_fdf_in_storage(name, opts = {}) click to toggle source

Export fields from from PDF in storage to FDF file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5290
def get_export_fields_from_pdf_to_fdf_in_storage(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, opts = {}) click to toggle source

Export fields from from PDF in storage to FDF file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5310
def get_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_export_fields_from_pdf_to_fdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_export_fields_from_pdf_to_fdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/fdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_export_fields_from_pdf_to_fdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_export_fields_from_pdf_to_xfdf_in_storage(name, opts = {}) click to toggle source

Export fields from from PDF in storage to XFDF file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5362
def get_export_fields_from_pdf_to_xfdf_in_storage(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, opts = {}) click to toggle source

Export fields from from PDF in storage to XFDF file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5382
def get_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_export_fields_from_pdf_to_xfdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_export_fields_from_pdf_to_xfdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/xfdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_export_fields_from_pdf_to_xfdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_export_fields_from_pdf_to_xml_in_storage(name, opts = {}) click to toggle source

Export fields from from PDF in storage to XML file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5434
def get_export_fields_from_pdf_to_xml_in_storage(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, opts = {}) click to toggle source

Export fields from from PDF in storage to XML file.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5454
def get_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_export_fields_from_pdf_to_xml_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_export_fields_from_pdf_to_xml_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_export_fields_from_pdf_to_xml_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_field(name, field_name, opts = {}) click to toggle source

Get document field by name.

@param name The document name. @param field_name The field name (name should be encoded). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5507
def get_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_field_with_http_info(name, field_name, opts = {}) click to toggle source

Get document field by name.

@param name The document name. @param field_name The field name (name should be encoded). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FieldResponse, Fixnum, Hash)>] FieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5528
def get_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_fields(name, opts = {}) click to toggle source

Get document fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5584
def get_fields(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_fields_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_fields_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_fields_with_http_info(name, opts = {}) click to toggle source

Get document fields.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FieldsResponse, Fixnum, Hash)>] FieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5604
def get_fields_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_file_attachment_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page FileAttachment annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FileAttachmentAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5657
def get_file_attachment_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_file_attachment_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_file_attachment_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_file_attachment_annotation_data(name, annotation_id, opts = {}) click to toggle source

Read document page FileAttachment annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5735
def get_file_attachment_annotation_data(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_file_attachment_annotation_data_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_file_attachment_annotation_data_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_file_attachment_annotation_data_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page FileAttachment annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5756
def get_file_attachment_annotation_data_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_file_attachment_annotation_data ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_file_attachment_annotation_data"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_file_attachment_annotation_data"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/fileattachment/{annotationId}/data".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_file_attachment_annotation_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_file_attachment_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page FileAttachment annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FileAttachmentAnnotationResponse, Fixnum, Hash)>] FileAttachmentAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5678
def get_file_attachment_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_file_attachment_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_file_attachment_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_file_attachment_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/fileattachment/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FileAttachmentAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_file_attachment_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_file_versions(path, opts = {}) click to toggle source

Get file versions

@param path File path e.g. &#39;/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [FileVersions]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5811
def get_file_versions(path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_file_versions_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_file_versions_with_http_info(path, opts)
    else
      raise
    end
  return data
end
get_file_versions_with_http_info(path, opts = {}) click to toggle source

Get file versions

@param path File path e.g. &#39;/file.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [Array<(FileVersions, Fixnum, Hash)>] FileVersions data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5830
def get_file_versions_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_file_versions ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.get_file_versions"
  end
  # resource path
  local_var_path = "/pdf/storage/version/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FileVersions')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_file_versions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_files_list(path, opts = {}) click to toggle source

Get all files and folders within a folder

@param path Folder path e.g. &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [FilesList]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5880
def get_files_list(path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_files_list_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_files_list_with_http_info(path, opts)
    else
      raise
    end
  return data
end
get_files_list_with_http_info(path, opts = {}) click to toggle source

Get all files and folders within a folder

@param path Folder path e.g. &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [Array<(FilesList, Fixnum, Hash)>] FilesList data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5899
def get_files_list_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_files_list ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.get_files_list"
  end
  # resource path
  local_var_path = "/pdf/storage/folder/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FilesList')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_files_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_free_text_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page free text annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FreeTextAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5951
def get_free_text_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_free_text_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_free_text_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_free_text_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page free text annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FreeTextAnnotationResponse, Fixnum, Hash)>] FreeTextAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 5972
def get_free_text_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_free_text_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_free_text_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_free_text_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/freetext/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FreeTextAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_free_text_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_highlight_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page highlight annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [HighlightAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6029
def get_highlight_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_highlight_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_highlight_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_highlight_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page highlight annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(HighlightAnnotationResponse, Fixnum, Hash)>] HighlightAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6050
def get_highlight_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_highlight_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_highlight_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_highlight_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/highlight/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'HighlightAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_highlight_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_html_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert HTML file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.zip) @param [Hash] opts the optional parameters @option opts [String] :html_file_name Name of HTML file in ZIP. @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6113
def get_html_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_html_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_html_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_html_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert HTML file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.zip) @param [Hash] opts the optional parameters @option opts [String] :html_file_name Name of HTML file in ZIP. @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6140
def get_html_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_html_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_html_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/html"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'htmlFileName'] = opts[:'html_file_name'] if !opts[:'html_file_name'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_html_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_image(name, image_id, opts = {}) click to toggle source

Read document image by ID.

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ImageResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6201
def get_image(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_image_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_image_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
get_image_extract_as_gif(name, image_id, opts = {}) click to toggle source

Extract document image in GIF format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6281
def get_image_extract_as_gif(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_image_extract_as_gif_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_image_extract_as_gif_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
get_image_extract_as_gif_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in GIF format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6304
def get_image_extract_as_gif_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_image_extract_as_gif ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_image_extract_as_gif"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.get_image_extract_as_gif"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/gif".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_image_extract_as_gif\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_image_extract_as_jpeg(name, image_id, opts = {}) click to toggle source

Extract document image in JPEG format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6365
def get_image_extract_as_jpeg(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_image_extract_as_jpeg_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_image_extract_as_jpeg_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
get_image_extract_as_jpeg_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in JPEG format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6388
def get_image_extract_as_jpeg_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_image_extract_as_jpeg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_image_extract_as_jpeg"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.get_image_extract_as_jpeg"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/jpeg".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_image_extract_as_jpeg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_image_extract_as_png(name, image_id, opts = {}) click to toggle source

Extract document image in PNG format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6449
def get_image_extract_as_png(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_image_extract_as_png_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_image_extract_as_png_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
get_image_extract_as_png_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in PNG format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6472
def get_image_extract_as_png_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_image_extract_as_png ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_image_extract_as_png"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.get_image_extract_as_png"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/png".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_image_extract_as_png\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_image_extract_as_tiff(name, image_id, opts = {}) click to toggle source

Extract document image in TIFF format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6533
def get_image_extract_as_tiff(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_image_extract_as_tiff_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_image_extract_as_tiff_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
get_image_extract_as_tiff_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in TIFF format

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6556
def get_image_extract_as_tiff_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_image_extract_as_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_image_extract_as_tiff"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.get_image_extract_as_tiff"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/tiff".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_image_extract_as_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_image_with_http_info(name, image_id, opts = {}) click to toggle source

Read document image by ID.

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ImageResponse, Fixnum, Hash)>] ImageResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6222
def get_image_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_image ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_image"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.get_image"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ImageResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_images(name, page_number, opts = {}) click to toggle source

Read document images.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ImagesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6615
def get_images(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_images_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_images_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_images_with_http_info(name, page_number, opts = {}) click to toggle source

Read document images.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ImagesResponse, Fixnum, Hash)>] ImagesResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6636
def get_images_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_images ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_images"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_images"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ImagesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_images\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_import_fields_from_fdf_in_storage(name, fdf_file_path, opts = {}) click to toggle source

Update fields from FDF file in storage.

@param name The document name. @param fdf_file_path The Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6693
def get_import_fields_from_fdf_in_storage(name, fdf_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts)
    else
      raise
    end
  return data
end
get_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts = {}) click to toggle source

Update fields from FDF file in storage.

@param name The document name. @param fdf_file_path The Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6714
def get_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_import_fields_from_fdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_import_fields_from_fdf_in_storage"
  end
  # verify the required parameter 'fdf_file_path' is set
  if @api_client.config.client_side_validation && fdf_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'fdf_file_path' when calling PdfApi.get_import_fields_from_fdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/fdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'fdfFilePath'] = fdf_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_import_fields_from_fdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_import_fields_from_xfdf_in_storage(name, xfdf_file_path, opts = {}) click to toggle source

Update fields from XFDF file in storage.

@param name The document name. @param xfdf_file_path The XFDF file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6772
def get_import_fields_from_xfdf_in_storage(name, xfdf_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts)
    else
      raise
    end
  return data
end
get_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts = {}) click to toggle source

Update fields from XFDF file in storage.

@param name The document name. @param xfdf_file_path The XFDF file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6793
def get_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_import_fields_from_xfdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_import_fields_from_xfdf_in_storage"
  end
  # verify the required parameter 'xfdf_file_path' is set
  if @api_client.config.client_side_validation && xfdf_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xfdf_file_path' when calling PdfApi.get_import_fields_from_xfdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xfdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xfdfFilePath'] = xfdf_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_import_fields_from_xfdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_import_fields_from_xml_in_storage(name, xml_file_path, opts = {}) click to toggle source

Import from XML file (located on storage) to PDF format and return resulting file in response.

@param name The document name. @param xml_file_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6851
def get_import_fields_from_xml_in_storage(name, xml_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts)
    else
      raise
    end
  return data
end
get_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts = {}) click to toggle source

Import from XML file (located on storage) to PDF format and return resulting file in response.

@param name The document name. @param xml_file_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6872
def get_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_import_fields_from_xml_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_import_fields_from_xml_in_storage"
  end
  # verify the required parameter 'xml_file_path' is set
  if @api_client.config.client_side_validation && xml_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xml_file_path' when calling PdfApi.get_import_fields_from_xml_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xmlFilePath'] = xml_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_import_fields_from_xml_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_ink_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page ink annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [InkAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6930
def get_ink_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_ink_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_ink_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_ink_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page ink annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(InkAnnotationResponse, Fixnum, Hash)>] InkAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 6951
def get_ink_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_ink_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_ink_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_ink_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/ink/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'InkAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_ink_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_la_te_x_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7006
def get_la_te_x_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_la_te_x_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_la_te_x_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_la_te_x_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7025
def get_la_te_x_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_la_te_x_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_la_te_x_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/latex"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_la_te_x_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_line_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page line annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [LineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7078
def get_line_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_line_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_line_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_line_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page line annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(LineAnnotationResponse, Fixnum, Hash)>] LineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7099
def get_line_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_line_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_line_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_line_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/line/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'LineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_line_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_list_box_field(name, field_name, opts = {}) click to toggle source

Read document listbox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ListBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7234
def get_list_box_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_list_box_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_list_box_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_list_box_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document listbox field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ListBoxFieldResponse, Fixnum, Hash)>] ListBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7255
def get_list_box_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_list_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_list_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_list_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/listbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ListBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_list_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_markdown_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert MD file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.md) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7310
def get_markdown_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_markdown_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_markdown_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_markdown_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert MD file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.md) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7329
def get_markdown_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_markdown_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_markdown_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/markdown"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_markdown_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_mht_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert MHT file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.mht) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7380
def get_mht_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_mht_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_mht_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_mht_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert MHT file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.mht) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7399
def get_mht_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_mht_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_mht_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/mht"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_mht_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_movie_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page movie annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [MovieAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7452
def get_movie_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_movie_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_movie_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_movie_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page movie annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(MovieAnnotationResponse, Fixnum, Hash)>] MovieAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7473
def get_movie_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_movie_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_movie_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_movie_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/movie/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'MovieAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_movie_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page(name, page_number, opts = {}) click to toggle source

Read document page info.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [DocumentPageResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7530
def get_page(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_annotations(name, page_number, opts = {}) click to toggle source

Read document page annotations. Returns only FreeTextAnnotations, TextAnnotations, other annotations will implemented next releases.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AnnotationsInfoResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7608
def get_page_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page annotations. Returns only FreeTextAnnotations, TextAnnotations, other annotations will implemented next releases.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AnnotationsInfoResponse, Fixnum, Hash)>] AnnotationsInfoResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7629
def get_page_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AnnotationsInfoResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_caret_annotations(name, page_number, opts = {}) click to toggle source

Read document page caret annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CaretAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7686
def get_page_caret_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_caret_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_caret_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_caret_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page caret annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CaretAnnotationsResponse, Fixnum, Hash)>] CaretAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7707
def get_page_caret_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_caret_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_caret_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_caret_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/caret".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CaretAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_caret_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_check_box_fields(name, page_number, opts = {}) click to toggle source

Read document page checkbox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CheckBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7764
def get_page_check_box_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_check_box_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_check_box_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_check_box_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page checkbox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CheckBoxFieldsResponse, Fixnum, Hash)>] CheckBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7785
def get_page_check_box_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_check_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_check_box_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_check_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/checkbox".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CheckBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_check_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_circle_annotations(name, page_number, opts = {}) click to toggle source

Read document page circle annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CircleAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7842
def get_page_circle_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_circle_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_circle_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_circle_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page circle annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CircleAnnotationsResponse, Fixnum, Hash)>] CircleAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7863
def get_page_circle_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_circle_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_circle_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_circle_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/circle".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'CircleAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_circle_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_combo_box_fields(name, page_number, opts = {}) click to toggle source

Read document page combobox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ComboBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7920
def get_page_combo_box_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_combo_box_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_combo_box_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_combo_box_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page combobox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ComboBoxFieldsResponse, Fixnum, Hash)>] ComboBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7941
def get_page_combo_box_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_combo_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_combo_box_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_combo_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/combobox".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ComboBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_combo_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_bmp(name, page_number, opts = {}) click to toggle source

Convert document page to Bmp image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8000
def get_page_convert_to_bmp(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_bmp_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_bmp_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_bmp_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Bmp image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8023
def get_page_convert_to_bmp_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_bmp ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_bmp"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_bmp"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/bmp".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_bmp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_emf(name, page_number, opts = {}) click to toggle source

Convert document page to Emf image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8084
def get_page_convert_to_emf(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_emf_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_emf_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_emf_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Emf image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8107
def get_page_convert_to_emf_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_emf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_emf"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_emf"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/emf".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_emf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_gif(name, page_number, opts = {}) click to toggle source

Convert document page to Gif image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8168
def get_page_convert_to_gif(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_gif_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_gif_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_gif_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Gif image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8191
def get_page_convert_to_gif_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_gif ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_gif"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_gif"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/gif".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_gif\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_jpeg(name, page_number, opts = {}) click to toggle source

Convert document page to Jpeg image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8252
def get_page_convert_to_jpeg(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_jpeg_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_jpeg_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_jpeg_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Jpeg image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8275
def get_page_convert_to_jpeg_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_jpeg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_jpeg"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_jpeg"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/jpeg".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_jpeg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_png(name, page_number, opts = {}) click to toggle source

Convert document page to Png image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8336
def get_page_convert_to_png(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_png_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_png_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_png_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Png image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8359
def get_page_convert_to_png_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_png ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_png"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_png"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/png".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_png\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_convert_to_tiff(name, page_number, opts = {}) click to toggle source

Convert document page to Tiff image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8420
def get_page_convert_to_tiff(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_convert_to_tiff_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_convert_to_tiff_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_convert_to_tiff_with_http_info(name, page_number, opts = {}) click to toggle source

Convert document page to Tiff image and return resulting file in response.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8443
def get_page_convert_to_tiff_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_convert_to_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_convert_to_tiff"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_convert_to_tiff"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/tiff".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_convert_to_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_file_attachment_annotations(name, page_number, opts = {}) click to toggle source

Read document page FileAttachment annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FileAttachmentAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8502
def get_page_file_attachment_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_file_attachment_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_file_attachment_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_file_attachment_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page FileAttachment annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FileAttachmentAnnotationsResponse, Fixnum, Hash)>] FileAttachmentAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8523
def get_page_file_attachment_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_file_attachment_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_file_attachment_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_file_attachment_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/fileattachment".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FileAttachmentAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_file_attachment_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_free_text_annotations(name, page_number, opts = {}) click to toggle source

Read document page free text annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FreeTextAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8580
def get_page_free_text_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_free_text_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_free_text_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_free_text_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page free text annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FreeTextAnnotationsResponse, Fixnum, Hash)>] FreeTextAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8601
def get_page_free_text_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_free_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_free_text_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_free_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/freetext".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FreeTextAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_free_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_highlight_annotations(name, page_number, opts = {}) click to toggle source

Read document page highlight annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [HighlightAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8658
def get_page_highlight_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_highlight_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_highlight_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_highlight_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page highlight annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(HighlightAnnotationsResponse, Fixnum, Hash)>] HighlightAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8679
def get_page_highlight_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_highlight_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_highlight_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_highlight_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/highlight".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'HighlightAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_highlight_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_ink_annotations(name, page_number, opts = {}) click to toggle source

Read document page ink annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [InkAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8736
def get_page_ink_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_ink_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_ink_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_ink_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page ink annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(InkAnnotationsResponse, Fixnum, Hash)>] InkAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8757
def get_page_ink_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_ink_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_ink_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_ink_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/ink".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'InkAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_ink_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_line_annotations(name, page_number, opts = {}) click to toggle source

Read document page line annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [LineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8814
def get_page_line_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_line_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_line_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_line_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page line annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(LineAnnotationsResponse, Fixnum, Hash)>] LineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 8835
def get_page_line_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_line_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/line".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'LineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_list_box_fields(name, page_number, opts = {}) click to toggle source

Read document page listbox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ListBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9054
def get_page_list_box_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_list_box_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_list_box_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_list_box_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page listbox fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ListBoxFieldsResponse, Fixnum, Hash)>] ListBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9075
def get_page_list_box_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_list_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_list_box_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_list_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/listbox".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ListBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_list_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_movie_annotations(name, page_number, opts = {}) click to toggle source

Read document page movie annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [MovieAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9132
def get_page_movie_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_movie_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_movie_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_movie_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page movie annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(MovieAnnotationsResponse, Fixnum, Hash)>] MovieAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9153
def get_page_movie_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_movie_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_movie_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_movie_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/movie".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'MovieAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_movie_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_poly_line_annotations(name, page_number, opts = {}) click to toggle source

Read document page polyline annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolyLineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9210
def get_page_poly_line_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_poly_line_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_poly_line_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_poly_line_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page polyline annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolyLineAnnotationsResponse, Fixnum, Hash)>] PolyLineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9231
def get_page_poly_line_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_poly_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_poly_line_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_poly_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/polyline".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolyLineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_poly_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_polygon_annotations(name, page_number, opts = {}) click to toggle source

Read document page polygon annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolygonAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9288
def get_page_polygon_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_polygon_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_polygon_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_polygon_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page polygon annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolygonAnnotationsResponse, Fixnum, Hash)>] PolygonAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9309
def get_page_polygon_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_polygon_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_polygon_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_polygon_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/polygon".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolygonAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_polygon_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_popup_annotations(name, page_number, opts = {}) click to toggle source

Read document page popup annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PopupAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9366
def get_page_popup_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_popup_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_popup_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_popup_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page popup annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PopupAnnotationsResponse, Fixnum, Hash)>] PopupAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9387
def get_page_popup_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_popup_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_popup_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_popup_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/popup".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PopupAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_popup_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_radio_button_fields(name, page_number, opts = {}) click to toggle source

Read document page radiobutton fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RadioButtonFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9444
def get_page_radio_button_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_radio_button_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_radio_button_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_radio_button_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page radiobutton fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RadioButtonFieldsResponse, Fixnum, Hash)>] RadioButtonFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9465
def get_page_radio_button_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_radio_button_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_radio_button_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_radio_button_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/radiobutton".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RadioButtonFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_radio_button_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_redaction_annotations(name, page_number, opts = {}) click to toggle source

Read document page redaction annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RedactionAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9522
def get_page_redaction_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_redaction_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_redaction_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_redaction_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page redaction annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RedactionAnnotationsResponse, Fixnum, Hash)>] RedactionAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9543
def get_page_redaction_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_redaction_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_redaction_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_redaction_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/redaction".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RedactionAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_redaction_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_screen_annotations(name, page_number, opts = {}) click to toggle source

Read document page screen annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ScreenAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9600
def get_page_screen_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_screen_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_screen_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_screen_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page screen annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ScreenAnnotationsResponse, Fixnum, Hash)>] ScreenAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9621
def get_page_screen_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_screen_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_screen_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_screen_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/screen".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ScreenAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_screen_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_signature_fields(name, page_number, opts = {}) click to toggle source

Read document page signature fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SignatureFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9678
def get_page_signature_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_signature_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_signature_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_signature_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page signature fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SignatureFieldsResponse, Fixnum, Hash)>] SignatureFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9699
def get_page_signature_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_signature_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_signature_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_signature_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/signature".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SignatureFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_signature_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_sound_annotations(name, page_number, opts = {}) click to toggle source

Read document page sound annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SoundAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9756
def get_page_sound_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_sound_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_sound_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_sound_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page sound annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SoundAnnotationsResponse, Fixnum, Hash)>] SoundAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9777
def get_page_sound_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_sound_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_sound_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_sound_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/sound".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SoundAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_sound_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_square_annotations(name, page_number, opts = {}) click to toggle source

Read document page square annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquareAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9834
def get_page_square_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_square_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_square_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_square_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page square annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquareAnnotationsResponse, Fixnum, Hash)>] SquareAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9855
def get_page_square_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_square_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_square_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_square_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/square".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquareAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_square_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_squiggly_annotations(name, page_number, opts = {}) click to toggle source

Read document page squiggly annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquigglyAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9912
def get_page_squiggly_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_squiggly_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_squiggly_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_squiggly_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page squiggly annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquigglyAnnotationsResponse, Fixnum, Hash)>] SquigglyAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9933
def get_page_squiggly_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_squiggly_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_squiggly_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_squiggly_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/squiggly".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquigglyAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_squiggly_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_stamp_annotations(name, page_number, opts = {}) click to toggle source

Read document page stamp annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 9990
def get_page_stamp_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_stamp_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_stamp_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_stamp_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page stamp annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampAnnotationsResponse, Fixnum, Hash)>] StampAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10011
def get_page_stamp_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_stamp_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_stamp_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_stamp_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/stamp".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StampAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_stamp_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_stamps(name, page_number, opts = {}) click to toggle source

Read page document stamps.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampsInfoResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10068
def get_page_stamps(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_stamps_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_stamps_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_stamps_with_http_info(name, page_number, opts = {}) click to toggle source

Read page document stamps.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampsInfoResponse, Fixnum, Hash)>] StampsInfoResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10089
def get_page_stamps_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_stamps"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamps".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StampsInfoResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_strike_out_annotations(name, page_number, opts = {}) click to toggle source

Read document page StrikeOut annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StrikeOutAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10146
def get_page_strike_out_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_strike_out_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_strike_out_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_strike_out_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page StrikeOut annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StrikeOutAnnotationsResponse, Fixnum, Hash)>] StrikeOutAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10167
def get_page_strike_out_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_strike_out_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_strike_out_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_strike_out_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/strikeout".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StrikeOutAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_strike_out_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_tables(name, page_number, opts = {}) click to toggle source

Read document page tables.

@param name @param page_number @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [TablesRecognizedResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10224
def get_page_tables(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_tables_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_tables_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_tables_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page tables.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10245
def get_page_tables_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_tables ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_tables"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_tables"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/tables".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TablesRecognizedResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_tables\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_text(name, page_number, llx, lly, urx, ury, opts = {}) click to toggle source

Read page text items.

@param name The document name. @param page_number Number of page (starting from 1). @param llx X-coordinate of lower - left corner. @param lly Y - coordinate of lower-left corner. @param urx X - coordinate of upper-right corner. @param ury Y - coordinate of upper-right corner. @param [Hash] opts the optional parameters @option opts [Array<String>] :format List of formats for search. @option opts [String] :regex Formats are specified as a regular expression. @option opts [BOOLEAN] :split_rects Split result fragments (default is true). (default to true) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [TextRectsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10309
def get_page_text(name, page_number, llx, lly, urx, ury, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_text_with_http_info(name, page_number, llx, lly, urx, ury, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_text_with_http_info(name, page_number, llx, lly, urx, ury, opts)
    else
      raise
    end
  return data
end
get_page_text_annotations(name, page_number, opts = {}) click to toggle source

Read document page text annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10417
def get_page_text_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_text_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_text_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_text_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page text annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextAnnotationsResponse, Fixnum, Hash)>] TextAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10438
def get_page_text_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_text_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/text".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_text_box_fields(name, page_number, opts = {}) click to toggle source

Read document page text box fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextBoxFieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10495
def get_page_text_box_fields(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_text_box_fields_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_text_box_fields_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_text_box_fields_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page text box fields.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextBoxFieldsResponse, Fixnum, Hash)>] TextBoxFieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10516
def get_page_text_box_fields_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_text_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_text_box_fields"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_text_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/page/{pageNumber}/fields/textbox".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextBoxFieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_text_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_text_with_http_info(name, page_number, llx, lly, urx, ury, opts = {}) click to toggle source

Read page text items.

@param name The document name. @param page_number Number of page (starting from 1). @param llx X-coordinate of lower - left corner. @param lly Y - coordinate of lower-left corner. @param urx X - coordinate of upper-right corner. @param ury Y - coordinate of upper-right corner. @param [Hash] opts the optional parameters @option opts [Array<String>] :format List of formats for search. @option opts [String] :regex Formats are specified as a regular expression. @option opts [BOOLEAN] :split_rects Split result fragments (default is true). @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(TextRectsResponse, Fixnum, Hash)>] TextRectsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10337
def get_page_text_with_http_info(name, page_number, llx, lly, urx, ury, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_text ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_text"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_text"
  end
  # verify the required parameter 'llx' is set
  if @api_client.config.client_side_validation && llx.nil?
    fail ArgumentError, "Missing the required parameter 'llx' when calling PdfApi.get_page_text"
  end
  # verify the required parameter 'lly' is set
  if @api_client.config.client_side_validation && lly.nil?
    fail ArgumentError, "Missing the required parameter 'lly' when calling PdfApi.get_page_text"
  end
  # verify the required parameter 'urx' is set
  if @api_client.config.client_side_validation && urx.nil?
    fail ArgumentError, "Missing the required parameter 'urx' when calling PdfApi.get_page_text"
  end
  # verify the required parameter 'ury' is set
  if @api_client.config.client_side_validation && ury.nil?
    fail ArgumentError, "Missing the required parameter 'ury' when calling PdfApi.get_page_text"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/text".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'LLX'] = llx
  query_params[:'LLY'] = lly
  query_params[:'URX'] = urx
  query_params[:'URY'] = ury
  query_params[:'format'] = @api_client.build_collection_param(opts[:'format'], :csv) if !opts[:'format'].nil?
  query_params[:'regex'] = opts[:'regex'] if !opts[:'regex'].nil?
  query_params[:'splitRects'] = opts[:'split_rects'] if !opts[:'split_rects'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextRectsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_underline_annotations(name, page_number, opts = {}) click to toggle source

Read document page underline annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [UnderlineAnnotationsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10573
def get_page_underline_annotations(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_page_underline_annotations_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_page_underline_annotations_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
get_page_underline_annotations_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page underline annotations.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(UnderlineAnnotationsResponse, Fixnum, Hash)>] UnderlineAnnotationsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10594
def get_page_underline_annotations_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page_underline_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page_underline_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page_underline_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/underline".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'UnderlineAnnotationsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page_underline_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_page_with_http_info(name, page_number, opts = {}) click to toggle source

Read document page info.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(DocumentPageResponse, Fixnum, Hash)>] DocumentPageResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 7551
def get_page_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_page"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.get_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPageResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pages(name, opts = {}) click to toggle source

Read document pages info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [DocumentPagesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10650
def get_pages(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pages_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pages_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pages_with_http_info(name, opts = {}) click to toggle source

Read document pages info.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(DocumentPagesResponse, Fixnum, Hash)>] DocumentPagesResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10670
def get_pages_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pages ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pages"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPagesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pages\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pcl_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert PCL file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.pcl) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10721
def get_pcl_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pcl_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pcl_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_pcl_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert PCL file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.pcl) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10740
def get_pcl_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pcl_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_pcl_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/pcl"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pcl_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_a_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert PDFA file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.pdf) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :dont_optimize If set, document resources will not be optimized. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10792
def get_pdf_a_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_a_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_a_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_pdf_a_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert PDFA file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.pdf) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :dont_optimize If set, document resources will not be optimized. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10812
def get_pdf_a_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_a_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_pdf_a_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/pdfa"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dontOptimize'] = opts[:'dont_optimize'] if !opts[:'dont_optimize'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_a_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_doc(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to DOC format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10873
def get_pdf_in_storage_to_doc(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_doc_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_doc_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_doc_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to DOC format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10901
def get_pdf_in_storage_to_doc_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_doc ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_doc"
  end
  if @api_client.config.client_side_validation && opts[:'format'] && !['Doc', 'DocX'].include?(opts[:'format'])
    fail ArgumentError, 'invalid value for "format", must be one of Doc, DocX'
  end
  if @api_client.config.client_side_validation && opts[:'mode'] && !['Textbox', 'Flow'].include?(opts[:'mode'])
    fail ArgumentError, 'invalid value for "mode", must be one of Textbox, Flow'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/doc".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'addReturnToLineEnd'] = opts[:'add_return_to_line_end'] if !opts[:'add_return_to_line_end'].nil?
  query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
  query_params[:'imageResolutionX'] = opts[:'image_resolution_x'] if !opts[:'image_resolution_x'].nil?
  query_params[:'imageResolutionY'] = opts[:'image_resolution_y'] if !opts[:'image_resolution_y'].nil?
  query_params[:'maxDistanceBetweenTextLines'] = opts[:'max_distance_between_text_lines'] if !opts[:'max_distance_between_text_lines'].nil?
  query_params[:'mode'] = opts[:'mode'] if !opts[:'mode'].nil?
  query_params[:'recognizeBullets'] = opts[:'recognize_bullets'] if !opts[:'recognize_bullets'].nil?
  query_params[:'relativeHorizontalProximity'] = opts[:'relative_horizontal_proximity'] if !opts[:'relative_horizontal_proximity'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_doc\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_epub(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to EPUB format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10968
def get_pdf_in_storage_to_epub(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_epub_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_epub_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_epub_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to EPUB format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 10989
def get_pdf_in_storage_to_epub_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_epub ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_epub"
  end
  if @api_client.config.client_side_validation && opts[:'content_recognition_mode'] && !['Flow', 'PdfFlow', 'Fixed'].include?(opts[:'content_recognition_mode'])
    fail ArgumentError, 'invalid value for "content_recognition_mode", must be one of Flow, PdfFlow, Fixed'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/epub".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'contentRecognitionMode'] = opts[:'content_recognition_mode'] if !opts[:'content_recognition_mode'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_epub\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_html(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to Html format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11074
def get_pdf_in_storage_to_html(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_html_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_html_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_html_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to Html format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11123
def get_pdf_in_storage_to_html_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_html ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_html"
  end
  if @api_client.config.client_side_validation && opts[:'document_type'] && !['Xhtml', 'Html5'].include?(opts[:'document_type'])
    fail ArgumentError, 'invalid value for "document_type", must be one of Xhtml, Html5'
  end
  if @api_client.config.client_side_validation && opts[:'antialiasing_processing'] && !['NoAdditionalProcessing', 'TryCorrectResultHtml'].include?(opts[:'antialiasing_processing'])
    fail ArgumentError, 'invalid value for "antialiasing_processing", must be one of NoAdditionalProcessing, TryCorrectResultHtml'
  end
  if @api_client.config.client_side_validation && opts[:'font_encoding_strategy'] && !['Default', 'DecreaseToUnicodePriorityLevel'].include?(opts[:'font_encoding_strategy'])
    fail ArgumentError, 'invalid value for "font_encoding_strategy", must be one of Default, DecreaseToUnicodePriorityLevel'
  end
  if @api_client.config.client_side_validation && opts[:'font_saving_mode'] && !['AlwaysSaveAsWOFF', 'AlwaysSaveAsTTF', 'AlwaysSaveAsEOT', 'SaveInAllFormats'].include?(opts[:'font_saving_mode'])
    fail ArgumentError, 'invalid value for "font_saving_mode", must be one of AlwaysSaveAsWOFF, AlwaysSaveAsTTF, AlwaysSaveAsEOT, SaveInAllFormats'
  end
  if @api_client.config.client_side_validation && opts[:'html_markup_generation_mode'] && !['WriteAllHtml', 'WriteOnlyBodyContent'].include?(opts[:'html_markup_generation_mode'])
    fail ArgumentError, 'invalid value for "html_markup_generation_mode", must be one of WriteAllHtml, WriteOnlyBodyContent'
  end
  if @api_client.config.client_side_validation && opts[:'letters_positioning_method'] && !['UseEmUnitsAndCompensationOfRoundingErrorsInCss', 'UsePixelUnitsInCssLetterSpacingForIE'].include?(opts[:'letters_positioning_method'])
    fail ArgumentError, 'invalid value for "letters_positioning_method", must be one of UseEmUnitsAndCompensationOfRoundingErrorsInCss, UsePixelUnitsInCssLetterSpacingForIE'
  end
  if @api_client.config.client_side_validation && opts[:'parts_embedding_mode'] && !['EmbedAllIntoHtml', 'EmbedCssOnly', 'NoEmbedding'].include?(opts[:'parts_embedding_mode'])
    fail ArgumentError, 'invalid value for "parts_embedding_mode", must be one of EmbedAllIntoHtml, EmbedCssOnly, NoEmbedding'
  end
  if @api_client.config.client_side_validation && opts[:'raster_images_saving_mode'] && !['AsPngImagesEmbeddedIntoSvg', 'AsExternalPngFilesReferencedViaSvg', 'AsEmbeddedPartsOfPngPageBackground'].include?(opts[:'raster_images_saving_mode'])
    fail ArgumentError, 'invalid value for "raster_images_saving_mode", must be one of AsPngImagesEmbeddedIntoSvg, AsExternalPngFilesReferencedViaSvg, AsEmbeddedPartsOfPngPageBackground'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/html".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'additionalMarginWidthInPoints'] = opts[:'additional_margin_width_in_points'] if !opts[:'additional_margin_width_in_points'].nil?
  query_params[:'compressSvgGraphicsIfAny'] = opts[:'compress_svg_graphics_if_any'] if !opts[:'compress_svg_graphics_if_any'].nil?
  query_params[:'convertMarkedContentToLayers'] = opts[:'convert_marked_content_to_layers'] if !opts[:'convert_marked_content_to_layers'].nil?
  query_params[:'defaultFontName'] = opts[:'default_font_name'] if !opts[:'default_font_name'].nil?
  query_params[:'documentType'] = opts[:'document_type'] if !opts[:'document_type'].nil?
  query_params[:'fixedLayout'] = opts[:'fixed_layout'] if !opts[:'fixed_layout'].nil?
  query_params[:'imageResolution'] = opts[:'image_resolution'] if !opts[:'image_resolution'].nil?
  query_params[:'minimalLineWidth'] = opts[:'minimal_line_width'] if !opts[:'minimal_line_width'].nil?
  query_params[:'preventGlyphsGrouping'] = opts[:'prevent_glyphs_grouping'] if !opts[:'prevent_glyphs_grouping'].nil?
  query_params[:'splitCssIntoPages'] = opts[:'split_css_into_pages'] if !opts[:'split_css_into_pages'].nil?
  query_params[:'splitIntoPages'] = opts[:'split_into_pages'] if !opts[:'split_into_pages'].nil?
  query_params[:'useZOrder'] = opts[:'use_z_order'] if !opts[:'use_z_order'].nil?
  query_params[:'antialiasingProcessing'] = opts[:'antialiasing_processing'] if !opts[:'antialiasing_processing'].nil?
  query_params[:'cssClassNamesPrefix'] = opts[:'css_class_names_prefix'] if !opts[:'css_class_names_prefix'].nil?
  query_params[:'explicitListOfSavedPages'] = @api_client.build_collection_param(opts[:'explicit_list_of_saved_pages'], :csv) if !opts[:'explicit_list_of_saved_pages'].nil?
  query_params[:'fontEncodingStrategy'] = opts[:'font_encoding_strategy'] if !opts[:'font_encoding_strategy'].nil?
  query_params[:'fontSavingMode'] = opts[:'font_saving_mode'] if !opts[:'font_saving_mode'].nil?
  query_params[:'htmlMarkupGenerationMode'] = opts[:'html_markup_generation_mode'] if !opts[:'html_markup_generation_mode'].nil?
  query_params[:'lettersPositioningMethod'] = opts[:'letters_positioning_method'] if !opts[:'letters_positioning_method'].nil?
  query_params[:'pagesFlowTypeDependsOnViewersScreenSize'] = opts[:'pages_flow_type_depends_on_viewers_screen_size'] if !opts[:'pages_flow_type_depends_on_viewers_screen_size'].nil?
  query_params[:'partsEmbeddingMode'] = opts[:'parts_embedding_mode'] if !opts[:'parts_embedding_mode'].nil?
  query_params[:'rasterImagesSavingMode'] = opts[:'raster_images_saving_mode'] if !opts[:'raster_images_saving_mode'].nil?
  query_params[:'removeEmptyAreasOnTopAndBottom'] = opts[:'remove_empty_areas_on_top_and_bottom'] if !opts[:'remove_empty_areas_on_top_and_bottom'].nil?
  query_params[:'saveShadowedTextsAsTransparentTexts'] = opts[:'save_shadowed_texts_as_transparent_texts'] if !opts[:'save_shadowed_texts_as_transparent_texts'].nil?
  query_params[:'saveTransparentTexts'] = opts[:'save_transparent_texts'] if !opts[:'save_transparent_texts'].nil?
  query_params[:'specialFolderForAllImages'] = opts[:'special_folder_for_all_images'] if !opts[:'special_folder_for_all_images'].nil?
  query_params[:'specialFolderForSvgImages'] = opts[:'special_folder_for_svg_images'] if !opts[:'special_folder_for_svg_images'].nil?
  query_params[:'trySaveTextUnderliningAndStrikeoutingInCss'] = opts[:'try_save_text_underlining_and_strikeouting_in_css'] if !opts[:'try_save_text_underlining_and_strikeouting_in_css'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'flowLayoutParagraphFullWidth'] = opts[:'flow_layout_paragraph_full_width'] if !opts[:'flow_layout_paragraph_full_width'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_html\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_mobi_xml(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to MOBIXML format and returns resulting ZIP archive file in response content.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11228
def get_pdf_in_storage_to_mobi_xml(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_mobi_xml_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_mobi_xml_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_mobi_xml_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to MOBIXML format and returns resulting ZIP archive file in response content.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11248
def get_pdf_in_storage_to_mobi_xml_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_mobi_xml ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_mobi_xml"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/mobixml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_mobi_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_pdf_a(name, type, opts = {}) click to toggle source

Converts PDF document (located on storage) to PdfA format and returns resulting file in response content

@param name The document name. @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11301
def get_pdf_in_storage_to_pdf_a(name, type, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_pdf_a_with_http_info(name, type, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_pdf_a_with_http_info(name, type, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_pdf_a_with_http_info(name, type, opts = {}) click to toggle source

Converts PDF document (located on storage) to PdfA format and returns resulting file in response content

@param name The document name. @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11322
def get_pdf_in_storage_to_pdf_a_with_http_info(name, type, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_pdf_a ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_pdf_a"
  end
  # verify the required parameter 'type' is set
  if @api_client.config.client_side_validation && type.nil?
    fail ArgumentError, "Missing the required parameter 'type' when calling PdfApi.get_pdf_in_storage_to_pdf_a"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['PDFA1A', 'PDFA1B', 'PDFA3A'].include?(type)
    fail ArgumentError, "invalid value for 'type', must be one of PDFA1A, PDFA1B, PDFA3A"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/pdfa".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'type'] = type
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_pdf_a\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_pptx(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to PPTX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11385
def get_pdf_in_storage_to_pptx(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_pptx_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_pptx_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_pptx_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to PPTX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11407
def get_pdf_in_storage_to_pptx_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_pptx ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_pptx"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/pptx".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'separateImages'] = opts[:'separate_images'] if !opts[:'separate_images'].nil?
  query_params[:'slidesAsImages'] = opts[:'slides_as_images'] if !opts[:'slides_as_images'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_pptx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_svg(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to SVG format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :compress_output_to_zip_archive Specifies whether output will be created as one zip-archive. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11462
def get_pdf_in_storage_to_svg(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_svg_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_svg_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_svg_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to SVG format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :compress_output_to_zip_archive Specifies whether output will be created as one zip-archive. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11483
def get_pdf_in_storage_to_svg_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_svg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_svg"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/svg".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'compressOutputToZipArchive'] = opts[:'compress_output_to_zip_archive'] if !opts[:'compress_output_to_zip_archive'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_svg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_te_x(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to TeX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11536
def get_pdf_in_storage_to_te_x(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_te_x_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_te_x_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_te_x_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to TeX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11556
def get_pdf_in_storage_to_te_x_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_te_x ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_te_x"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/tex".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_te_x\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_tiff(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to TIFF format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11623
def get_pdf_in_storage_to_tiff(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_tiff_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_tiff_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_tiff_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to TIFF format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11658
def get_pdf_in_storage_to_tiff_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_tiff"
  end
  if @api_client.config.client_side_validation && opts[:'compression'] && !['LZW', 'CCITT4', 'CCITT3', 'RLE', 'None'].include?(opts[:'compression'])
    fail ArgumentError, 'invalid value for "compression", must be one of LZW, CCITT4, CCITT3, RLE, None'
  end
  if @api_client.config.client_side_validation && opts[:'color_depth'] && !['Default', 'Format8bpp', 'Format4bpp', 'Format1bpp'].include?(opts[:'color_depth'])
    fail ArgumentError, 'invalid value for "color_depth", must be one of Default, Format8bpp, Format4bpp, Format1bpp'
  end
  if @api_client.config.client_side_validation && opts[:'orientation'] && !['None', 'Landscape', 'Portrait'].include?(opts[:'orientation'])
    fail ArgumentError, 'invalid value for "orientation", must be one of None, Landscape, Portrait'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/tiff".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'brightness'] = opts[:'brightness'] if !opts[:'brightness'].nil?
  query_params[:'compression'] = opts[:'compression'] if !opts[:'compression'].nil?
  query_params[:'colorDepth'] = opts[:'color_depth'] if !opts[:'color_depth'].nil?
  query_params[:'leftMargin'] = opts[:'left_margin'] if !opts[:'left_margin'].nil?
  query_params[:'rightMargin'] = opts[:'right_margin'] if !opts[:'right_margin'].nil?
  query_params[:'topMargin'] = opts[:'top_margin'] if !opts[:'top_margin'].nil?
  query_params[:'bottomMargin'] = opts[:'bottom_margin'] if !opts[:'bottom_margin'].nil?
  query_params[:'orientation'] = opts[:'orientation'] if !opts[:'orientation'].nil?
  query_params[:'skipBlankPages'] = opts[:'skip_blank_pages'] if !opts[:'skip_blank_pages'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'xResolution'] = opts[:'x_resolution'] if !opts[:'x_resolution'].nil?
  query_params[:'yResolution'] = opts[:'y_resolution'] if !opts[:'y_resolution'].nil?
  query_params[:'pageIndex'] = opts[:'page_index'] if !opts[:'page_index'].nil?
  query_params[:'pageCount'] = opts[:'page_count'] if !opts[:'page_count'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_xls(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLS format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11738
def get_pdf_in_storage_to_xls(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_xls_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_xls_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_xls_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLS format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11762
def get_pdf_in_storage_to_xls_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_xls ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_xls"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xls".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_xls\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_xlsx(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLSX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11822
def get_pdf_in_storage_to_xlsx(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_xlsx_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_xlsx_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_xlsx_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLSX format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11846
def get_pdf_in_storage_to_xlsx_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_xlsx ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_xlsx"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xlsx".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_xlsx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_xml(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XML format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11902
def get_pdf_in_storage_to_xml(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_xml_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_xml_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_xml_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XML format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11922
def get_pdf_in_storage_to_xml_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_xml ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_xml"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_pdf_in_storage_to_xps(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XPS format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11974
def get_pdf_in_storage_to_xps(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_pdf_in_storage_to_xps_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_pdf_in_storage_to_xps_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_pdf_in_storage_to_xps_with_http_info(name, opts = {}) click to toggle source

Converts PDF document (located on storage) to XPS format and returns resulting file in response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 11994
def get_pdf_in_storage_to_xps_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_pdf_in_storage_to_xps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_pdf_in_storage_to_xps"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_pdf_in_storage_to_xps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_poly_line_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page polyline annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolyLineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12047
def get_poly_line_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_poly_line_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_poly_line_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_poly_line_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page polyline annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolyLineAnnotationResponse, Fixnum, Hash)>] PolyLineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12068
def get_poly_line_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_poly_line_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_poly_line_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_poly_line_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polyline/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolyLineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_poly_line_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_polygon_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page polygon annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolygonAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12125
def get_polygon_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_polygon_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_polygon_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_polygon_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page polygon annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolygonAnnotationResponse, Fixnum, Hash)>] PolygonAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12146
def get_polygon_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_polygon_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_polygon_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_polygon_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polygon/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PolygonAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_polygon_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_popup_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page popup annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PopupAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12203
def get_popup_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_popup_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_popup_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_popup_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page popup annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PopupAnnotationResponse, Fixnum, Hash)>] PopupAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12224
def get_popup_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_popup_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_popup_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_popup_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/popup/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'PopupAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_popup_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_ps_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert PS file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.ps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12279
def get_ps_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_ps_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_ps_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_ps_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert PS file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.ps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12298
def get_ps_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_ps_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_ps_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/ps"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_ps_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_radio_button_field(name, field_name, opts = {}) click to toggle source

Read document RadioButton field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RadioButtonFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12351
def get_radio_button_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_radio_button_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_radio_button_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_radio_button_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document RadioButton field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RadioButtonFieldResponse, Fixnum, Hash)>] RadioButtonFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12372
def get_radio_button_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_radio_button_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_radio_button_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_radio_button_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/radiobutton/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RadioButtonFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_radio_button_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_redaction_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page redaction annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RedactionAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12429
def get_redaction_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_redaction_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_redaction_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_redaction_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page redaction annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RedactionAnnotationResponse, Fixnum, Hash)>] RedactionAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12450
def get_redaction_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_redaction_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_redaction_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_redaction_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/redaction/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'RedactionAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_redaction_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_screen_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page screen annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ScreenAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12507
def get_screen_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_screen_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_screen_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_screen_annotation_data(name, annotation_id, opts = {}) click to toggle source

Read document page screen annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12585
def get_screen_annotation_data(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_screen_annotation_data_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_screen_annotation_data_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_screen_annotation_data_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page screen annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12606
def get_screen_annotation_data_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_screen_annotation_data ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_screen_annotation_data"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_screen_annotation_data"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/screen/{annotationId}/data".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_screen_annotation_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_screen_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page screen annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ScreenAnnotationResponse, Fixnum, Hash)>] ScreenAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12528
def get_screen_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_screen_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_screen_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_screen_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/screen/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ScreenAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_screen_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_signature_field(name, field_name, opts = {}) click to toggle source

Read document signature field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SignatureFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12663
def get_signature_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_signature_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_signature_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_signature_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document signature field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SignatureFieldResponse, Fixnum, Hash)>] SignatureFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12684
def get_signature_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_signature_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_signature_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_signature_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/signature/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SignatureFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_signature_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_sound_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page sound annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SoundAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12741
def get_sound_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_sound_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_sound_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_sound_annotation_data(name, annotation_id, opts = {}) click to toggle source

Read document page sound annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12819
def get_sound_annotation_data(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_sound_annotation_data_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_sound_annotation_data_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_sound_annotation_data_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page sound annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12840
def get_sound_annotation_data_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_sound_annotation_data ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_sound_annotation_data"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_sound_annotation_data"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/sound/{annotationId}/data".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_sound_annotation_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_sound_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page sound annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SoundAnnotationResponse, Fixnum, Hash)>] SoundAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12762
def get_sound_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_sound_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_sound_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_sound_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/sound/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SoundAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_sound_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_square_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page square annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquareAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12897
def get_square_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_square_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_square_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_square_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page square annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquareAnnotationResponse, Fixnum, Hash)>] SquareAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12918
def get_square_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_square_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_square_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_square_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/square/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquareAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_square_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_squiggly_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page squiggly annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquigglyAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12975
def get_squiggly_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_squiggly_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_squiggly_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_squiggly_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page squiggly annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquigglyAnnotationResponse, Fixnum, Hash)>] SquigglyAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 12996
def get_squiggly_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_squiggly_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_squiggly_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_squiggly_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/squiggly/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SquigglyAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_squiggly_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_stamp_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page stamp annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13053
def get_stamp_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_stamp_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_stamp_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_stamp_annotation_data(name, annotation_id, opts = {}) click to toggle source

Read document page stamp annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13131
def get_stamp_annotation_data(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_stamp_annotation_data_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_stamp_annotation_data_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_stamp_annotation_data_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page stamp annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13152
def get_stamp_annotation_data_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_stamp_annotation_data ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_stamp_annotation_data"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_stamp_annotation_data"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/stamp/{annotationId}/data".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_stamp_annotation_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_stamp_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page stamp annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampAnnotationResponse, Fixnum, Hash)>] StampAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13074
def get_stamp_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_stamp_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_stamp_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_stamp_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/stamp/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StampAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_stamp_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_strike_out_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page StrikeOut annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StrikeOutAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13209
def get_strike_out_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_strike_out_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_strike_out_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_strike_out_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page StrikeOut annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StrikeOutAnnotationResponse, Fixnum, Hash)>] StrikeOutAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13230
def get_strike_out_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_strike_out_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_strike_out_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_strike_out_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/strikeout/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StrikeOutAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_strike_out_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_svg_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert SVG file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.svg) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :adjust_page_size Adjust page size @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13293
def get_svg_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_svg_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_svg_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_svg_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert SVG file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.svg) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :adjust_page_size Adjust page size @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13320
def get_svg_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_svg_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_svg_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/svg"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'adjustPageSize'] = opts[:'adjust_page_size'] if !opts[:'adjust_page_size'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_svg_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_table(name, table_id, opts = {}) click to toggle source

Read document page table by ID.

@param name The document name. @param table_id The table ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TableRecognizedResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13381
def get_table(name, table_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_table_with_http_info(name, table_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_table_with_http_info(name, table_id, opts)
    else
      raise
    end
  return data
end
get_table_with_http_info(name, table_id, opts = {}) click to toggle source

Read document page table by ID.

@param name The document name. @param table_id The table ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TableRecognizedResponse, Fixnum, Hash)>] TableRecognizedResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13402
def get_table_with_http_info(name, table_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_table ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_table"
  end
  # verify the required parameter 'table_id' is set
  if @api_client.config.client_side_validation && table_id.nil?
    fail ArgumentError, "Missing the required parameter 'table_id' when calling PdfApi.get_table"
  end
  # resource path
  local_var_path = "/pdf/{name}/tables/{tableId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'tableId' + '}', table_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TableRecognizedResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_table\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_te_x_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13457
def get_te_x_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_te_x_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_te_x_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_te_x_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13476
def get_te_x_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_te_x_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_te_x_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/tex"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_te_x_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_text(name, llx, lly, urx, ury, opts = {}) click to toggle source

Read document text.

@param name The document name. @param llx X-coordinate of lower - left corner. @param lly Y - coordinate of lower-left corner. @param urx X - coordinate of upper-right corner. @param ury Y - coordinate of upper-right corner. @param [Hash] opts the optional parameters @option opts [Array<String>] :format List of formats for search. @option opts [String] :regex Formats are specified as a regular expression. @option opts [BOOLEAN] :split_rects Split result fragments (default is true). (default to true) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [TextRectsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13535
def get_text(name, llx, lly, urx, ury, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_text_with_http_info(name, llx, lly, urx, ury, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_text_with_http_info(name, llx, lly, urx, ury, opts)
    else
      raise
    end
  return data
end
get_text_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page text annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13638
def get_text_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_text_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_text_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_text_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page text annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextAnnotationResponse, Fixnum, Hash)>] TextAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13659
def get_text_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_text_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_text_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_text_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/text/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_text_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_text_box_field(name, field_name, opts = {}) click to toggle source

Read document text box field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13716
def get_text_box_field(name, field_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_text_box_field_with_http_info(name, field_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_text_box_field_with_http_info(name, field_name, opts)
    else
      raise
    end
  return data
end
get_text_box_field_with_http_info(name, field_name, opts = {}) click to toggle source

Read document text box field by name.

@param name The document name. @param field_name The field name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextBoxFieldResponse, Fixnum, Hash)>] TextBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13737
def get_text_box_field_with_http_info(name, field_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_text_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_text_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.get_text_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/textbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_text_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_text_with_http_info(name, llx, lly, urx, ury, opts = {}) click to toggle source

Read document text.

@param name The document name. @param llx X-coordinate of lower - left corner. @param lly Y - coordinate of lower-left corner. @param urx X - coordinate of upper-right corner. @param ury Y - coordinate of upper-right corner. @param [Hash] opts the optional parameters @option opts [Array<String>] :format List of formats for search. @option opts [String] :regex Formats are specified as a regular expression. @option opts [BOOLEAN] :split_rects Split result fragments (default is true). @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(TextRectsResponse, Fixnum, Hash)>] TextRectsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13562
def get_text_with_http_info(name, llx, lly, urx, ury, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_text ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_text"
  end
  # verify the required parameter 'llx' is set
  if @api_client.config.client_side_validation && llx.nil?
    fail ArgumentError, "Missing the required parameter 'llx' when calling PdfApi.get_text"
  end
  # verify the required parameter 'lly' is set
  if @api_client.config.client_side_validation && lly.nil?
    fail ArgumentError, "Missing the required parameter 'lly' when calling PdfApi.get_text"
  end
  # verify the required parameter 'urx' is set
  if @api_client.config.client_side_validation && urx.nil?
    fail ArgumentError, "Missing the required parameter 'urx' when calling PdfApi.get_text"
  end
  # verify the required parameter 'ury' is set
  if @api_client.config.client_side_validation && ury.nil?
    fail ArgumentError, "Missing the required parameter 'ury' when calling PdfApi.get_text"
  end
  # resource path
  local_var_path = "/pdf/{name}/text".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'LLX'] = llx
  query_params[:'LLY'] = lly
  query_params[:'URX'] = urx
  query_params[:'URY'] = ury
  query_params[:'format'] = @api_client.build_collection_param(opts[:'format'], :csv) if !opts[:'format'].nil?
  query_params[:'regex'] = opts[:'regex'] if !opts[:'regex'].nil?
  query_params[:'splitRects'] = opts[:'split_rects'] if !opts[:'split_rects'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'TextRectsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_underline_annotation(name, annotation_id, opts = {}) click to toggle source

Read document page underline annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [UnderlineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13794
def get_underline_annotation(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_underline_annotation_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_underline_annotation_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
get_underline_annotation_with_http_info(name, annotation_id, opts = {}) click to toggle source

Read document page underline annotation by ID.

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(UnderlineAnnotationResponse, Fixnum, Hash)>] UnderlineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13815
def get_underline_annotation_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_underline_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_underline_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.get_underline_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/underline/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'UnderlineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_underline_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_verify_signature(name, sign_name, opts = {}) click to toggle source

Verify signature document.

@param name The document name. @param sign_name Sign name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SignatureVerifyResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13872
def get_verify_signature(name, sign_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_verify_signature_with_http_info(name, sign_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_verify_signature_with_http_info(name, sign_name, opts)
    else
      raise
    end
  return data
end
get_verify_signature_with_http_info(name, sign_name, opts = {}) click to toggle source

Verify signature document.

@param name The document name. @param sign_name Sign name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SignatureVerifyResponse, Fixnum, Hash)>] SignatureVerifyResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13893
def get_verify_signature_with_http_info(name, sign_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_verify_signature ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_verify_signature"
  end
  # verify the required parameter 'sign_name' is set
  if @api_client.config.client_side_validation && sign_name.nil?
    fail ArgumentError, "Missing the required parameter 'sign_name' when calling PdfApi.get_verify_signature"
  end
  # resource path
  local_var_path = "/pdf/{name}/verifySignature".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'signName'] = sign_name
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SignatureVerifyResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_verify_signature\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_web_in_storage_to_pdf(url, opts = {}) click to toggle source

Convert web page to PDF format and return resulting file in response.

@param url Source url @param [Hash] opts the optional parameters @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13956
def get_web_in_storage_to_pdf(url, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_web_in_storage_to_pdf_with_http_info(url, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_web_in_storage_to_pdf_with_http_info(url, opts)
    else
      raise
    end
  return data
end
get_web_in_storage_to_pdf_with_http_info(url, opts = {}) click to toggle source

Convert web page to PDF format and return resulting file in response.

@param url Source url @param [Hash] opts the optional parameters @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 13982
def get_web_in_storage_to_pdf_with_http_info(url, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_web_in_storage_to_pdf ..."
  end
  # verify the required parameter 'url' is set
  if @api_client.config.client_side_validation && url.nil?
    fail ArgumentError, "Missing the required parameter 'url' when calling PdfApi.get_web_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/web"

  # query parameters
  query_params = {}
  query_params[:'url'] = url
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_web_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_words_per_page(name, opts = {}) click to toggle source

Get number of words per document page.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [WordCountResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14041
def get_words_per_page(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_words_per_page_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_words_per_page_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_words_per_page_with_http_info(name, opts = {}) click to toggle source

Get number of words per document page.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(WordCountResponse, Fixnum, Hash)>] WordCountResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14061
def get_words_per_page_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_words_per_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_words_per_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/wordCount".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'WordCountResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_words_per_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_xfa_pdf_in_storage_to_acro_form(name, opts = {}) click to toggle source

Converts PDF document which contains XFA form (located on storage) to PDF with AcroForm and returns resulting file response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14113
def get_xfa_pdf_in_storage_to_acro_form(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_xfa_pdf_in_storage_to_acro_form_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_xfa_pdf_in_storage_to_acro_form_with_http_info(name, opts)
    else
      raise
    end
  return data
end
get_xfa_pdf_in_storage_to_acro_form_with_http_info(name, opts = {}) click to toggle source

Converts PDF document which contains XFA form (located on storage) to PDF with AcroForm and returns resulting file response content

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14133
def get_xfa_pdf_in_storage_to_acro_form_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_xfa_pdf_in_storage_to_acro_form ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.get_xfa_pdf_in_storage_to_acro_form"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xfatoacroform".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_xfa_pdf_in_storage_to_acro_form\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_xml_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert XML file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :xsl_file_path Full XSL source filename (ex. /folder1/folder2/template.xsl) @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14185
def get_xml_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_xml_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_xml_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_xml_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert XML file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :xsl_file_path Full XSL source filename (ex. /folder1/folder2/template.xsl) @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14205
def get_xml_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_xml_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_xml_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/xml"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'xslFilePath'] = opts[:'xsl_file_path'] if !opts[:'xsl_file_path'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_xml_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_xps_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert XPS file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14257
def get_xps_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_xps_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_xps_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_xps_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert XPS file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14276
def get_xps_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_xps_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_xps_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/xps"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_xps_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
get_xsl_fo_in_storage_to_pdf(src_path, opts = {}) click to toggle source

Convert XslFo file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xslfo) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [File]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14327
def get_xsl_fo_in_storage_to_pdf(src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = get_xsl_fo_in_storage_to_pdf_with_http_info(src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = get_xsl_fo_in_storage_to_pdf_with_http_info(src_path, opts)
    else
      raise
    end
  return data
end
get_xsl_fo_in_storage_to_pdf_with_http_info(src_path, opts = {}) click to toggle source

Convert XslFo file (located on storage) to PDF format and return resulting file in response.

@param src_path Full source filename (ex. /folder1/folder2/template.xslfo) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14346
def get_xsl_fo_in_storage_to_pdf_with_http_info(src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.get_xsl_fo_in_storage_to_pdf ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.get_xsl_fo_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/create/xslfo"

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?

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

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#get_xsl_fo_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
move_file(src_path, dest_path, opts = {}) click to toggle source

Move file

@param src_path Source file path e.g. &#39;/src.ext&#39; @param dest_path Destination file path e.g. &#39;/dest.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @option opts [String] :version_id File version ID to move @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14400
def move_file(src_path, dest_path, opts = {})
  @api_client.request_token_if_needed
  move_file_with_http_info(src_path, dest_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      move_file_with_http_info(src_path, dest_path, opts)
    else
      raise
    end
  return nil
end
move_file_with_http_info(src_path, dest_path, opts = {}) click to toggle source

Move file

@param src_path Source file path e.g. &#39;/src.ext&#39; @param dest_path Destination file path e.g. &#39;/dest.ext&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @option opts [String] :version_id File version ID to move @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14422
def move_file_with_http_info(src_path, dest_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.move_file ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.move_file"
  end
  # verify the required parameter 'dest_path' is set
  if @api_client.config.client_side_validation && dest_path.nil?
    fail ArgumentError, "Missing the required parameter 'dest_path' when calling PdfApi.move_file"
  end
  # resource path
  local_var_path = "/pdf/storage/file/move/{srcPath}".sub('{' + 'srcPath' + '}', src_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'destPath'] = dest_path
  query_params[:'srcStorageName'] = opts[:'src_storage_name'] if !opts[:'src_storage_name'].nil?
  query_params[:'destStorageName'] = opts[:'dest_storage_name'] if !opts[:'dest_storage_name'].nil?
  query_params[:'versionId'] = opts[:'version_id'] if !opts[:'version_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#move_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
move_folder(src_path, dest_path, opts = {}) click to toggle source

Move folder

@param src_path Folder path to move e.g. &#39;/folder&#39; @param dest_path Destination folder path to move to e.g &#39;/dst&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @return [nil]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14480
def move_folder(src_path, dest_path, opts = {})
  @api_client.request_token_if_needed
  move_folder_with_http_info(src_path, dest_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      move_folder_with_http_info(src_path, dest_path, opts)
    else
      raise
    end
  return nil
end
move_folder_with_http_info(src_path, dest_path, opts = {}) click to toggle source

Move folder

@param src_path Folder path to move e.g. &#39;/folder&#39; @param dest_path Destination folder path to move to e.g &#39;/dst&#39; @param [Hash] opts the optional parameters @option opts [String] :src_storage_name Source storage name @option opts [String] :dest_storage_name Destination storage name @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14501
def move_folder_with_http_info(src_path, dest_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.move_folder ..."
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.move_folder"
  end
  # verify the required parameter 'dest_path' is set
  if @api_client.config.client_side_validation && dest_path.nil?
    fail ArgumentError, "Missing the required parameter 'dest_path' when calling PdfApi.move_folder"
  end
  # resource path
  local_var_path = "/pdf/storage/folder/move/{srcPath}".sub('{' + 'srcPath' + '}', src_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'destPath'] = dest_path
  query_params[:'srcStorageName'] = opts[:'src_storage_name'] if !opts[:'src_storage_name'].nil?
  query_params[:'destStorageName'] = opts[:'dest_storage_name'] if !opts[:'dest_storage_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#move_folder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
object_exists(path, opts = {}) click to toggle source

Check if file or folder exists

@param path File or folder path e.g. &#39;/file.ext&#39; or &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID @return [ObjectExist]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14557
def object_exists(path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = object_exists_with_http_info(path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = object_exists_with_http_info(path, opts)
    else
      raise
    end
  return data
end
object_exists_with_http_info(path, opts = {}) click to toggle source

Check if file or folder exists

@param path File or folder path e.g. &#39;/file.ext&#39; or &#39;/folder&#39; @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @option opts [String] :version_id File version ID @return [Array<(ObjectExist, Fixnum, Hash)>] ObjectExist data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14577
def object_exists_with_http_info(path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.object_exists ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.object_exists"
  end
  # resource path
  local_var_path = "/pdf/storage/exist/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_name'].nil?
  query_params[:'versionId'] = opts[:'version_id'] if !opts[:'version_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ObjectExist')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#object_exists\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_append_document(name, append_file, opts = {}) click to toggle source

Append document to existing one.

@param name The original document name. @param append_file Append file server path. @param [Hash] opts the optional parameters @option opts [Integer] :start_page Appending start page. (default to 0) @option opts [Integer] :end_page Appending end page. (default to 0) @option opts [String] :storage The documents storage. @option opts [String] :folder The original document folder. @return [DocumentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14632
def post_append_document(name, append_file, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_append_document_with_http_info(name, append_file, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_append_document_with_http_info(name, append_file, opts)
    else
      raise
    end
  return data
end
post_append_document_with_http_info(name, append_file, opts = {}) click to toggle source

Append document to existing one.

@param name The original document name. @param append_file Append file server path. @param [Hash] opts the optional parameters @option opts [Integer] :start_page Appending start page. @option opts [Integer] :end_page Appending end page. @option opts [String] :storage The documents storage. @option opts [String] :folder The original document folder. @return [Array<(DocumentResponse, Fixnum, Hash)>] DocumentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14655
def post_append_document_with_http_info(name, append_file, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_append_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_append_document"
  end
  # verify the required parameter 'append_file' is set
  if @api_client.config.client_side_validation && append_file.nil?
    fail ArgumentError, "Missing the required parameter 'append_file' when calling PdfApi.post_append_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/appendDocument".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'appendFile'] = append_file
  query_params[:'startPage'] = opts[:'start_page'] if !opts[:'start_page'].nil?
  query_params[:'endPage'] = opts[:'end_page'] if !opts[:'end_page'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_append_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_bookmark(name, bookmark_path, bookmarks, opts = {}) click to toggle source

Add document bookmarks.

@param name The document name. @param bookmark_path The parent bookmark path. Specify an empty string when adding a bookmark to the root. @param bookmarks The array of bookmark. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [BookmarksResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14716
def post_bookmark(name, bookmark_path, bookmarks, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_bookmark_with_http_info(name, bookmark_path, bookmarks, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_bookmark_with_http_info(name, bookmark_path, bookmarks, opts)
    else
      raise
    end
  return data
end
post_bookmark_with_http_info(name, bookmark_path, bookmarks, opts = {}) click to toggle source

Add document bookmarks.

@param name The document name. @param bookmark_path The parent bookmark path. Specify an empty string when adding a bookmark to the root. @param bookmarks The array of bookmark. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(BookmarksResponse, Fixnum, Hash)>] BookmarksResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14738
def post_bookmark_with_http_info(name, bookmark_path, bookmarks, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_bookmark ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_bookmark"
  end
  # verify the required parameter 'bookmark_path' is set
  if @api_client.config.client_side_validation && bookmark_path.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark_path' when calling PdfApi.post_bookmark"
  end
  # verify the required parameter 'bookmarks' is set
  if @api_client.config.client_side_validation && bookmarks.nil?
    fail ArgumentError, "Missing the required parameter 'bookmarks' when calling PdfApi.post_bookmark"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/bookmark/{bookmarkPath}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'bookmarkPath' + '}', bookmark_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(bookmarks)
  auth_names = ['JWT']
  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 => 'BookmarksResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_bookmark\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_change_password_document_in_storage(name, owner_password, new_user_password, new_owner_password, opts = {}) click to toggle source

Change document password in storage.

@param name Document name. @param owner_password Owner password (encrypted Base64). @param new_user_password New user password (encrypted Base64). @param new_owner_password New owner password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14800
def post_change_password_document_in_storage(name, owner_password, new_user_password, new_owner_password, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_change_password_document_in_storage_with_http_info(name, owner_password, new_user_password, new_owner_password, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_change_password_document_in_storage_with_http_info(name, owner_password, new_user_password, new_owner_password, opts)
    else
      raise
    end
  return data
end
post_change_password_document_in_storage_with_http_info(name, owner_password, new_user_password, new_owner_password, opts = {}) click to toggle source

Change document password in storage.

@param name Document name. @param owner_password Owner password (encrypted Base64). @param new_user_password New user password (encrypted Base64). @param new_owner_password New owner password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14823
def post_change_password_document_in_storage_with_http_info(name, owner_password, new_user_password, new_owner_password, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_change_password_document_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_change_password_document_in_storage"
  end
  # verify the required parameter 'owner_password' is set
  if @api_client.config.client_side_validation && owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'owner_password' when calling PdfApi.post_change_password_document_in_storage"
  end
  # verify the required parameter 'new_user_password' is set
  if @api_client.config.client_side_validation && new_user_password.nil?
    fail ArgumentError, "Missing the required parameter 'new_user_password' when calling PdfApi.post_change_password_document_in_storage"
  end
  # verify the required parameter 'new_owner_password' is set
  if @api_client.config.client_side_validation && new_owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'new_owner_password' when calling PdfApi.post_change_password_document_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/changepassword".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'ownerPassword'] = owner_password
  query_params[:'newUserPassword'] = new_user_password
  query_params[:'newOwnerPassword'] = new_owner_password
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_change_password_document_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_check_box_fields(name, fields, opts = {}) click to toggle source

Add document checkbox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14891
def post_check_box_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_check_box_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_check_box_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
post_check_box_fields_with_http_info(name, fields, opts = {}) click to toggle source

Add document checkbox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14912
def post_check_box_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_check_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_check_box_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.post_check_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/checkbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_check_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_combo_box_fields(name, fields, opts = {}) click to toggle source

Add document combobox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14968
def post_combo_box_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_combo_box_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_combo_box_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
post_combo_box_fields_with_http_info(name, fields, opts = {}) click to toggle source

Add document combobox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 14989
def post_combo_box_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_combo_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_combo_box_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.post_combo_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/combobox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_combo_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_create_document(name, document_config, opts = {}) click to toggle source

Create empty document.

@param name The new document name. @param document_config The document config for new document. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The new document folder. @return [DocumentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15045
def post_create_document(name, document_config, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_create_document_with_http_info(name, document_config, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_create_document_with_http_info(name, document_config, opts)
    else
      raise
    end
  return data
end
post_create_document_with_http_info(name, document_config, opts = {}) click to toggle source

Create empty document.

@param name The new document name. @param document_config The document config for new document. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The new document folder. @return [Array<(DocumentResponse, Fixnum, Hash)>] DocumentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15066
def post_create_document_with_http_info(name, document_config, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_create_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_create_document"
  end
  # verify the required parameter 'document_config' is set
  if @api_client.config.client_side_validation && document_config.nil?
    fail ArgumentError, "Missing the required parameter 'document_config' when calling PdfApi.post_create_document"
  end
  # resource path
  local_var_path = "/pdf/{name}".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(document_config)
  auth_names = ['JWT']
  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 => 'DocumentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_create_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_create_field(name, page, field, opts = {}) click to toggle source

Create field.

@param name The document name. @param page Document page number. @param field Field with the field data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15123
def post_create_field(name, page, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_create_field_with_http_info(name, page, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_create_field_with_http_info(name, page, field, opts)
    else
      raise
    end
  return data
end
post_create_field_with_http_info(name, page, field, opts = {}) click to toggle source

Create field.

@param name The document name. @param page Document page number. @param field Field with the field data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15145
def post_create_field_with_http_info(name, page, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_create_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_create_field"
  end
  # verify the required parameter 'page' is set
  if @api_client.config.client_side_validation && page.nil?
    fail ArgumentError, "Missing the required parameter 'page' when calling PdfApi.post_create_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.post_create_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'page'] = page
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_create_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_decrypt_document_in_storage(name, password, opts = {}) click to toggle source

Decrypt document in storage.

@param name Document name. @param password The password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15206
def post_decrypt_document_in_storage(name, password, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_decrypt_document_in_storage_with_http_info(name, password, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_decrypt_document_in_storage_with_http_info(name, password, opts)
    else
      raise
    end
  return data
end
post_decrypt_document_in_storage_with_http_info(name, password, opts = {}) click to toggle source

Decrypt document in storage.

@param name Document name. @param password The password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15227
def post_decrypt_document_in_storage_with_http_info(name, password, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_decrypt_document_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_decrypt_document_in_storage"
  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 PdfApi.post_decrypt_document_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/decrypt".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'password'] = password
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_decrypt_document_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_image_footer(name, image_footer, opts = {}) click to toggle source

Add document image footer.

@param name The document name. @param image_footer The image footer. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15287
def post_document_image_footer(name, image_footer, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_image_footer_with_http_info(name, image_footer, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_image_footer_with_http_info(name, image_footer, opts)
    else
      raise
    end
  return data
end
post_document_image_footer_with_http_info(name, image_footer, opts = {}) click to toggle source

Add document image footer.

@param name The document name. @param image_footer The image footer. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15310
def post_document_image_footer_with_http_info(name, image_footer, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_image_footer ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_image_footer"
  end
  # verify the required parameter 'image_footer' is set
  if @api_client.config.client_side_validation && image_footer.nil?
    fail ArgumentError, "Missing the required parameter 'image_footer' when calling PdfApi.post_document_image_footer"
  end
  # resource path
  local_var_path = "/pdf/{name}/footer/image".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPageNumber'] = opts[:'start_page_number'] if !opts[:'start_page_number'].nil?
  query_params[:'endPageNumber'] = opts[:'end_page_number'] if !opts[:'end_page_number'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(image_footer)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_image_footer\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_image_header(name, image_header, opts = {}) click to toggle source

Add document image header.

@param name The document name. @param image_header The image header. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15370
def post_document_image_header(name, image_header, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_image_header_with_http_info(name, image_header, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_image_header_with_http_info(name, image_header, opts)
    else
      raise
    end
  return data
end
post_document_image_header_with_http_info(name, image_header, opts = {}) click to toggle source

Add document image header.

@param name The document name. @param image_header The image header. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15393
def post_document_image_header_with_http_info(name, image_header, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_image_header ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_image_header"
  end
  # verify the required parameter 'image_header' is set
  if @api_client.config.client_side_validation && image_header.nil?
    fail ArgumentError, "Missing the required parameter 'image_header' when calling PdfApi.post_document_image_header"
  end
  # resource path
  local_var_path = "/pdf/{name}/header/image".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPageNumber'] = opts[:'start_page_number'] if !opts[:'start_page_number'].nil?
  query_params[:'endPageNumber'] = opts[:'end_page_number'] if !opts[:'end_page_number'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(image_header)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_image_header\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_page_number_stamps(name, stamp, opts = {}) click to toggle source

Add document page number stamps.

@param name The document name. @param stamp The stamp. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15453
def post_document_page_number_stamps(name, stamp, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_page_number_stamps_with_http_info(name, stamp, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_page_number_stamps_with_http_info(name, stamp, opts)
    else
      raise
    end
  return data
end
post_document_page_number_stamps_with_http_info(name, stamp, opts = {}) click to toggle source

Add document page number stamps.

@param name The document name. @param stamp The stamp. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15476
def post_document_page_number_stamps_with_http_info(name, stamp, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_page_number_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_page_number_stamps"
  end
  # verify the required parameter 'stamp' is set
  if @api_client.config.client_side_validation && stamp.nil?
    fail ArgumentError, "Missing the required parameter 'stamp' when calling PdfApi.post_document_page_number_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/stamps/pagenumber".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPageNumber'] = opts[:'start_page_number'] if !opts[:'start_page_number'].nil?
  query_params[:'endPageNumber'] = opts[:'end_page_number'] if !opts[:'end_page_number'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(stamp)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_page_number_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_text_footer(name, text_footer, opts = {}) click to toggle source

Add document text footer.

@param name The document name. @param text_footer The text footer. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15536
def post_document_text_footer(name, text_footer, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_text_footer_with_http_info(name, text_footer, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_text_footer_with_http_info(name, text_footer, opts)
    else
      raise
    end
  return data
end
post_document_text_footer_with_http_info(name, text_footer, opts = {}) click to toggle source

Add document text footer.

@param name The document name. @param text_footer The text footer. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15559
def post_document_text_footer_with_http_info(name, text_footer, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_text_footer ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_text_footer"
  end
  # verify the required parameter 'text_footer' is set
  if @api_client.config.client_side_validation && text_footer.nil?
    fail ArgumentError, "Missing the required parameter 'text_footer' when calling PdfApi.post_document_text_footer"
  end
  # resource path
  local_var_path = "/pdf/{name}/footer/text".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPageNumber'] = opts[:'start_page_number'] if !opts[:'start_page_number'].nil?
  query_params[:'endPageNumber'] = opts[:'end_page_number'] if !opts[:'end_page_number'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(text_footer)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_text_footer\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_text_header(name, text_header, opts = {}) click to toggle source

Add document text header.

@param name The document name. @param text_header The text header. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15619
def post_document_text_header(name, text_header, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_text_header_with_http_info(name, text_header, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_text_header_with_http_info(name, text_header, opts)
    else
      raise
    end
  return data
end
post_document_text_header_with_http_info(name, text_header, opts = {}) click to toggle source

Add document text header.

@param name The document name. @param text_header The text header. @param [Hash] opts the optional parameters @option opts [Integer] :start_page_number The start page number. @option opts [Integer] :end_page_number The end page number. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15642
def post_document_text_header_with_http_info(name, text_header, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_text_header ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_text_header"
  end
  # verify the required parameter 'text_header' is set
  if @api_client.config.client_side_validation && text_header.nil?
    fail ArgumentError, "Missing the required parameter 'text_header' when calling PdfApi.post_document_text_header"
  end
  # resource path
  local_var_path = "/pdf/{name}/header/text".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPageNumber'] = opts[:'start_page_number'] if !opts[:'start_page_number'].nil?
  query_params[:'endPageNumber'] = opts[:'end_page_number'] if !opts[:'end_page_number'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(text_header)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_text_header\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_document_text_replace(name, text_replace, opts = {}) click to toggle source

Document's replace text method.

@param name @param text_replace @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [TextReplaceResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15700
def post_document_text_replace(name, text_replace, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_document_text_replace_with_http_info(name, text_replace, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_document_text_replace_with_http_info(name, text_replace, opts)
    else
      raise
    end
  return data
end
post_document_text_replace_with_http_info(name, text_replace, opts = {}) click to toggle source

Document&#39;s replace text method.

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

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15721
def post_document_text_replace_with_http_info(name, text_replace, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_document_text_replace ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_document_text_replace"
  end
  # verify the required parameter 'text_replace' is set
  if @api_client.config.client_side_validation && text_replace.nil?
    fail ArgumentError, "Missing the required parameter 'text_replace' when calling PdfApi.post_document_text_replace"
  end
  # resource path
  local_var_path = "/pdf/{name}/text/replace".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(text_replace)
  auth_names = ['JWT']
  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 => 'TextReplaceResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_document_text_replace\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_encrypt_document_in_storage(name, user_password, owner_password, crypto_algorithm, opts = {}) click to toggle source

Encrypt document in storage.

@param name Document name. @param user_password User password (encrypted Base64). @param owner_password Owner password (encrypted Base64). @param crypto_algorithm Cryptographic algorithm, see CryptoAlgorithm for details. @param [Hash] opts the optional parameters @option opts [Array<PermissionsFlags>] :permissions_flags Array of document permissions, see PermissionsFlags for details. @option opts [BOOLEAN] :use_pdf20 Support for revision 6 (Extension 8). @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15781
def post_encrypt_document_in_storage(name, user_password, owner_password, crypto_algorithm, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_encrypt_document_in_storage_with_http_info(name, user_password, owner_password, crypto_algorithm, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_encrypt_document_in_storage_with_http_info(name, user_password, owner_password, crypto_algorithm, opts)
    else
      raise
    end
  return data
end
post_encrypt_document_in_storage_with_http_info(name, user_password, owner_password, crypto_algorithm, opts = {}) click to toggle source

Encrypt document in storage.

@param name Document name. @param user_password User password (encrypted Base64). @param owner_password Owner password (encrypted Base64). @param crypto_algorithm Cryptographic algorithm, see CryptoAlgorithm for details. @param [Hash] opts the optional parameters @option opts [Array<PermissionsFlags>] :permissions_flags Array of document permissions, see PermissionsFlags for details. @option opts [BOOLEAN] :use_pdf20 Support for revision 6 (Extension 8). @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15806
def post_encrypt_document_in_storage_with_http_info(name, user_password, owner_password, crypto_algorithm, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_encrypt_document_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_encrypt_document_in_storage"
  end
  # verify the required parameter 'user_password' is set
  if @api_client.config.client_side_validation && user_password.nil?
    fail ArgumentError, "Missing the required parameter 'user_password' when calling PdfApi.post_encrypt_document_in_storage"
  end
  # verify the required parameter 'owner_password' is set
  if @api_client.config.client_side_validation && owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'owner_password' when calling PdfApi.post_encrypt_document_in_storage"
  end
  # verify the required parameter 'crypto_algorithm' is set
  if @api_client.config.client_side_validation && crypto_algorithm.nil?
    fail ArgumentError, "Missing the required parameter 'crypto_algorithm' when calling PdfApi.post_encrypt_document_in_storage"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['RC4x40', 'RC4x128', 'AESx128', 'AESx256'].include?(crypto_algorithm)
    fail ArgumentError, "invalid value for 'crypto_algorithm', must be one of RC4x40, RC4x128, AESx128, AESx256"
  end
  # resource path
  local_var_path = "/pdf/{name}/encrypt".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'userPassword'] = user_password
  query_params[:'ownerPassword'] = owner_password
  query_params[:'cryptoAlgorithm'] = crypto_algorithm
  query_params[:'permissionsFlags'] = @api_client.build_collection_param(opts[:'permissions_flags'], :csv) if !opts[:'permissions_flags'].nil?
  query_params[:'usePdf20'] = opts[:'use_pdf20'] if !opts[:'use_pdf20'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_encrypt_document_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_flatten_document(name, opts = {}) click to toggle source

Flatten the document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :update_appearances If set, all field appearances will be regenerated before flattening. This option may help if field is incorrectly flattened. This option may decrease performance.. @option opts [BOOLEAN] :call_events If set, formatting and other JavaScript events will be called. @option opts [BOOLEAN] :hide_buttons If set, buttons will be removed from flattened document. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15882
def post_flatten_document(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_flatten_document_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_flatten_document_with_http_info(name, opts)
    else
      raise
    end
  return data
end
post_flatten_document_with_http_info(name, opts = {}) click to toggle source

Flatten the document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :update_appearances If set, all field appearances will be regenerated before flattening. This option may help if field is incorrectly flattened. This option may decrease performance.. @option opts [BOOLEAN] :call_events If set, formatting and other JavaScript events will be called. @option opts [BOOLEAN] :hide_buttons If set, buttons will be removed from flattened document. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15905
def post_flatten_document_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_flatten_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_flatten_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/flatten".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'updateAppearances'] = opts[:'update_appearances'] if !opts[:'update_appearances'].nil?
  query_params[:'callEvents'] = opts[:'call_events'] if !opts[:'call_events'].nil?
  query_params[:'hideButtons'] = opts[:'hide_buttons'] if !opts[:'hide_buttons'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_flatten_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_import_fields_from_fdf(name, opts = {}) click to toggle source

Update fields from FDF file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :fdf_data Fdf file. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15961
def post_import_fields_from_fdf(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_import_fields_from_fdf_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_import_fields_from_fdf_with_http_info(name, opts)
    else
      raise
    end
  return data
end
post_import_fields_from_fdf_with_http_info(name, opts = {}) click to toggle source

Update fields from FDF file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :fdf_data Fdf file. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 15982
def post_import_fields_from_fdf_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_import_fields_from_fdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_import_fields_from_fdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/fdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'fdf_data'] if !opts[:'fdf_data'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_import_fields_from_fdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_import_fields_from_xfdf(name, opts = {}) click to toggle source

Update fields from XFDF file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :xfdf_data Xfdf file. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16037
def post_import_fields_from_xfdf(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_import_fields_from_xfdf_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_import_fields_from_xfdf_with_http_info(name, opts)
    else
      raise
    end
  return data
end
post_import_fields_from_xfdf_with_http_info(name, opts = {}) click to toggle source

Update fields from XFDF file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :xfdf_data Xfdf file. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16058
def post_import_fields_from_xfdf_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_import_fields_from_xfdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_import_fields_from_xfdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xfdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'xfdf_data'] if !opts[:'xfdf_data'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_import_fields_from_xfdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_import_fields_from_xml(name, opts = {}) click to toggle source

Update fields from XML file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :xml_data Xml file. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16113
def post_import_fields_from_xml(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_import_fields_from_xml_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_import_fields_from_xml_with_http_info(name, opts)
    else
      raise
    end
  return data
end
post_import_fields_from_xml_with_http_info(name, opts = {}) click to toggle source

Update fields from XML file in request.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :xml_data Xml file. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16134
def post_import_fields_from_xml_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_import_fields_from_xml ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_import_fields_from_xml"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'xml_data'] if !opts[:'xml_data'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_import_fields_from_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_insert_image(name, page_number, llx, lly, urx, ury, opts = {}) click to toggle source

Insert image to document page.

@param name The document name. @param page_number The page number. @param llx Coordinate lower left X. @param lly Coordinate lower left Y. @param urx Coordinate upper right X. @param ury Coordinate upper right Y. @param [Hash] opts the optional parameters @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :image Image file. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16195
def post_insert_image(name, page_number, llx, lly, urx, ury, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_insert_image_with_http_info(name, page_number, llx, lly, urx, ury, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_insert_image_with_http_info(name, page_number, llx, lly, urx, ury, opts)
    else
      raise
    end
  return data
end
post_insert_image_with_http_info(name, page_number, llx, lly, urx, ury, opts = {}) click to toggle source

Insert image to document page.

@param name The document name. @param page_number The page number. @param llx Coordinate lower left X. @param lly Coordinate lower left Y. @param urx Coordinate upper right X. @param ury Coordinate upper right Y. @param [Hash] opts the optional parameters @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :image Image file. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16222
def post_insert_image_with_http_info(name, page_number, llx, lly, urx, ury, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_insert_image ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_insert_image"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_insert_image"
  end
  # verify the required parameter 'llx' is set
  if @api_client.config.client_side_validation && llx.nil?
    fail ArgumentError, "Missing the required parameter 'llx' when calling PdfApi.post_insert_image"
  end
  # verify the required parameter 'lly' is set
  if @api_client.config.client_side_validation && lly.nil?
    fail ArgumentError, "Missing the required parameter 'lly' when calling PdfApi.post_insert_image"
  end
  # verify the required parameter 'urx' is set
  if @api_client.config.client_side_validation && urx.nil?
    fail ArgumentError, "Missing the required parameter 'urx' when calling PdfApi.post_insert_image"
  end
  # verify the required parameter 'ury' is set
  if @api_client.config.client_side_validation && ury.nil?
    fail ArgumentError, "Missing the required parameter 'ury' when calling PdfApi.post_insert_image"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'llx'] = llx
  query_params[:'lly'] = lly
  query_params[:'urx'] = urx
  query_params[:'ury'] = ury
  query_params[:'imageFilePath'] = opts[:'image_file_path'] if !opts[:'image_file_path'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'image'] if !opts[:'image'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_insert_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_list_box_fields(name, fields, opts = {}) click to toggle source

Add document listbox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16302
def post_list_box_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_list_box_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_list_box_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
post_list_box_fields_with_http_info(name, fields, opts = {}) click to toggle source

Add document listbox fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16323
def post_list_box_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_list_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_list_box_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.post_list_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/listbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_list_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_move_page(name, page_number, new_index, opts = {}) click to toggle source

Move page to new position.

@param name The document name. @param page_number The page number. @param new_index The new page position/index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16380
def post_move_page(name, page_number, new_index, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_move_page_with_http_info(name, page_number, new_index, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_move_page_with_http_info(name, page_number, new_index, opts)
    else
      raise
    end
  return data
end
post_move_page_with_http_info(name, page_number, new_index, opts = {}) click to toggle source

Move page to new position.

@param name The document name. @param page_number The page number. @param new_index The new page position/index. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16402
def post_move_page_with_http_info(name, page_number, new_index, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_move_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_move_page"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_move_page"
  end
  # verify the required parameter 'new_index' is set
  if @api_client.config.client_side_validation && new_index.nil?
    fail ArgumentError, "Missing the required parameter 'new_index' when calling PdfApi.post_move_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/movePage".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'newIndex'] = new_index
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_move_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_optimize_document(name, options, opts = {}) click to toggle source

Optimize document.

@param name The document name. @param options The optimization options. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16464
def post_optimize_document(name, options, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_optimize_document_with_http_info(name, options, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_optimize_document_with_http_info(name, options, opts)
    else
      raise
    end
  return data
end
post_optimize_document_with_http_info(name, options, opts = {}) click to toggle source

Optimize document.

@param name The document name. @param options The optimization options. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16485
def post_optimize_document_with_http_info(name, options, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_optimize_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_optimize_document"
  end
  # verify the required parameter 'options' is set
  if @api_client.config.client_side_validation && options.nil?
    fail ArgumentError, "Missing the required parameter 'options' when calling PdfApi.post_optimize_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/optimize".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(options)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_optimize_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_caret_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page caret annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16542
def post_page_caret_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_caret_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_caret_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_caret_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page caret annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16564
def post_page_caret_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_caret_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_caret_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_caret_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_caret_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/caret".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_caret_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_certify(name, page_number, sign, doc_mdp_access_permission_type, opts = {}) click to toggle source

Certify document page.

@param name The document name. @param page_number The page number. @param sign Signature object containing signature data. @param doc_mdp_access_permission_type The access permissions granted for this document. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16626
def post_page_certify(name, page_number, sign, doc_mdp_access_permission_type, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_certify_with_http_info(name, page_number, sign, doc_mdp_access_permission_type, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_certify_with_http_info(name, page_number, sign, doc_mdp_access_permission_type, opts)
    else
      raise
    end
  return data
end
post_page_certify_with_http_info(name, page_number, sign, doc_mdp_access_permission_type, opts = {}) click to toggle source

Certify document page.

@param name The document name. @param page_number The page number. @param sign Signature object containing signature data. @param doc_mdp_access_permission_type The access permissions granted for this document. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16649
def post_page_certify_with_http_info(name, page_number, sign, doc_mdp_access_permission_type, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_certify ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_certify"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_certify"
  end
  # verify the required parameter 'sign' is set
  if @api_client.config.client_side_validation && sign.nil?
    fail ArgumentError, "Missing the required parameter 'sign' when calling PdfApi.post_page_certify"
  end
  # verify the required parameter 'doc_mdp_access_permission_type' is set
  if @api_client.config.client_side_validation && doc_mdp_access_permission_type.nil?
    fail ArgumentError, "Missing the required parameter 'doc_mdp_access_permission_type' when calling PdfApi.post_page_certify"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['NoChanges', 'FillingInForms', 'AnnotationModification'].include?(doc_mdp_access_permission_type)
    fail ArgumentError, "invalid value for 'doc_mdp_access_permission_type', must be one of NoChanges, FillingInForms, AnnotationModification"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/certify".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'docMdpAccessPermissionType'] = doc_mdp_access_permission_type
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(sign)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_certify\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_circle_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page circle annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16719
def post_page_circle_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_circle_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_circle_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_circle_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page circle annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16741
def post_page_circle_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_circle_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_circle_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_circle_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_circle_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/circle".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_circle_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_file_attachment_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page FileAttachment annotations.

@param name The document name. @param page_number The page number. @param annotations Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16802
def post_page_file_attachment_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_file_attachment_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_file_attachment_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_file_attachment_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page FileAttachment annotations.

@param name The document name. @param page_number The page number. @param annotations Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16824
def post_page_file_attachment_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_file_attachment_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_file_attachment_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_file_attachment_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_file_attachment_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/fileattachment".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_file_attachment_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_free_text_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page free text annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16885
def post_page_free_text_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_free_text_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_free_text_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_free_text_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page free text annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16907
def post_page_free_text_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_free_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_free_text_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_free_text_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_free_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/freetext".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_free_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_highlight_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page highlight annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16968
def post_page_highlight_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_highlight_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_highlight_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_highlight_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page highlight annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 16990
def post_page_highlight_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_highlight_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_highlight_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_highlight_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_highlight_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/highlight".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_highlight_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_image_stamps(name, page_number, stamps, opts = {}) click to toggle source

Add document page image stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17051
def post_page_image_stamps(name, page_number, stamps, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_image_stamps_with_http_info(name, page_number, stamps, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_image_stamps_with_http_info(name, page_number, stamps, opts)
    else
      raise
    end
  return data
end
post_page_image_stamps_with_http_info(name, page_number, stamps, opts = {}) click to toggle source

Add document page image stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17073
def post_page_image_stamps_with_http_info(name, page_number, stamps, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_image_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_image_stamps"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_image_stamps"
  end
  # verify the required parameter 'stamps' is set
  if @api_client.config.client_side_validation && stamps.nil?
    fail ArgumentError, "Missing the required parameter 'stamps' when calling PdfApi.post_page_image_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamps/image".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(stamps)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_image_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_ink_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page ink annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17134
def post_page_ink_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_ink_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_ink_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_ink_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page ink annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17156
def post_page_ink_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_ink_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_ink_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_ink_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_ink_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/ink".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_ink_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_line_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page line annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17217
def post_page_line_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_line_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_line_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_line_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page line annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17239
def post_page_line_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_line_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_line_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/line".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_link_annotations(name, page_number, links, opts = {}) click to toggle source

Add document page link annotations.

@param name The document name. @param page_number The page number. @param links Array of link annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17300
def post_page_link_annotations(name, page_number, links, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_link_annotations_with_http_info(name, page_number, links, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_link_annotations_with_http_info(name, page_number, links, opts)
    else
      raise
    end
  return data
end
post_page_link_annotations_with_http_info(name, page_number, links, opts = {}) click to toggle source

Add document page link annotations.

@param name The document name. @param page_number The page number. @param links Array of link annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17322
def post_page_link_annotations_with_http_info(name, page_number, links, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_link_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_link_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_link_annotations"
  end
  # verify the required parameter 'links' is set
  if @api_client.config.client_side_validation && links.nil?
    fail ArgumentError, "Missing the required parameter 'links' when calling PdfApi.post_page_link_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/links".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(links)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_link_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_movie_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page movie annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17383
def post_page_movie_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_movie_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_movie_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_movie_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page movie annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17405
def post_page_movie_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_movie_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_movie_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_movie_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_movie_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/movie".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_movie_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_pdf_page_stamps(name, page_number, stamps, opts = {}) click to toggle source

Add document pdf page stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17466
def post_page_pdf_page_stamps(name, page_number, stamps, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_pdf_page_stamps_with_http_info(name, page_number, stamps, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_pdf_page_stamps_with_http_info(name, page_number, stamps, opts)
    else
      raise
    end
  return data
end
post_page_pdf_page_stamps_with_http_info(name, page_number, stamps, opts = {}) click to toggle source

Add document pdf page stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17488
def post_page_pdf_page_stamps_with_http_info(name, page_number, stamps, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_pdf_page_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_pdf_page_stamps"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_pdf_page_stamps"
  end
  # verify the required parameter 'stamps' is set
  if @api_client.config.client_side_validation && stamps.nil?
    fail ArgumentError, "Missing the required parameter 'stamps' when calling PdfApi.post_page_pdf_page_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamps/pdfpage".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(stamps)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_pdf_page_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_poly_line_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page polyline annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17549
def post_page_poly_line_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_poly_line_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_poly_line_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_poly_line_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page polyline annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17571
def post_page_poly_line_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_poly_line_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_poly_line_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_poly_line_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_poly_line_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/polyline".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_poly_line_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_polygon_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page polygon annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17632
def post_page_polygon_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_polygon_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_polygon_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_polygon_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page polygon annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17654
def post_page_polygon_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_polygon_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_polygon_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_polygon_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_polygon_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/polygon".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_polygon_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_redaction_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page redaction annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [BOOLEAN] :apply Apply redaction immediately after adding. (default to false) @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17716
def post_page_redaction_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_redaction_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_redaction_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_redaction_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page redaction annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [BOOLEAN] :apply Apply redaction immediately after adding. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17739
def post_page_redaction_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_redaction_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_redaction_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_redaction_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_redaction_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/redaction".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'apply'] = opts[:'apply'] if !opts[:'apply'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_redaction_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_screen_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page screen annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17801
def post_page_screen_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_screen_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_screen_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_screen_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page screen annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17823
def post_page_screen_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_screen_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_screen_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_screen_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_screen_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/screen".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_screen_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_sound_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page sound annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17884
def post_page_sound_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_sound_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_sound_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_sound_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page sound annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17906
def post_page_sound_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_sound_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_sound_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_sound_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_sound_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/sound".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_sound_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_square_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page square annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17967
def post_page_square_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_square_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_square_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_square_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page square annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 17989
def post_page_square_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_square_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_square_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_square_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_square_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/square".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_square_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_squiggly_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page squiggly annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18050
def post_page_squiggly_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_squiggly_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_squiggly_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_squiggly_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page squiggly annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18072
def post_page_squiggly_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_squiggly_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_squiggly_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_squiggly_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_squiggly_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/squiggly".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_squiggly_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_stamp_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page stamp annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18133
def post_page_stamp_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_stamp_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_stamp_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_stamp_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page stamp annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18155
def post_page_stamp_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_stamp_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_stamp_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_stamp_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_stamp_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/stamp".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_stamp_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_strike_out_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page StrikeOut annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18216
def post_page_strike_out_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_strike_out_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_strike_out_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_strike_out_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page StrikeOut annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18238
def post_page_strike_out_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_strike_out_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_strike_out_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_strike_out_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_strike_out_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/strikeout".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_strike_out_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_tables(name, page_number, tables, opts = {}) click to toggle source

Add document page tables.

@param name The document name. @param page_number The page number. @param tables The array of table. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18299
def post_page_tables(name, page_number, tables, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_tables_with_http_info(name, page_number, tables, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_tables_with_http_info(name, page_number, tables, opts)
    else
      raise
    end
  return data
end
post_page_tables_with_http_info(name, page_number, tables, opts = {}) click to toggle source

Add document page tables.

@param name The document name. @param page_number The page number. @param tables The array of table. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18321
def post_page_tables_with_http_info(name, page_number, tables, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_tables ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_tables"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_tables"
  end
  # verify the required parameter 'tables' is set
  if @api_client.config.client_side_validation && tables.nil?
    fail ArgumentError, "Missing the required parameter 'tables' when calling PdfApi.post_page_tables"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/tables".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(tables)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_tables\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_text_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page text annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18382
def post_page_text_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_text_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_text_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_text_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page text annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18404
def post_page_text_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_text_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_text_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_text_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_text_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/text".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_text_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_text_replace(name, page_number, text_replace_list_request, opts = {}) click to toggle source

Page's replace text method.

@param name @param page_number @param text_replace_list_request @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [TextReplaceResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18465
def post_page_text_replace(name, page_number, text_replace_list_request, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_text_replace_with_http_info(name, page_number, text_replace_list_request, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_text_replace_with_http_info(name, page_number, text_replace_list_request, opts)
    else
      raise
    end
  return data
end
post_page_text_replace_with_http_info(name, page_number, text_replace_list_request, opts = {}) click to toggle source

Page&#39;s replace text method.

@param name @param page_number @param text_replace_list_request @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [Array<(TextReplaceResponse, Fixnum, Hash)>] TextReplaceResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18487
def post_page_text_replace_with_http_info(name, page_number, text_replace_list_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_text_replace ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_text_replace"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_text_replace"
  end
  # verify the required parameter 'text_replace_list_request' is set
  if @api_client.config.client_side_validation && text_replace_list_request.nil?
    fail ArgumentError, "Missing the required parameter 'text_replace_list_request' when calling PdfApi.post_page_text_replace"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/text/replace".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(text_replace_list_request)
  auth_names = ['JWT']
  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 => 'TextReplaceResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_text_replace\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_text_stamps(name, page_number, stamps, opts = {}) click to toggle source

Add document page text stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18548
def post_page_text_stamps(name, page_number, stamps, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_text_stamps_with_http_info(name, page_number, stamps, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_text_stamps_with_http_info(name, page_number, stamps, opts)
    else
      raise
    end
  return data
end
post_page_text_stamps_with_http_info(name, page_number, stamps, opts = {}) click to toggle source

Add document page text stamps.

@param name The document name. @param page_number The page number. @param stamps The array of stamp. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18570
def post_page_text_stamps_with_http_info(name, page_number, stamps, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_text_stamps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_text_stamps"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_text_stamps"
  end
  # verify the required parameter 'stamps' is set
  if @api_client.config.client_side_validation && stamps.nil?
    fail ArgumentError, "Missing the required parameter 'stamps' when calling PdfApi.post_page_text_stamps"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamps/text".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(stamps)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_text_stamps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_page_underline_annotations(name, page_number, annotations, opts = {}) click to toggle source

Add document page underline annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18631
def post_page_underline_annotations(name, page_number, annotations, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_page_underline_annotations_with_http_info(name, page_number, annotations, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_page_underline_annotations_with_http_info(name, page_number, annotations, opts)
    else
      raise
    end
  return data
end
post_page_underline_annotations_with_http_info(name, page_number, annotations, opts = {}) click to toggle source

Add document page underline annotations.

@param name The document name. @param page_number The page number. @param annotations The array of annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18653
def post_page_underline_annotations_with_http_info(name, page_number, annotations, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_page_underline_annotations ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_page_underline_annotations"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_page_underline_annotations"
  end
  # verify the required parameter 'annotations' is set
  if @api_client.config.client_side_validation && annotations.nil?
    fail ArgumentError, "Missing the required parameter 'annotations' when calling PdfApi.post_page_underline_annotations"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/annotations/underline".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotations)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_page_underline_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_popup_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Add document popup annotations.

@param name The document name. @param annotation_id The parent annotation ID. @param annotation The annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18714
def post_popup_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_popup_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_popup_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
post_popup_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Add document popup annotations.

@param name The document name. @param annotation_id The parent annotation ID. @param annotation The annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18736
def post_popup_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_popup_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_popup_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.post_popup_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.post_popup_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/{annotationId}/popup".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_popup_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_radio_button_fields(name, fields, opts = {}) click to toggle source

Add document RadioButton fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18796
def post_radio_button_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_radio_button_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_radio_button_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
post_radio_button_fields_with_http_info(name, fields, opts = {}) click to toggle source

Add document RadioButton fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18817
def post_radio_button_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_radio_button_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_radio_button_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.post_radio_button_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/radiobutton".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_radio_button_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_sign_document(name, sign, opts = {}) click to toggle source

Sign document.

@param name The document name. @param sign Signature object containing signature data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18873
def post_sign_document(name, sign, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_sign_document_with_http_info(name, sign, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_sign_document_with_http_info(name, sign, opts)
    else
      raise
    end
  return data
end
post_sign_document_with_http_info(name, sign, opts = {}) click to toggle source

Sign document.

@param name The document name. @param sign Signature object containing signature data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18894
def post_sign_document_with_http_info(name, sign, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_sign_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_sign_document"
  end
  # verify the required parameter 'sign' is set
  if @api_client.config.client_side_validation && sign.nil?
    fail ArgumentError, "Missing the required parameter 'sign' when calling PdfApi.post_sign_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/sign".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(sign)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_sign_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_sign_page(name, page_number, sign, opts = {}) click to toggle source

Sign page.

@param name The document name. @param page_number The page number. @param sign Signature object containing signature data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18951
def post_sign_page(name, page_number, sign, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_sign_page_with_http_info(name, page_number, sign, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_sign_page_with_http_info(name, page_number, sign, opts)
    else
      raise
    end
  return data
end
post_sign_page_with_http_info(name, page_number, sign, opts = {}) click to toggle source

Sign page.

@param name The document name. @param page_number The page number. @param sign Signature object containing signature data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 18973
def post_sign_page_with_http_info(name, page_number, sign, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_sign_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_sign_page"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.post_sign_page"
  end
  # verify the required parameter 'sign' is set
  if @api_client.config.client_side_validation && sign.nil?
    fail ArgumentError, "Missing the required parameter 'sign' when calling PdfApi.post_sign_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/sign".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(sign)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_sign_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_signature_field(name, field, opts = {}) click to toggle source

Add document signature field.

@param name The document name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19033
def post_signature_field(name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_signature_field_with_http_info(name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_signature_field_with_http_info(name, field, opts)
    else
      raise
    end
  return data
end
post_signature_field_with_http_info(name, field, opts = {}) click to toggle source

Add document signature field.

@param name The document name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19054
def post_signature_field_with_http_info(name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_signature_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_signature_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.post_signature_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/signature".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_signature_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_split_document(name, opts = {}) click to toggle source

Split document to parts.

@param name Document name. @param [Hash] opts the optional parameters @option opts [String] :format Resulting documents format. @option opts [Integer] :from Start page if defined. @option opts [Integer] :to End page if defined. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SplitResultResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19112
def post_split_document(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_split_document_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_split_document_with_http_info(name, opts)
    else
      raise
    end
  return data
end
post_split_document_with_http_info(name, opts = {}) click to toggle source

Split document to parts.

@param name Document name. @param [Hash] opts the optional parameters @option opts [String] :format Resulting documents format. @option opts [Integer] :from Start page if defined. @option opts [Integer] :to End page if defined. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SplitResultResponse, Fixnum, Hash)>] SplitResultResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19135
def post_split_document_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_split_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_split_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/split".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
  query_params[:'from'] = opts[:'from'] if !opts[:'from'].nil?
  query_params[:'to'] = opts[:'to'] if !opts[:'to'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'SplitResultResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_split_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
post_text_box_fields(name, fields, opts = {}) click to toggle source

Add document text box fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19191
def post_text_box_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = post_text_box_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = post_text_box_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
post_text_box_fields_with_http_info(name, fields, opts = {}) click to toggle source

Add document text box fields.

@param name The document name. @param fields The array of field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19212
def post_text_box_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.post_text_box_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.post_text_box_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.post_text_box_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/textbox".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#post_text_box_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_add_new_page(name, opts = {}) click to toggle source

Add new page to end of the document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [DocumentPagesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19267
def put_add_new_page(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_add_new_page_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_add_new_page_with_http_info(name, opts)
    else
      raise
    end
  return data
end
put_add_new_page_with_http_info(name, opts = {}) click to toggle source

Add new page to end of the document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(DocumentPagesResponse, Fixnum, Hash)>] DocumentPagesResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19287
def put_add_new_page_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_add_new_page ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_add_new_page"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPagesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_add_new_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_add_text(name, page_number, paragraph, opts = {}) click to toggle source

Add text to PDF document page.

@param name The document name. @param page_number Number of page (starting from 1). @param paragraph Paragraph data. @param [Hash] opts the optional parameters @option opts [String] :folder Document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19341
def put_add_text(name, page_number, paragraph, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_add_text_with_http_info(name, page_number, paragraph, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_add_text_with_http_info(name, page_number, paragraph, opts)
    else
      raise
    end
  return data
end
put_add_text_with_http_info(name, page_number, paragraph, opts = {}) click to toggle source

Add text to PDF document page.

@param name The document name. @param page_number Number of page (starting from 1). @param paragraph Paragraph data. @param [Hash] opts the optional parameters @option opts [String] :folder Document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19363
def put_add_text_with_http_info(name, page_number, paragraph, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_add_text ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_add_text"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_add_text"
  end
  # verify the required parameter 'paragraph' is set
  if @api_client.config.client_side_validation && paragraph.nil?
    fail ArgumentError, "Missing the required parameter 'paragraph' when calling PdfApi.put_add_text"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/text".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(paragraph)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_add_text\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_annotations_flatten(name, opts = {}) click to toggle source

Flattens the annotations of the specified types

@param name The document name. @param [Hash] opts the optional parameters @option opts [Integer] :start_page The start page number. @option opts [Integer] :end_page The end page number. @option opts [Array<AnnotationType>] :annotation_types Array of annotation types. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19425
def put_annotations_flatten(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_annotations_flatten_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_annotations_flatten_with_http_info(name, opts)
    else
      raise
    end
  return data
end
put_annotations_flatten_with_http_info(name, opts = {}) click to toggle source

Flattens the annotations of the specified types

@param name The document name. @param [Hash] opts the optional parameters @option opts [Integer] :start_page The start page number. @option opts [Integer] :end_page The end page number. @option opts [Array<AnnotationType>] :annotation_types Array of annotation types. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19448
def put_annotations_flatten_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_annotations_flatten ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_annotations_flatten"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/flatten".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'startPage'] = opts[:'start_page'] if !opts[:'start_page'].nil?
  query_params[:'endPage'] = opts[:'end_page'] if !opts[:'end_page'].nil?
  query_params[:'annotationTypes'] = @api_client.build_collection_param(opts[:'annotation_types'], :csv) if !opts[:'annotation_types'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_annotations_flatten\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_bookmark(name, bookmark_path, bookmark, opts = {}) click to toggle source

Update document bookmark.

@param name The document name. @param bookmark_path The bookmark path. @param bookmark The bookmark. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [BookmarkResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19505
def put_bookmark(name, bookmark_path, bookmark, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_bookmark_with_http_info(name, bookmark_path, bookmark, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_bookmark_with_http_info(name, bookmark_path, bookmark, opts)
    else
      raise
    end
  return data
end
put_bookmark_with_http_info(name, bookmark_path, bookmark, opts = {}) click to toggle source

Update document bookmark.

@param name The document name. @param bookmark_path The bookmark path. @param bookmark The bookmark. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(BookmarkResponse, Fixnum, Hash)>] BookmarkResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19527
def put_bookmark_with_http_info(name, bookmark_path, bookmark, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_bookmark ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_bookmark"
  end
  # verify the required parameter 'bookmark_path' is set
  if @api_client.config.client_side_validation && bookmark_path.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark_path' when calling PdfApi.put_bookmark"
  end
  # verify the required parameter 'bookmark' is set
  if @api_client.config.client_side_validation && bookmark.nil?
    fail ArgumentError, "Missing the required parameter 'bookmark' when calling PdfApi.put_bookmark"
  end
  # resource path
  local_var_path = "/pdf/{name}/bookmarks/bookmark/{bookmarkPath}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'bookmarkPath' + '}', bookmark_path.to_s)

  # query parameters
  query_params = {}
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(bookmark)
  auth_names = ['JWT']
  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 => 'BookmarkResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_bookmark\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_caret_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document caret annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CaretAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19588
def put_caret_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_caret_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_caret_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_caret_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document caret annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CaretAnnotationResponse, Fixnum, Hash)>] CaretAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19610
def put_caret_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_caret_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_caret_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_caret_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_caret_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/caret/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'CaretAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_caret_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_change_password_document(out_path, owner_password, new_user_password, new_owner_password, opts = {}) click to toggle source

Change document password from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param owner_password Owner password (encrypted Base64). @param new_user_password New user password (encrypted Base64). @param new_owner_password New owner password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be changed password. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19672
def put_change_password_document(out_path, owner_password, new_user_password, new_owner_password, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_change_password_document_with_http_info(out_path, owner_password, new_user_password, new_owner_password, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_change_password_document_with_http_info(out_path, owner_password, new_user_password, new_owner_password, opts)
    else
      raise
    end
  return data
end
put_change_password_document_with_http_info(out_path, owner_password, new_user_password, new_owner_password, opts = {}) click to toggle source

Change document password from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param owner_password Owner password (encrypted Base64). @param new_user_password New user password (encrypted Base64). @param new_owner_password New owner password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be changed password. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19695
def put_change_password_document_with_http_info(out_path, owner_password, new_user_password, new_owner_password, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_change_password_document ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_change_password_document"
  end
  # verify the required parameter 'owner_password' is set
  if @api_client.config.client_side_validation && owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'owner_password' when calling PdfApi.put_change_password_document"
  end
  # verify the required parameter 'new_user_password' is set
  if @api_client.config.client_side_validation && new_user_password.nil?
    fail ArgumentError, "Missing the required parameter 'new_user_password' when calling PdfApi.put_change_password_document"
  end
  # verify the required parameter 'new_owner_password' is set
  if @api_client.config.client_side_validation && new_owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'new_owner_password' when calling PdfApi.put_change_password_document"
  end
  # resource path
  local_var_path = "/pdf/changepassword"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'ownerPassword'] = owner_password
  query_params[:'newUserPassword'] = new_user_password
  query_params[:'newOwnerPassword'] = new_owner_password
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_change_password_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_check_box_field(name, field_name, field, opts = {}) click to toggle source

Replace document checkbox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CheckBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19766
def put_check_box_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_check_box_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_check_box_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_check_box_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document checkbox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CheckBoxFieldResponse, Fixnum, Hash)>] CheckBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19788
def put_check_box_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_check_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_check_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_check_box_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_check_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/checkbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'CheckBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_check_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_circle_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document circle annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [CircleAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19849
def put_circle_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_circle_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_circle_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_circle_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document circle annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(CircleAnnotationResponse, Fixnum, Hash)>] CircleAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19871
def put_circle_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_circle_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_circle_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_circle_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_circle_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/circle/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'CircleAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_circle_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_combo_box_field(name, field_name, field, opts = {}) click to toggle source

Replace document combobox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ComboBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19932
def put_combo_box_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_combo_box_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_combo_box_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_combo_box_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document combobox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ComboBoxFieldResponse, Fixnum, Hash)>] ComboBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 19954
def put_combo_box_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_combo_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_combo_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_combo_box_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_combo_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/combobox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'ComboBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_combo_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_create_document(name, opts = {}) click to toggle source

Create empty document.

@param name The new document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The new document folder. @return [DocumentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20013
def put_create_document(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_create_document_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_create_document_with_http_info(name, opts)
    else
      raise
    end
  return data
end
put_create_document_with_http_info(name, opts = {}) click to toggle source

Create empty document.

@param name The new document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The new document folder. @return [Array<(DocumentResponse, Fixnum, Hash)>] DocumentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20033
def put_create_document_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_create_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_create_document"
  end
  # resource path
  local_var_path = "/pdf/{name}".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_create_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_decrypt_document(out_path, password, opts = {}) click to toggle source

Decrypt document from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param password The password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be decrypted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20086
def put_decrypt_document(out_path, password, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_decrypt_document_with_http_info(out_path, password, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_decrypt_document_with_http_info(out_path, password, opts)
    else
      raise
    end
  return data
end
put_decrypt_document_with_http_info(out_path, password, opts = {}) click to toggle source

Decrypt document from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param password The password (encrypted Base64). @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be decrypted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20107
def put_decrypt_document_with_http_info(out_path, password, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_decrypt_document ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_decrypt_document"
  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 PdfApi.put_decrypt_document"
  end
  # resource path
  local_var_path = "/pdf/decrypt"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'password'] = password
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_decrypt_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_document_display_properties(name, display_properties, opts = {}) click to toggle source

Update document display properties.

@param name The document name. @param display_properties The display properties. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [DisplayPropertiesResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20167
def put_document_display_properties(name, display_properties, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_document_display_properties_with_http_info(name, display_properties, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_document_display_properties_with_http_info(name, display_properties, opts)
    else
      raise
    end
  return data
end
put_document_display_properties_with_http_info(name, display_properties, opts = {}) click to toggle source

Update document display properties.

@param name The document name. @param display_properties The display properties. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(DisplayPropertiesResponse, Fixnum, Hash)>] DisplayPropertiesResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20188
def put_document_display_properties_with_http_info(name, display_properties, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_document_display_properties ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_document_display_properties"
  end
  # verify the required parameter 'display_properties' is set
  if @api_client.config.client_side_validation && display_properties.nil?
    fail ArgumentError, "Missing the required parameter 'display_properties' when calling PdfApi.put_document_display_properties"
  end
  # resource path
  local_var_path = "/pdf/{name}/displayproperties".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(display_properties)
  auth_names = ['JWT']
  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 => 'DisplayPropertiesResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_document_display_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_encrypt_document(out_path, user_password, owner_password, crypto_algorithm, opts = {}) click to toggle source

Encrypt document from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param user_password User password (encrypted Base64). @param owner_password Owner password (encrypted Base64). @param crypto_algorithm Cryptographic algorithm, see CryptoAlgorithm for details. @param [Hash] opts the optional parameters @option opts [Array<PermissionsFlags>] :permissions_flags Array of document permissions, see PermissionsFlags for details. @option opts [BOOLEAN] :use_pdf20 Support for revision 6 (Extension 8). @option opts [String] :storage The document storage. @option opts [File] :file A file to be encrypted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20248
def put_encrypt_document(out_path, user_password, owner_password, crypto_algorithm, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_encrypt_document_with_http_info(out_path, user_password, owner_password, crypto_algorithm, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_encrypt_document_with_http_info(out_path, user_password, owner_password, crypto_algorithm, opts)
    else
      raise
    end
  return data
end
put_encrypt_document_with_http_info(out_path, user_password, owner_password, crypto_algorithm, opts = {}) click to toggle source

Encrypt document from content.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param user_password User password (encrypted Base64). @param owner_password Owner password (encrypted Base64). @param crypto_algorithm Cryptographic algorithm, see CryptoAlgorithm for details. @param [Hash] opts the optional parameters @option opts [Array<PermissionsFlags>] :permissions_flags Array of document permissions, see PermissionsFlags for details. @option opts [BOOLEAN] :use_pdf20 Support for revision 6 (Extension 8). @option opts [String] :storage The document storage. @option opts [File] :file A file to be encrypted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20273
def put_encrypt_document_with_http_info(out_path, user_password, owner_password, crypto_algorithm, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_encrypt_document ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_encrypt_document"
  end
  # verify the required parameter 'user_password' is set
  if @api_client.config.client_side_validation && user_password.nil?
    fail ArgumentError, "Missing the required parameter 'user_password' when calling PdfApi.put_encrypt_document"
  end
  # verify the required parameter 'owner_password' is set
  if @api_client.config.client_side_validation && owner_password.nil?
    fail ArgumentError, "Missing the required parameter 'owner_password' when calling PdfApi.put_encrypt_document"
  end
  # verify the required parameter 'crypto_algorithm' is set
  if @api_client.config.client_side_validation && crypto_algorithm.nil?
    fail ArgumentError, "Missing the required parameter 'crypto_algorithm' when calling PdfApi.put_encrypt_document"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['RC4x40', 'RC4x128', 'AESx128', 'AESx256'].include?(crypto_algorithm)
    fail ArgumentError, "invalid value for 'crypto_algorithm', must be one of RC4x40, RC4x128, AESx128, AESx256"
  end
  # resource path
  local_var_path = "/pdf/encrypt"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'userPassword'] = user_password
  query_params[:'ownerPassword'] = owner_password
  query_params[:'cryptoAlgorithm'] = crypto_algorithm
  query_params[:'permissionsFlags'] = @api_client.build_collection_param(opts[:'permissions_flags'], :csv) if !opts[:'permissions_flags'].nil?
  query_params[:'usePdf20'] = opts[:'use_pdf20'] if !opts[:'use_pdf20'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_encrypt_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_epub_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert EPUB file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.epub) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :dst_folder The destination document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20349
def put_epub_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_epub_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_epub_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_epub_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert EPUB file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.epub) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :dst_folder The destination document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20370
def put_epub_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_epub_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_epub_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_epub_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/epub".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_epub_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_export_fields_from_pdf_to_fdf_in_storage(name, fdf_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to FDF file in storage.

@param name The document name. @param fdf_output_file_path The output Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20428
def put_export_fields_from_pdf_to_fdf_in_storage(name, fdf_output_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, fdf_output_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, fdf_output_file_path, opts)
    else
      raise
    end
  return data
end
put_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, fdf_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to FDF file in storage.

@param name The document name. @param fdf_output_file_path The output Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20449
def put_export_fields_from_pdf_to_fdf_in_storage_with_http_info(name, fdf_output_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_export_fields_from_pdf_to_fdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_export_fields_from_pdf_to_fdf_in_storage"
  end
  # verify the required parameter 'fdf_output_file_path' is set
  if @api_client.config.client_side_validation && fdf_output_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'fdf_output_file_path' when calling PdfApi.put_export_fields_from_pdf_to_fdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/fdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'fdfOutputFilePath'] = fdf_output_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_export_fields_from_pdf_to_fdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_export_fields_from_pdf_to_xfdf_in_storage(name, xfdf_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to XFDF file in storage.

@param name The document name. @param xfdf_output_file_path The output xfdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20507
def put_export_fields_from_pdf_to_xfdf_in_storage(name, xfdf_output_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, xfdf_output_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, xfdf_output_file_path, opts)
    else
      raise
    end
  return data
end
put_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, xfdf_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to XFDF file in storage.

@param name The document name. @param xfdf_output_file_path The output xfdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20528
def put_export_fields_from_pdf_to_xfdf_in_storage_with_http_info(name, xfdf_output_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_export_fields_from_pdf_to_xfdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_export_fields_from_pdf_to_xfdf_in_storage"
  end
  # verify the required parameter 'xfdf_output_file_path' is set
  if @api_client.config.client_side_validation && xfdf_output_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xfdf_output_file_path' when calling PdfApi.put_export_fields_from_pdf_to_xfdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/xfdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xfdfOutputFilePath'] = xfdf_output_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_export_fields_from_pdf_to_xfdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_export_fields_from_pdf_to_xml_in_storage(name, xml_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to XML file in storage.

@param name The document name. @param xml_output_file_path The output xml file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20586
def put_export_fields_from_pdf_to_xml_in_storage(name, xml_output_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, xml_output_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, xml_output_file_path, opts)
    else
      raise
    end
  return data
end
put_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, xml_output_file_path, opts = {}) click to toggle source

Export fields from from PDF in storage to XML file in storage.

@param name The document name. @param xml_output_file_path The output xml file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20607
def put_export_fields_from_pdf_to_xml_in_storage_with_http_info(name, xml_output_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_export_fields_from_pdf_to_xml_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_export_fields_from_pdf_to_xml_in_storage"
  end
  # verify the required parameter 'xml_output_file_path' is set
  if @api_client.config.client_side_validation && xml_output_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xml_output_file_path' when calling PdfApi.put_export_fields_from_pdf_to_xml_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/export/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xmlOutputFilePath'] = xml_output_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_export_fields_from_pdf_to_xml_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_fields_flatten(name, opts = {}) click to toggle source

Flatten form fields in document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20664
def put_fields_flatten(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_fields_flatten_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_fields_flatten_with_http_info(name, opts)
    else
      raise
    end
  return data
end
put_fields_flatten_with_http_info(name, opts = {}) click to toggle source

Flatten form fields in document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20684
def put_fields_flatten_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_fields_flatten ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_fields_flatten"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/flatten".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_fields_flatten\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_file_attachment_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document FileAttachment annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FileAttachmentAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20738
def put_file_attachment_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_file_attachment_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_file_attachment_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_file_attachment_annotation_data_extract(name, annotation_id, opts = {}) click to toggle source

Extract document FileAttachment annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :out_folder The output folder. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20821
def put_file_attachment_annotation_data_extract(name, annotation_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_file_attachment_annotation_data_extract_with_http_info(name, annotation_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_file_attachment_annotation_data_extract_with_http_info(name, annotation_id, opts)
    else
      raise
    end
  return data
end
put_file_attachment_annotation_data_extract_with_http_info(name, annotation_id, opts = {}) click to toggle source

Extract document FileAttachment annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param [Hash] opts the optional parameters @option opts [String] :out_folder The output folder. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20843
def put_file_attachment_annotation_data_extract_with_http_info(name, annotation_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_file_attachment_annotation_data_extract ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_file_attachment_annotation_data_extract"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_file_attachment_annotation_data_extract"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/fileattachment/{annotationId}/data/extract".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'outFolder'] = opts[:'out_folder'] if !opts[:'out_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_file_attachment_annotation_data_extract\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_file_attachment_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document FileAttachment annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FileAttachmentAnnotationResponse, Fixnum, Hash)>] FileAttachmentAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20760
def put_file_attachment_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_file_attachment_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_file_attachment_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_file_attachment_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_file_attachment_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/fileattachment/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'FileAttachmentAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_file_attachment_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_free_text_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document free text annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FreeTextAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20902
def put_free_text_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_free_text_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_free_text_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_free_text_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document free text annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FreeTextAnnotationResponse, Fixnum, Hash)>] FreeTextAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20924
def put_free_text_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_free_text_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_free_text_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_free_text_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_free_text_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/freetext/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'FreeTextAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_free_text_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_highlight_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document highlight annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [HighlightAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 20985
def put_highlight_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_highlight_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_highlight_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_highlight_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document highlight annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(HighlightAnnotationResponse, Fixnum, Hash)>] HighlightAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21007
def put_highlight_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_highlight_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_highlight_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_highlight_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_highlight_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/highlight/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'HighlightAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_highlight_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_html_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert HTML file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.zip) @param [Hash] opts the optional parameters @option opts [String] :html_file_name Name of HTML file in ZIP. @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21075
def put_html_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_html_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_html_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_html_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert HTML file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.zip) @param [Hash] opts the optional parameters @option opts [String] :html_file_name Name of HTML file in ZIP. @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21104
def put_html_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_html_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_html_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_html_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/html".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'htmlFileName'] = opts[:'html_file_name'] if !opts[:'html_file_name'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_html_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_image_extract_as_gif(name, image_id, opts = {}) click to toggle source

Extract document image in GIF format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21173
def put_image_extract_as_gif(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_image_extract_as_gif_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_image_extract_as_gif_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
put_image_extract_as_gif_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in GIF format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21197
def put_image_extract_as_gif_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_image_extract_as_gif ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_image_extract_as_gif"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.put_image_extract_as_gif"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/gif".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_image_extract_as_gif\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_image_extract_as_jpeg(name, image_id, opts = {}) click to toggle source

Extract document image in JPEG format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21260
def put_image_extract_as_jpeg(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_image_extract_as_jpeg_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_image_extract_as_jpeg_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
put_image_extract_as_jpeg_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in JPEG format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21284
def put_image_extract_as_jpeg_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_image_extract_as_jpeg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_image_extract_as_jpeg"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.put_image_extract_as_jpeg"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/jpeg".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_image_extract_as_jpeg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_image_extract_as_png(name, image_id, opts = {}) click to toggle source

Extract document image in PNG format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21347
def put_image_extract_as_png(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_image_extract_as_png_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_image_extract_as_png_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
put_image_extract_as_png_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in PNG format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21371
def put_image_extract_as_png_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_image_extract_as_png ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_image_extract_as_png"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.put_image_extract_as_png"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/png".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_image_extract_as_png\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_image_extract_as_tiff(name, image_id, opts = {}) click to toggle source

Extract document image in TIFF format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21434
def put_image_extract_as_tiff(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_image_extract_as_tiff_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_image_extract_as_tiff_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
put_image_extract_as_tiff_with_http_info(name, image_id, opts = {}) click to toggle source

Extract document image in TIFF format to folder

@param name The document name. @param image_id Image ID. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21458
def put_image_extract_as_tiff_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_image_extract_as_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_image_extract_as_tiff"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.put_image_extract_as_tiff"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}/extract/tiff".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_image_extract_as_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_image_in_storage_to_pdf(name, image_templates, opts = {}) click to toggle source

Convert image file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param image_templates ImageTemplatesRequestImage templates @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21518
def put_image_in_storage_to_pdf(name, image_templates, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_image_in_storage_to_pdf_with_http_info(name, image_templates, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_image_in_storage_to_pdf_with_http_info(name, image_templates, opts)
    else
      raise
    end
  return data
end
put_image_in_storage_to_pdf_with_http_info(name, image_templates, opts = {}) click to toggle source

Convert image file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param image_templates ImageTemplatesRequestImage templates @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21539
def put_image_in_storage_to_pdf_with_http_info(name, image_templates, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_image_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_image_in_storage_to_pdf"
  end
  # verify the required parameter 'image_templates' is set
  if @api_client.config.client_side_validation && image_templates.nil?
    fail ArgumentError, "Missing the required parameter 'image_templates' when calling PdfApi.put_image_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/images".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(image_templates)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_image_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_images_extract_as_gif(name, page_number, opts = {}) click to toggle source

Extract document images in GIF format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21598
def put_images_extract_as_gif(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_images_extract_as_gif_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_images_extract_as_gif_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
put_images_extract_as_gif_with_http_info(name, page_number, opts = {}) click to toggle source

Extract document images in GIF format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21622
def put_images_extract_as_gif_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_images_extract_as_gif ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_images_extract_as_gif"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_images_extract_as_gif"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images/extract/gif".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_images_extract_as_gif\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_images_extract_as_jpeg(name, page_number, opts = {}) click to toggle source

Extract document images in JPEG format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21685
def put_images_extract_as_jpeg(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_images_extract_as_jpeg_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_images_extract_as_jpeg_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
put_images_extract_as_jpeg_with_http_info(name, page_number, opts = {}) click to toggle source

Extract document images in JPEG format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21709
def put_images_extract_as_jpeg_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_images_extract_as_jpeg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_images_extract_as_jpeg"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_images_extract_as_jpeg"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images/extract/jpeg".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_images_extract_as_jpeg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_images_extract_as_png(name, page_number, opts = {}) click to toggle source

Extract document images in PNG format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21772
def put_images_extract_as_png(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_images_extract_as_png_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_images_extract_as_png_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
put_images_extract_as_png_with_http_info(name, page_number, opts = {}) click to toggle source

Extract document images in PNG format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21796
def put_images_extract_as_png_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_images_extract_as_png ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_images_extract_as_png"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_images_extract_as_png"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images/extract/png".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_images_extract_as_png\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_images_extract_as_tiff(name, page_number, opts = {}) click to toggle source

Extract document images in TIFF format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21859
def put_images_extract_as_tiff(name, page_number, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_images_extract_as_tiff_with_http_info(name, page_number, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_images_extract_as_tiff_with_http_info(name, page_number, opts)
    else
      raise
    end
  return data
end
put_images_extract_as_tiff_with_http_info(name, page_number, opts = {}) click to toggle source

Extract document images in TIFF format to folder.

@param name The document name. @param page_number The page number. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :dest_folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21883
def put_images_extract_as_tiff_with_http_info(name, page_number, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_images_extract_as_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_images_extract_as_tiff"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_images_extract_as_tiff"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/images/extract/tiff".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'destFolder'] = opts[:'dest_folder'] if !opts[:'dest_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_images_extract_as_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_import_fields_from_fdf_in_storage(name, fdf_file_path, opts = {}) click to toggle source

Update fields from FDF file in storage.

@param name The document name. @param fdf_file_path The Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21943
def put_import_fields_from_fdf_in_storage(name, fdf_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts)
    else
      raise
    end
  return data
end
put_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts = {}) click to toggle source

Update fields from FDF file in storage.

@param name The document name. @param fdf_file_path The Fdf file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 21964
def put_import_fields_from_fdf_in_storage_with_http_info(name, fdf_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_import_fields_from_fdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_import_fields_from_fdf_in_storage"
  end
  # verify the required parameter 'fdf_file_path' is set
  if @api_client.config.client_side_validation && fdf_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'fdf_file_path' when calling PdfApi.put_import_fields_from_fdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/fdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'fdfFilePath'] = fdf_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_import_fields_from_fdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_import_fields_from_xfdf_in_storage(name, xfdf_file_path, opts = {}) click to toggle source

Update fields from XFDF file in storage.

@param name The document name. @param xfdf_file_path The XFDF file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22022
def put_import_fields_from_xfdf_in_storage(name, xfdf_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts)
    else
      raise
    end
  return data
end
put_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts = {}) click to toggle source

Update fields from XFDF file in storage.

@param name The document name. @param xfdf_file_path The XFDF file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22043
def put_import_fields_from_xfdf_in_storage_with_http_info(name, xfdf_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_import_fields_from_xfdf_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_import_fields_from_xfdf_in_storage"
  end
  # verify the required parameter 'xfdf_file_path' is set
  if @api_client.config.client_side_validation && xfdf_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xfdf_file_path' when calling PdfApi.put_import_fields_from_xfdf_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xfdf".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xfdfFilePath'] = xfdf_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_import_fields_from_xfdf_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_import_fields_from_xml_in_storage(name, xml_file_path, opts = {}) click to toggle source

Update fields from XML file in storage.

@param name The document name. @param xml_file_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22101
def put_import_fields_from_xml_in_storage(name, xml_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts)
    else
      raise
    end
  return data
end
put_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts = {}) click to toggle source

Update fields from XML file in storage.

@param name The document name. @param xml_file_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22122
def put_import_fields_from_xml_in_storage_with_http_info(name, xml_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_import_fields_from_xml_in_storage ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_import_fields_from_xml_in_storage"
  end
  # verify the required parameter 'xml_file_path' is set
  if @api_client.config.client_side_validation && xml_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'xml_file_path' when calling PdfApi.put_import_fields_from_xml_in_storage"
  end
  # resource path
  local_var_path = "/pdf/{name}/import/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'xmlFilePath'] = xml_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_import_fields_from_xml_in_storage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_ink_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document ink annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [InkAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22181
def put_ink_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_ink_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_ink_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_ink_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document ink annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(InkAnnotationResponse, Fixnum, Hash)>] InkAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22203
def put_ink_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_ink_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_ink_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_ink_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_ink_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/ink/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'InkAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_ink_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_la_te_x_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22263
def put_la_te_x_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_la_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_la_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_la_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22284
def put_la_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_la_te_x_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_la_te_x_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_la_te_x_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/latex".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_la_te_x_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_line_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document line annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [LineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22343
def put_line_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_line_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_line_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_line_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document line annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(LineAnnotationResponse, Fixnum, Hash)>] LineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22365
def put_line_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_line_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_line_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_line_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_line_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/line/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'LineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_line_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_list_box_field(name, field_name, field, opts = {}) click to toggle source

Replace document listbox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ListBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22509
def put_list_box_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_list_box_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_list_box_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_list_box_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document listbox field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ListBoxFieldResponse, Fixnum, Hash)>] ListBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22531
def put_list_box_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_list_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_list_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_list_box_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_list_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/listbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'ListBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_list_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_markdown_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert MD file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.md) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :dst_folder The destination document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22591
def put_markdown_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_markdown_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_markdown_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_markdown_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert MD file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.md) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :dst_folder The destination document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22612
def put_markdown_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_markdown_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_markdown_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_markdown_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/markdown".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_markdown_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_merge_documents(name, merge_documents, opts = {}) click to toggle source

Merge a list of documents.

@param name Resulting document name. @param merge_documents MergeDocuments with a list of documents. @param [Hash] opts the optional parameters @option opts [String] :storage Resulting document storage. @option opts [String] :folder Resulting document folder. @return [DocumentResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22670
def put_merge_documents(name, merge_documents, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_merge_documents_with_http_info(name, merge_documents, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_merge_documents_with_http_info(name, merge_documents, opts)
    else
      raise
    end
  return data
end
put_merge_documents_with_http_info(name, merge_documents, opts = {}) click to toggle source

Merge a list of documents.

@param name Resulting document name. @param merge_documents MergeDocuments with a list of documents. @param [Hash] opts the optional parameters @option opts [String] :storage Resulting document storage. @option opts [String] :folder Resulting document folder. @return [Array<(DocumentResponse, Fixnum, Hash)>] DocumentResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22691
def put_merge_documents_with_http_info(name, merge_documents, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_merge_documents ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_merge_documents"
  end
  # verify the required parameter 'merge_documents' is set
  if @api_client.config.client_side_validation && merge_documents.nil?
    fail ArgumentError, "Missing the required parameter 'merge_documents' when calling PdfApi.put_merge_documents"
  end
  # resource path
  local_var_path = "/pdf/{name}/merge".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(merge_documents)
  auth_names = ['JWT']
  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 => 'DocumentResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_merge_documents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_mht_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert MHT file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.mht) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22747
def put_mht_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_mht_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_mht_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_mht_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert MHT file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.mht) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22768
def put_mht_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_mht_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_mht_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_mht_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/mht".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_mht_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_movie_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document movie annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [MovieAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22827
def put_movie_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_movie_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_movie_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_movie_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document movie annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(MovieAnnotationResponse, Fixnum, Hash)>] MovieAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22849
def put_movie_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_movie_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_movie_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_movie_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_movie_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/movie/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'MovieAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_movie_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_add_stamp(name, page_number, stamp, opts = {}) click to toggle source

Add page stamp.

@param name The document name. @param page_number The page number. @param stamp Stamp with data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22910
def put_page_add_stamp(name, page_number, stamp, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_add_stamp_with_http_info(name, page_number, stamp, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_add_stamp_with_http_info(name, page_number, stamp, opts)
    else
      raise
    end
  return data
end
put_page_add_stamp_with_http_info(name, page_number, stamp, opts = {}) click to toggle source

Add page stamp.

@param name The document name. @param page_number The page number. @param stamp Stamp with data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22932
def put_page_add_stamp_with_http_info(name, page_number, stamp, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_add_stamp ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_add_stamp"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_add_stamp"
  end
  # verify the required parameter 'stamp' is set
  if @api_client.config.client_side_validation && stamp.nil?
    fail ArgumentError, "Missing the required parameter 'stamp' when calling PdfApi.put_page_add_stamp"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/stamp".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(stamp)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_add_stamp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_bmp(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to bmp image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 22995
def put_page_convert_to_bmp(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_bmp_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_bmp_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_bmp_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to bmp image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23019
def put_page_convert_to_bmp_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_bmp ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_bmp"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_bmp"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_bmp"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/bmp".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_bmp\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_emf(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to emf image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23086
def put_page_convert_to_emf(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_emf_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_emf_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_emf_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to emf image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23110
def put_page_convert_to_emf_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_emf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_emf"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_emf"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_emf"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/emf".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_emf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_gif(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to gif image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23177
def put_page_convert_to_gif(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_gif_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_gif_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_gif_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to gif image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23201
def put_page_convert_to_gif_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_gif ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_gif"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_gif"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_gif"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/gif".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_gif\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_jpeg(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to Jpeg image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23268
def put_page_convert_to_jpeg(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_jpeg_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_jpeg_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_jpeg_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to Jpeg image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23292
def put_page_convert_to_jpeg_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_jpeg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_jpeg"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_jpeg"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_jpeg"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/jpeg".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_jpeg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_png(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to png image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23359
def put_page_convert_to_png(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_png_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_png_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_png_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to png image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23383
def put_page_convert_to_png_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_png ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_png"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_png"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_png"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/png".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_png\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_page_convert_to_tiff(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to Tiff image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. (default to 0) @option opts [Integer] :height The converted image height. (default to 0) @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23450
def put_page_convert_to_tiff(name, page_number, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_page_convert_to_tiff_with_http_info(name, page_number, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_page_convert_to_tiff_with_http_info(name, page_number, out_path, opts)
    else
      raise
    end
  return data
end
put_page_convert_to_tiff_with_http_info(name, page_number, out_path, opts = {}) click to toggle source

Convert document page to Tiff image and upload resulting file to storage.

@param name The document name. @param page_number The page number. @param out_path The out path of result image. @param [Hash] opts the optional parameters @option opts [Integer] :width The converted image width. @option opts [Integer] :height The converted image height. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23474
def put_page_convert_to_tiff_with_http_info(name, page_number, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_page_convert_to_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_page_convert_to_tiff"
  end
  # verify the required parameter 'page_number' is set
  if @api_client.config.client_side_validation && page_number.nil?
    fail ArgumentError, "Missing the required parameter 'page_number' when calling PdfApi.put_page_convert_to_tiff"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_page_convert_to_tiff"
  end
  # resource path
  local_var_path = "/pdf/{name}/pages/{pageNumber}/convert/tiff".sub('{' + 'name' + '}', name.to_s).sub('{' + 'pageNumber' + '}', page_number.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_page_convert_to_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pcl_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert PCL file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.pcl) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23538
def put_pcl_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pcl_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pcl_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_pcl_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert PCL file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.pcl) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23559
def put_pcl_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pcl_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pcl_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_pcl_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/pcl".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pcl_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_a_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert PDFA file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.pdf) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [BOOLEAN] :dont_optimize If set, document resources will not be optimized. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23618
def put_pdf_a_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_a_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_a_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_pdf_a_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert PDFA file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.pdf) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [BOOLEAN] :dont_optimize If set, document resources will not be optimized. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23640
def put_pdf_a_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_a_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_a_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_pdf_a_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/pdfa".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'dontOptimize'] = opts[:'dont_optimize'] if !opts[:'dont_optimize'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_a_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_doc(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to DOC format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23706
def put_pdf_in_request_to_doc(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_doc_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_doc_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_doc_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to DOC format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23734
def put_pdf_in_request_to_doc_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_doc ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_doc"
  end
  if @api_client.config.client_side_validation && opts[:'format'] && !['Doc', 'DocX'].include?(opts[:'format'])
    fail ArgumentError, 'invalid value for "format", must be one of Doc, DocX'
  end
  if @api_client.config.client_side_validation && opts[:'mode'] && !['Textbox', 'Flow'].include?(opts[:'mode'])
    fail ArgumentError, 'invalid value for "mode", must be one of Textbox, Flow'
  end
  # resource path
  local_var_path = "/pdf/convert/doc"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'addReturnToLineEnd'] = opts[:'add_return_to_line_end'] if !opts[:'add_return_to_line_end'].nil?
  query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
  query_params[:'imageResolutionX'] = opts[:'image_resolution_x'] if !opts[:'image_resolution_x'].nil?
  query_params[:'imageResolutionY'] = opts[:'image_resolution_y'] if !opts[:'image_resolution_y'].nil?
  query_params[:'maxDistanceBetweenTextLines'] = opts[:'max_distance_between_text_lines'] if !opts[:'max_distance_between_text_lines'].nil?
  query_params[:'mode'] = opts[:'mode'] if !opts[:'mode'].nil?
  query_params[:'recognizeBullets'] = opts[:'recognize_bullets'] if !opts[:'recognize_bullets'].nil?
  query_params[:'relativeHorizontalProximity'] = opts[:'relative_horizontal_proximity'] if !opts[:'relative_horizontal_proximity'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_doc\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_epub(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to EPUB format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.epub) @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23803
def put_pdf_in_request_to_epub(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_epub_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_epub_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_epub_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to EPUB format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.epub) @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23824
def put_pdf_in_request_to_epub_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_epub ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_epub"
  end
  if @api_client.config.client_side_validation && opts[:'content_recognition_mode'] && !['Flow', 'PdfFlow', 'Fixed'].include?(opts[:'content_recognition_mode'])
    fail ArgumentError, 'invalid value for "content_recognition_mode", must be one of Flow, PdfFlow, Fixed'
  end
  # resource path
  local_var_path = "/pdf/convert/epub"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'contentRecognitionMode'] = opts[:'content_recognition_mode'] if !opts[:'content_recognition_mode'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_epub\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_html(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to Html format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.html) @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @option opts [String] :output_format This parameter determines the type of result. The zip archive will be uploaded into the storage if the parameter is "Zip&quot; or missed (default). In case of the "Folder&quot;, all resulting files and directories will be uploaded to the folder of the resulting HTML file. (default to Zip) @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23912
def put_pdf_in_request_to_html(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_html_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_html_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_html_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to Html format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.html) @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @option opts [String] :output_format This parameter determines the type of result. The zip archive will be uploaded into the storage if the parameter is "Zip&quot; or missed (default). In case of the "Folder&quot;, all resulting files and directories will be uploaded to the folder of the resulting HTML file. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 23962
def put_pdf_in_request_to_html_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_html ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_html"
  end
  if @api_client.config.client_side_validation && opts[:'document_type'] && !['Xhtml', 'Html5'].include?(opts[:'document_type'])
    fail ArgumentError, 'invalid value for "document_type", must be one of Xhtml, Html5'
  end
  if @api_client.config.client_side_validation && opts[:'antialiasing_processing'] && !['NoAdditionalProcessing', 'TryCorrectResultHtml'].include?(opts[:'antialiasing_processing'])
    fail ArgumentError, 'invalid value for "antialiasing_processing", must be one of NoAdditionalProcessing, TryCorrectResultHtml'
  end
  if @api_client.config.client_side_validation && opts[:'font_encoding_strategy'] && !['Default', 'DecreaseToUnicodePriorityLevel'].include?(opts[:'font_encoding_strategy'])
    fail ArgumentError, 'invalid value for "font_encoding_strategy", must be one of Default, DecreaseToUnicodePriorityLevel'
  end
  if @api_client.config.client_side_validation && opts[:'font_saving_mode'] && !['AlwaysSaveAsWOFF', 'AlwaysSaveAsTTF', 'AlwaysSaveAsEOT', 'SaveInAllFormats'].include?(opts[:'font_saving_mode'])
    fail ArgumentError, 'invalid value for "font_saving_mode", must be one of AlwaysSaveAsWOFF, AlwaysSaveAsTTF, AlwaysSaveAsEOT, SaveInAllFormats'
  end
  if @api_client.config.client_side_validation && opts[:'html_markup_generation_mode'] && !['WriteAllHtml', 'WriteOnlyBodyContent'].include?(opts[:'html_markup_generation_mode'])
    fail ArgumentError, 'invalid value for "html_markup_generation_mode", must be one of WriteAllHtml, WriteOnlyBodyContent'
  end
  if @api_client.config.client_side_validation && opts[:'letters_positioning_method'] && !['UseEmUnitsAndCompensationOfRoundingErrorsInCss', 'UsePixelUnitsInCssLetterSpacingForIE'].include?(opts[:'letters_positioning_method'])
    fail ArgumentError, 'invalid value for "letters_positioning_method", must be one of UseEmUnitsAndCompensationOfRoundingErrorsInCss, UsePixelUnitsInCssLetterSpacingForIE'
  end
  if @api_client.config.client_side_validation && opts[:'parts_embedding_mode'] && !['EmbedAllIntoHtml', 'EmbedCssOnly', 'NoEmbedding'].include?(opts[:'parts_embedding_mode'])
    fail ArgumentError, 'invalid value for "parts_embedding_mode", must be one of EmbedAllIntoHtml, EmbedCssOnly, NoEmbedding'
  end
  if @api_client.config.client_side_validation && opts[:'raster_images_saving_mode'] && !['AsPngImagesEmbeddedIntoSvg', 'AsExternalPngFilesReferencedViaSvg', 'AsEmbeddedPartsOfPngPageBackground'].include?(opts[:'raster_images_saving_mode'])
    fail ArgumentError, 'invalid value for "raster_images_saving_mode", must be one of AsPngImagesEmbeddedIntoSvg, AsExternalPngFilesReferencedViaSvg, AsEmbeddedPartsOfPngPageBackground'
  end
  if @api_client.config.client_side_validation && opts[:'output_format'] && !['Zip', 'Folder'].include?(opts[:'output_format'])
    fail ArgumentError, 'invalid value for "output_format", must be one of Zip, Folder'
  end
  # resource path
  local_var_path = "/pdf/convert/html"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'additionalMarginWidthInPoints'] = opts[:'additional_margin_width_in_points'] if !opts[:'additional_margin_width_in_points'].nil?
  query_params[:'compressSvgGraphicsIfAny'] = opts[:'compress_svg_graphics_if_any'] if !opts[:'compress_svg_graphics_if_any'].nil?
  query_params[:'convertMarkedContentToLayers'] = opts[:'convert_marked_content_to_layers'] if !opts[:'convert_marked_content_to_layers'].nil?
  query_params[:'defaultFontName'] = opts[:'default_font_name'] if !opts[:'default_font_name'].nil?
  query_params[:'documentType'] = opts[:'document_type'] if !opts[:'document_type'].nil?
  query_params[:'fixedLayout'] = opts[:'fixed_layout'] if !opts[:'fixed_layout'].nil?
  query_params[:'imageResolution'] = opts[:'image_resolution'] if !opts[:'image_resolution'].nil?
  query_params[:'minimalLineWidth'] = opts[:'minimal_line_width'] if !opts[:'minimal_line_width'].nil?
  query_params[:'preventGlyphsGrouping'] = opts[:'prevent_glyphs_grouping'] if !opts[:'prevent_glyphs_grouping'].nil?
  query_params[:'splitCssIntoPages'] = opts[:'split_css_into_pages'] if !opts[:'split_css_into_pages'].nil?
  query_params[:'splitIntoPages'] = opts[:'split_into_pages'] if !opts[:'split_into_pages'].nil?
  query_params[:'useZOrder'] = opts[:'use_z_order'] if !opts[:'use_z_order'].nil?
  query_params[:'antialiasingProcessing'] = opts[:'antialiasing_processing'] if !opts[:'antialiasing_processing'].nil?
  query_params[:'cssClassNamesPrefix'] = opts[:'css_class_names_prefix'] if !opts[:'css_class_names_prefix'].nil?
  query_params[:'explicitListOfSavedPages'] = @api_client.build_collection_param(opts[:'explicit_list_of_saved_pages'], :csv) if !opts[:'explicit_list_of_saved_pages'].nil?
  query_params[:'fontEncodingStrategy'] = opts[:'font_encoding_strategy'] if !opts[:'font_encoding_strategy'].nil?
  query_params[:'fontSavingMode'] = opts[:'font_saving_mode'] if !opts[:'font_saving_mode'].nil?
  query_params[:'htmlMarkupGenerationMode'] = opts[:'html_markup_generation_mode'] if !opts[:'html_markup_generation_mode'].nil?
  query_params[:'lettersPositioningMethod'] = opts[:'letters_positioning_method'] if !opts[:'letters_positioning_method'].nil?
  query_params[:'pagesFlowTypeDependsOnViewersScreenSize'] = opts[:'pages_flow_type_depends_on_viewers_screen_size'] if !opts[:'pages_flow_type_depends_on_viewers_screen_size'].nil?
  query_params[:'partsEmbeddingMode'] = opts[:'parts_embedding_mode'] if !opts[:'parts_embedding_mode'].nil?
  query_params[:'rasterImagesSavingMode'] = opts[:'raster_images_saving_mode'] if !opts[:'raster_images_saving_mode'].nil?
  query_params[:'removeEmptyAreasOnTopAndBottom'] = opts[:'remove_empty_areas_on_top_and_bottom'] if !opts[:'remove_empty_areas_on_top_and_bottom'].nil?
  query_params[:'saveShadowedTextsAsTransparentTexts'] = opts[:'save_shadowed_texts_as_transparent_texts'] if !opts[:'save_shadowed_texts_as_transparent_texts'].nil?
  query_params[:'saveTransparentTexts'] = opts[:'save_transparent_texts'] if !opts[:'save_transparent_texts'].nil?
  query_params[:'specialFolderForAllImages'] = opts[:'special_folder_for_all_images'] if !opts[:'special_folder_for_all_images'].nil?
  query_params[:'specialFolderForSvgImages'] = opts[:'special_folder_for_svg_images'] if !opts[:'special_folder_for_svg_images'].nil?
  query_params[:'trySaveTextUnderliningAndStrikeoutingInCss'] = opts[:'try_save_text_underlining_and_strikeouting_in_css'] if !opts[:'try_save_text_underlining_and_strikeouting_in_css'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'flowLayoutParagraphFullWidth'] = opts[:'flow_layout_paragraph_full_width'] if !opts[:'flow_layout_paragraph_full_width'].nil?
  query_params[:'outputFormat'] = opts[:'output_format'] if !opts[:'output_format'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_html\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_mobi_xml(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to MOBIXML format and uploads resulting ZIP archive file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.mobixml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24073
def put_pdf_in_request_to_mobi_xml(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_mobi_xml_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_mobi_xml_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_mobi_xml_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to MOBIXML format and uploads resulting ZIP archive file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.mobixml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24093
def put_pdf_in_request_to_mobi_xml_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_mobi_xml ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_mobi_xml"
  end
  # resource path
  local_var_path = "/pdf/convert/mobixml"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_mobi_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_pdf_a(out_path, type, opts = {}) click to toggle source

Converts PDF document (in request content) to PdfA format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24148
def put_pdf_in_request_to_pdf_a(out_path, type, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_pdf_a_with_http_info(out_path, type, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_pdf_a_with_http_info(out_path, type, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_pdf_a_with_http_info(out_path, type, opts = {}) click to toggle source

Converts PDF document (in request content) to PdfA format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24169
def put_pdf_in_request_to_pdf_a_with_http_info(out_path, type, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_pdf_a ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_pdf_a"
  end
  # verify the required parameter 'type' is set
  if @api_client.config.client_side_validation && type.nil?
    fail ArgumentError, "Missing the required parameter 'type' when calling PdfApi.put_pdf_in_request_to_pdf_a"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['PDFA1A', 'PDFA1B', 'PDFA3A'].include?(type)
    fail ArgumentError, "invalid value for 'type', must be one of PDFA1A, PDFA1B, PDFA3A"
  end
  # resource path
  local_var_path = "/pdf/convert/pdfa"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'type'] = type
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_pdf_a\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_pptx(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to PPTX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pptx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24234
def put_pdf_in_request_to_pptx(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_pptx_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_pptx_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_pptx_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to PPTX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pptx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24256
def put_pdf_in_request_to_pptx_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_pptx ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_pptx"
  end
  # resource path
  local_var_path = "/pdf/convert/pptx"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'separateImages'] = opts[:'separate_images'] if !opts[:'separate_images'].nil?
  query_params[:'slidesAsImages'] = opts[:'slides_as_images'] if !opts[:'slides_as_images'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_pptx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_svg(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to SVG format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.svg) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24312
def put_pdf_in_request_to_svg(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_svg_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_svg_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_svg_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to SVG format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.svg) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24332
def put_pdf_in_request_to_svg_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_svg ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_svg"
  end
  # resource path
  local_var_path = "/pdf/convert/svg"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_svg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_te_x(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to TeX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24386
def put_pdf_in_request_to_te_x(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_te_x_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_te_x_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_te_x_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to TeX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.tex) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24406
def put_pdf_in_request_to_te_x_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_te_x ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_te_x"
  end
  # resource path
  local_var_path = "/pdf/convert/tex"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_te_x\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_tiff(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to TIFF format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.tiff) @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24475
def put_pdf_in_request_to_tiff(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_tiff_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_tiff_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_tiff_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to TIFF format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.tiff) @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24510
def put_pdf_in_request_to_tiff_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_tiff ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_tiff"
  end
  if @api_client.config.client_side_validation && opts[:'compression'] && !['LZW', 'CCITT4', 'CCITT3', 'RLE', 'None'].include?(opts[:'compression'])
    fail ArgumentError, 'invalid value for "compression", must be one of LZW, CCITT4, CCITT3, RLE, None'
  end
  if @api_client.config.client_side_validation && opts[:'color_depth'] && !['Default', 'Format8bpp', 'Format4bpp', 'Format1bpp'].include?(opts[:'color_depth'])
    fail ArgumentError, 'invalid value for "color_depth", must be one of Default, Format8bpp, Format4bpp, Format1bpp'
  end
  if @api_client.config.client_side_validation && opts[:'orientation'] && !['None', 'Landscape', 'Portrait'].include?(opts[:'orientation'])
    fail ArgumentError, 'invalid value for "orientation", must be one of None, Landscape, Portrait'
  end
  # resource path
  local_var_path = "/pdf/convert/tiff"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'brightness'] = opts[:'brightness'] if !opts[:'brightness'].nil?
  query_params[:'compression'] = opts[:'compression'] if !opts[:'compression'].nil?
  query_params[:'colorDepth'] = opts[:'color_depth'] if !opts[:'color_depth'].nil?
  query_params[:'leftMargin'] = opts[:'left_margin'] if !opts[:'left_margin'].nil?
  query_params[:'rightMargin'] = opts[:'right_margin'] if !opts[:'right_margin'].nil?
  query_params[:'topMargin'] = opts[:'top_margin'] if !opts[:'top_margin'].nil?
  query_params[:'bottomMargin'] = opts[:'bottom_margin'] if !opts[:'bottom_margin'].nil?
  query_params[:'orientation'] = opts[:'orientation'] if !opts[:'orientation'].nil?
  query_params[:'skipBlankPages'] = opts[:'skip_blank_pages'] if !opts[:'skip_blank_pages'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'xResolution'] = opts[:'x_resolution'] if !opts[:'x_resolution'].nil?
  query_params[:'yResolution'] = opts[:'y_resolution'] if !opts[:'y_resolution'].nil?
  query_params[:'pageIndex'] = opts[:'page_index'] if !opts[:'page_index'].nil?
  query_params[:'pageCount'] = opts[:'page_count'] if !opts[:'page_count'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_xls(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XLS format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xls) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24592
def put_pdf_in_request_to_xls(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_xls_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_xls_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_xls_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XLS format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xls) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24616
def put_pdf_in_request_to_xls_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_xls ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_xls"
  end
  # resource path
  local_var_path = "/pdf/convert/xls"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_xls\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_xlsx(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XLSX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xlsx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24678
def put_pdf_in_request_to_xlsx(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_xlsx_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_xlsx_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_xlsx_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XLSX format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xlsx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24702
def put_pdf_in_request_to_xlsx_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_xlsx ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_xlsx"
  end
  # resource path
  local_var_path = "/pdf/convert/xlsx"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_xlsx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_xml(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XML format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24760
def put_pdf_in_request_to_xml(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_xml_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_xml_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_xml_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XML format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xml) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24780
def put_pdf_in_request_to_xml_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_xml ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_xml"
  end
  # resource path
  local_var_path = "/pdf/convert/xml"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_request_to_xps(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XPS format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24834
def put_pdf_in_request_to_xps(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_request_to_xps_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_request_to_xps_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_request_to_xps_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document (in request content) to XPS format and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.xps) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24854
def put_pdf_in_request_to_xps_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_request_to_xps ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_request_to_xps"
  end
  # resource path
  local_var_path = "/pdf/convert/xps"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_request_to_xps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_doc(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to DOC format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24917
def put_pdf_in_storage_to_doc(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_doc_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_doc_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_doc_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to DOC format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.doc) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :add_return_to_line_end Add return to line end. @option opts [String] :format Allows to specify .doc or .docx file format. @option opts [Integer] :image_resolution_x Image resolution X. @option opts [Integer] :image_resolution_y Image resolution Y. @option opts [Float] :max_distance_between_text_lines Max distance between text lines. @option opts [String] :mode Allows to control how a PDF document is converted into a word processing document. @option opts [BOOLEAN] :recognize_bullets Recognize bullets. @option opts [Float] :relative_horizontal_proximity Relative horizontal proximity. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 24946
def put_pdf_in_storage_to_doc_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_doc ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_doc"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_doc"
  end
  if @api_client.config.client_side_validation && opts[:'format'] && !['Doc', 'DocX'].include?(opts[:'format'])
    fail ArgumentError, 'invalid value for "format", must be one of Doc, DocX'
  end
  if @api_client.config.client_side_validation && opts[:'mode'] && !['Textbox', 'Flow'].include?(opts[:'mode'])
    fail ArgumentError, 'invalid value for "mode", must be one of Textbox, Flow'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/doc".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'addReturnToLineEnd'] = opts[:'add_return_to_line_end'] if !opts[:'add_return_to_line_end'].nil?
  query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
  query_params[:'imageResolutionX'] = opts[:'image_resolution_x'] if !opts[:'image_resolution_x'].nil?
  query_params[:'imageResolutionY'] = opts[:'image_resolution_y'] if !opts[:'image_resolution_y'].nil?
  query_params[:'maxDistanceBetweenTextLines'] = opts[:'max_distance_between_text_lines'] if !opts[:'max_distance_between_text_lines'].nil?
  query_params[:'mode'] = opts[:'mode'] if !opts[:'mode'].nil?
  query_params[:'recognizeBullets'] = opts[:'recognize_bullets'] if !opts[:'recognize_bullets'].nil?
  query_params[:'relativeHorizontalProximity'] = opts[:'relative_horizontal_proximity'] if !opts[:'relative_horizontal_proximity'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_doc\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_epub(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to EPUB format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.epub) @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25019
def put_pdf_in_storage_to_epub(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_epub_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_epub_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_epub_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to EPUB format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.epub) @param [Hash] opts the optional parameters @option opts [String] :content_recognition_mode Property tunes conversion for this or that desirable method of recognition of content. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25041
def put_pdf_in_storage_to_epub_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_epub ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_epub"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_epub"
  end
  if @api_client.config.client_side_validation && opts[:'content_recognition_mode'] && !['Flow', 'PdfFlow', 'Fixed'].include?(opts[:'content_recognition_mode'])
    fail ArgumentError, 'invalid value for "content_recognition_mode", must be one of Flow, PdfFlow, Fixed'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/epub".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'contentRecognitionMode'] = opts[:'content_recognition_mode'] if !opts[:'content_recognition_mode'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_epub\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_html(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to Html format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.html) @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @option opts [String] :output_format This parameter determines the type of result. The zip archive will be uploaded into the storage if the parameter is "Zip&quot; or missed (default). In case of the "Folder&quot;, all resulting files and directories will be uploaded to the folder of the resulting HTML file. (default to Zip) @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25133
def put_pdf_in_storage_to_html(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_html_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_html_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_html_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to Html format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.html) @param [Hash] opts the optional parameters @option opts [Integer] :additional_margin_width_in_points Defines width of margin that will be forcibly left around that output HTML-areas. @option opts [BOOLEAN] :compress_svg_graphics_if_any The flag that indicates whether found SVG graphics(if any) will be compressed(zipped) into SVGZ format during saving. @option opts [BOOLEAN] :convert_marked_content_to_layers If attribute ConvertMarkedContentToLayers set to true then an all elements inside a PDF marked content (layer) will be put into an HTML div with "data-pdflayer&quot; attribute specifying a layer name. This layer name will be extracted from optional properties of PDF marked content. If this attribute is false (by default) then no any layers will be created from PDF marked content. @option opts [String] :default_font_name Specifies the name of an installed font which is used to substitute any document font that is not embedded and not installed in the system. If null then default substitution font is used. @option opts [String] :document_type Result document type. @option opts [BOOLEAN] :fixed_layout The value indicating whether that HTML is created as fixed layout. @option opts [Integer] :image_resolution Resolution for image rendering. @option opts [Integer] :minimal_line_width This attribute sets minimal width of graphic path line. If thickness of line is less than 1px Adobe Acrobat rounds it to this value. So this attribute can be used to emulate this behavior for HTML browsers. @option opts [BOOLEAN] :prevent_glyphs_grouping This attribute switch on the mode when text glyphs will not be grouped into words and strings This mode allows to keep maximum precision during positioning of glyphs on the page and it can be used for conversion documents with music notes or glyphs that should be placed separately each other. This parameter will be applied to document only when the value of FixedLayout attribute is true. @option opts [BOOLEAN] :split_css_into_pages When multipage-mode selected(i.e &#39;SplitIntoPages&#39; is &#39;true&#39;), then this attribute defines whether should be created separate CSS-file for each result HTML page. @option opts [BOOLEAN] :split_into_pages The flag that indicates whether each page of source document will be converted into it&#39;s own target HTML document, i.e whether result HTML will be splitted into several HTML-pages. @option opts [BOOLEAN] :use_z_order If attribute UseZORder set to true, graphics and text are added to resultant HTML document accordingly Z-order in original PDF document. If this attribute is false all graphics is put as single layer which may cause some unnecessary effects for overlapped objects. @option opts [String] :antialiasing_processing The parameter defines required antialiasing measures during conversion of compound background images from PDF to HTML. @option opts [String] :css_class_names_prefix When PDFtoHTML converter generates result CSSs, CSS class names (something like ".stl_01 {}&quot; … ".stl_NN {}) are generated and used in result CSS. This property allows forcibly set class name prefix. @option opts [Array<Integer>] :explicit_list_of_saved_pages With this property You can explicitely define what pages of document should be converted. Pages in this list must have 1-based numbers. I.e. valid numbers of pages must be taken from range (1…) Order of appearing of pages in this list does not affect their order in result HTML page(s) - in result pages allways will go in order in which they are present in source PDF. @option opts [String] :font_encoding_strategy Defines encoding special rule to tune PDF decoding for current document. @option opts [String] :font_saving_mode Defines font saving mode that will be used during saving of PDF to desirable format. @option opts [String] :html_markup_generation_mode Sometimes specific reqirments to generation of HTML markup are present. This parameter defines HTML preparing modes that can be used during conversion of PDF to HTML to match such specific requirments. @option opts [String] :letters_positioning_method The mode of positioning of letters in words in result HTML. @option opts [BOOLEAN] :pages_flow_type_depends_on_viewers_screen_size If attribute &#39;SplitOnPages&#x3D;false&#39;, than whole HTML representing all input PDF pages will be put into one big result HTML file. This flag defines whether result HTML will be generated in such way that flow of areas that represent PDF pages in result HTML will depend on screen resolution of viewer. @option opts [String] :parts_embedding_mode It defines whether referenced files (HTML, Fonts,Images, CSSes) will be embedded into main HTML file or will be generated as apart binary entities. @option opts [String] :raster_images_saving_mode Converted PDF can contain raster images This parameter defines how they should be handled during conversion of PDF to HTML. @option opts [BOOLEAN] :remove_empty_areas_on_top_and_bottom Defines whether in created HTML will be removed top and bottom empty area without any content (if any). @option opts [BOOLEAN] :save_shadowed_texts_as_transparent_texts Pdf can contain texts that are shadowed by another elements (f.e. by images) but can be selected to clipboard in Acrobat Reader (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML to mimic behaviour of Acrobat Reader (othervise such texts are usually saved as hidden, not available for copying to clipboard). @option opts [BOOLEAN] :save_transparent_texts Pdf can contain transparent texts that can be selected to clipboard (usually it happen when document contains images and OCRed texts extracted from it). This settings tells to converter whether we need save such texts as transparent selectable texts in result HTML. @option opts [String] :special_folder_for_all_images The path to directory to which must be saved any images if they are encountered during saving of document as HTML. If parameter is empty or null then image files(if any) wil be saved together with other files linked to HTML It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [String] :special_folder_for_svg_images The path to directory to which must be saved only SVG-images if they are encountered during saving of document as HTML. If parameter is empty or null then SVG files(if any) wil be saved together with other image-files (near to output file) or in special folder for images (if it specified in SpecialImagesFolderIfAny option). It does not affect anything if CustomImageSavingStrategy property was successfully used to process relevant image file. @option opts [BOOLEAN] :try_save_text_underlining_and_strikeouting_in_css PDF itself does not contain underlining markers for texts. It emulated with line situated under text. This option allows converter try guess that this or that line is a text&#39;s underlining and put this info into CSS instead of drawing of underlining graphically. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @option opts [BOOLEAN] :flow_layout_paragraph_full_width This attribute specifies full width paragraph text for Flow mode, FixedLayout &#x3D; false. @option opts [String] :output_format This parameter determines the type of result. The zip archive will be uploaded into the storage if the parameter is "Zip&quot; or missed (default). In case of the "Folder&quot;, all resulting files and directories will be uploaded to the folder of the resulting HTML file. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25184
def put_pdf_in_storage_to_html_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_html ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_html"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_html"
  end
  if @api_client.config.client_side_validation && opts[:'document_type'] && !['Xhtml', 'Html5'].include?(opts[:'document_type'])
    fail ArgumentError, 'invalid value for "document_type", must be one of Xhtml, Html5'
  end
  if @api_client.config.client_side_validation && opts[:'antialiasing_processing'] && !['NoAdditionalProcessing', 'TryCorrectResultHtml'].include?(opts[:'antialiasing_processing'])
    fail ArgumentError, 'invalid value for "antialiasing_processing", must be one of NoAdditionalProcessing, TryCorrectResultHtml'
  end
  if @api_client.config.client_side_validation && opts[:'font_encoding_strategy'] && !['Default', 'DecreaseToUnicodePriorityLevel'].include?(opts[:'font_encoding_strategy'])
    fail ArgumentError, 'invalid value for "font_encoding_strategy", must be one of Default, DecreaseToUnicodePriorityLevel'
  end
  if @api_client.config.client_side_validation && opts[:'font_saving_mode'] && !['AlwaysSaveAsWOFF', 'AlwaysSaveAsTTF', 'AlwaysSaveAsEOT', 'SaveInAllFormats'].include?(opts[:'font_saving_mode'])
    fail ArgumentError, 'invalid value for "font_saving_mode", must be one of AlwaysSaveAsWOFF, AlwaysSaveAsTTF, AlwaysSaveAsEOT, SaveInAllFormats'
  end
  if @api_client.config.client_side_validation && opts[:'html_markup_generation_mode'] && !['WriteAllHtml', 'WriteOnlyBodyContent'].include?(opts[:'html_markup_generation_mode'])
    fail ArgumentError, 'invalid value for "html_markup_generation_mode", must be one of WriteAllHtml, WriteOnlyBodyContent'
  end
  if @api_client.config.client_side_validation && opts[:'letters_positioning_method'] && !['UseEmUnitsAndCompensationOfRoundingErrorsInCss', 'UsePixelUnitsInCssLetterSpacingForIE'].include?(opts[:'letters_positioning_method'])
    fail ArgumentError, 'invalid value for "letters_positioning_method", must be one of UseEmUnitsAndCompensationOfRoundingErrorsInCss, UsePixelUnitsInCssLetterSpacingForIE'
  end
  if @api_client.config.client_side_validation && opts[:'parts_embedding_mode'] && !['EmbedAllIntoHtml', 'EmbedCssOnly', 'NoEmbedding'].include?(opts[:'parts_embedding_mode'])
    fail ArgumentError, 'invalid value for "parts_embedding_mode", must be one of EmbedAllIntoHtml, EmbedCssOnly, NoEmbedding'
  end
  if @api_client.config.client_side_validation && opts[:'raster_images_saving_mode'] && !['AsPngImagesEmbeddedIntoSvg', 'AsExternalPngFilesReferencedViaSvg', 'AsEmbeddedPartsOfPngPageBackground'].include?(opts[:'raster_images_saving_mode'])
    fail ArgumentError, 'invalid value for "raster_images_saving_mode", must be one of AsPngImagesEmbeddedIntoSvg, AsExternalPngFilesReferencedViaSvg, AsEmbeddedPartsOfPngPageBackground'
  end
  if @api_client.config.client_side_validation && opts[:'output_format'] && !['Zip', 'Folder'].include?(opts[:'output_format'])
    fail ArgumentError, 'invalid value for "output_format", must be one of Zip, Folder'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/html".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'additionalMarginWidthInPoints'] = opts[:'additional_margin_width_in_points'] if !opts[:'additional_margin_width_in_points'].nil?
  query_params[:'compressSvgGraphicsIfAny'] = opts[:'compress_svg_graphics_if_any'] if !opts[:'compress_svg_graphics_if_any'].nil?
  query_params[:'convertMarkedContentToLayers'] = opts[:'convert_marked_content_to_layers'] if !opts[:'convert_marked_content_to_layers'].nil?
  query_params[:'defaultFontName'] = opts[:'default_font_name'] if !opts[:'default_font_name'].nil?
  query_params[:'documentType'] = opts[:'document_type'] if !opts[:'document_type'].nil?
  query_params[:'fixedLayout'] = opts[:'fixed_layout'] if !opts[:'fixed_layout'].nil?
  query_params[:'imageResolution'] = opts[:'image_resolution'] if !opts[:'image_resolution'].nil?
  query_params[:'minimalLineWidth'] = opts[:'minimal_line_width'] if !opts[:'minimal_line_width'].nil?
  query_params[:'preventGlyphsGrouping'] = opts[:'prevent_glyphs_grouping'] if !opts[:'prevent_glyphs_grouping'].nil?
  query_params[:'splitCssIntoPages'] = opts[:'split_css_into_pages'] if !opts[:'split_css_into_pages'].nil?
  query_params[:'splitIntoPages'] = opts[:'split_into_pages'] if !opts[:'split_into_pages'].nil?
  query_params[:'useZOrder'] = opts[:'use_z_order'] if !opts[:'use_z_order'].nil?
  query_params[:'antialiasingProcessing'] = opts[:'antialiasing_processing'] if !opts[:'antialiasing_processing'].nil?
  query_params[:'cssClassNamesPrefix'] = opts[:'css_class_names_prefix'] if !opts[:'css_class_names_prefix'].nil?
  query_params[:'explicitListOfSavedPages'] = @api_client.build_collection_param(opts[:'explicit_list_of_saved_pages'], :csv) if !opts[:'explicit_list_of_saved_pages'].nil?
  query_params[:'fontEncodingStrategy'] = opts[:'font_encoding_strategy'] if !opts[:'font_encoding_strategy'].nil?
  query_params[:'fontSavingMode'] = opts[:'font_saving_mode'] if !opts[:'font_saving_mode'].nil?
  query_params[:'htmlMarkupGenerationMode'] = opts[:'html_markup_generation_mode'] if !opts[:'html_markup_generation_mode'].nil?
  query_params[:'lettersPositioningMethod'] = opts[:'letters_positioning_method'] if !opts[:'letters_positioning_method'].nil?
  query_params[:'pagesFlowTypeDependsOnViewersScreenSize'] = opts[:'pages_flow_type_depends_on_viewers_screen_size'] if !opts[:'pages_flow_type_depends_on_viewers_screen_size'].nil?
  query_params[:'partsEmbeddingMode'] = opts[:'parts_embedding_mode'] if !opts[:'parts_embedding_mode'].nil?
  query_params[:'rasterImagesSavingMode'] = opts[:'raster_images_saving_mode'] if !opts[:'raster_images_saving_mode'].nil?
  query_params[:'removeEmptyAreasOnTopAndBottom'] = opts[:'remove_empty_areas_on_top_and_bottom'] if !opts[:'remove_empty_areas_on_top_and_bottom'].nil?
  query_params[:'saveShadowedTextsAsTransparentTexts'] = opts[:'save_shadowed_texts_as_transparent_texts'] if !opts[:'save_shadowed_texts_as_transparent_texts'].nil?
  query_params[:'saveTransparentTexts'] = opts[:'save_transparent_texts'] if !opts[:'save_transparent_texts'].nil?
  query_params[:'specialFolderForAllImages'] = opts[:'special_folder_for_all_images'] if !opts[:'special_folder_for_all_images'].nil?
  query_params[:'specialFolderForSvgImages'] = opts[:'special_folder_for_svg_images'] if !opts[:'special_folder_for_svg_images'].nil?
  query_params[:'trySaveTextUnderliningAndStrikeoutingInCss'] = opts[:'try_save_text_underlining_and_strikeouting_in_css'] if !opts[:'try_save_text_underlining_and_strikeouting_in_css'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'flowLayoutParagraphFullWidth'] = opts[:'flow_layout_paragraph_full_width'] if !opts[:'flow_layout_paragraph_full_width'].nil?
  query_params[:'outputFormat'] = opts[:'output_format'] if !opts[:'output_format'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_html\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_mobi_xml(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to MOBIXML format and uploads resulting ZIP archive file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.mobixml) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25299
def put_pdf_in_storage_to_mobi_xml(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_mobi_xml_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_mobi_xml_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_mobi_xml_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to MOBIXML format and uploads resulting ZIP archive file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.mobixml) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25320
def put_pdf_in_storage_to_mobi_xml_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_mobi_xml ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_mobi_xml"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_mobi_xml"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/mobixml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_mobi_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_pdf_a(name, out_path, type, opts = {}) click to toggle source

Converts PDF document (located on storage) to PdfA format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25379
def put_pdf_in_storage_to_pdf_a(name, out_path, type, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_pdf_a_with_http_info(name, out_path, type, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_pdf_a_with_http_info(name, out_path, type, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_pdf_a_with_http_info(name, out_path, type, opts = {}) click to toggle source

Converts PDF document (located on storage) to PdfA format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param type Type of PdfA format. @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25401
def put_pdf_in_storage_to_pdf_a_with_http_info(name, out_path, type, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_pdf_a ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_pdf_a"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_pdf_a"
  end
  # verify the required parameter 'type' is set
  if @api_client.config.client_side_validation && type.nil?
    fail ArgumentError, "Missing the required parameter 'type' when calling PdfApi.put_pdf_in_storage_to_pdf_a"
  end
  # verify enum value
  if @api_client.config.client_side_validation && !['PDFA1A', 'PDFA1B', 'PDFA3A'].include?(type)
    fail ArgumentError, "invalid value for 'type', must be one of PDFA1A, PDFA1B, PDFA3A"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/pdfa".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'type'] = type
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_pdf_a\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_pptx(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to PPTX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pptx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25470
def put_pdf_in_storage_to_pptx(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_pptx_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_pptx_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_pptx_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to PPTX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pptx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :separate_images Separate images. @option opts [BOOLEAN] :slides_as_images Slides as images. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25493
def put_pdf_in_storage_to_pptx_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_pptx ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_pptx"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_pptx"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/pptx".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'separateImages'] = opts[:'separate_images'] if !opts[:'separate_images'].nil?
  query_params[:'slidesAsImages'] = opts[:'slides_as_images'] if !opts[:'slides_as_images'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_pptx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_svg(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to SVG format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.svg) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25553
def put_pdf_in_storage_to_svg(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_svg_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_svg_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_svg_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to SVG format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.svg) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25574
def put_pdf_in_storage_to_svg_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_svg ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_svg"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_svg"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/svg".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_svg\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_te_x(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to TeX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.tex) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25632
def put_pdf_in_storage_to_te_x(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_te_x_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_te_x_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_te_x_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to TeX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.tex) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25653
def put_pdf_in_storage_to_te_x_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_te_x ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_te_x"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_te_x"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/tex".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_te_x\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_tiff(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to TIFF format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.tiff) @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25726
def put_pdf_in_storage_to_tiff(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_tiff_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_tiff_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_tiff_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to TIFF format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.tiff) @param [Hash] opts the optional parameters @option opts [Float] :brightness Image brightness. @option opts [String] :compression Tiff compression. Possible values are: LZW, CCITT4, CCITT3, RLE, None. @option opts [String] :color_depth Image color depth. Possible valuse are: Default, Format8bpp, Format4bpp, Format1bpp. @option opts [Integer] :left_margin Left image margin. @option opts [Integer] :right_margin Right image margin. @option opts [Integer] :top_margin Top image margin. @option opts [Integer] :bottom_margin Bottom image margin. @option opts [String] :orientation Image orientation. Possible values are: None, Landscape, Portait. @option opts [BOOLEAN] :skip_blank_pages Skip blank pages flag. @option opts [Integer] :width Image width. @option opts [Integer] :height Image height. @option opts [Integer] :x_resolution Horizontal resolution. @option opts [Integer] :y_resolution Vertical resolution. @option opts [Integer] :page_index Start page to export. @option opts [Integer] :page_count Number of pages to export. @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25762
def put_pdf_in_storage_to_tiff_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_tiff ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_tiff"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_tiff"
  end
  if @api_client.config.client_side_validation && opts[:'compression'] && !['LZW', 'CCITT4', 'CCITT3', 'RLE', 'None'].include?(opts[:'compression'])
    fail ArgumentError, 'invalid value for "compression", must be one of LZW, CCITT4, CCITT3, RLE, None'
  end
  if @api_client.config.client_side_validation && opts[:'color_depth'] && !['Default', 'Format8bpp', 'Format4bpp', 'Format1bpp'].include?(opts[:'color_depth'])
    fail ArgumentError, 'invalid value for "color_depth", must be one of Default, Format8bpp, Format4bpp, Format1bpp'
  end
  if @api_client.config.client_side_validation && opts[:'orientation'] && !['None', 'Landscape', 'Portrait'].include?(opts[:'orientation'])
    fail ArgumentError, 'invalid value for "orientation", must be one of None, Landscape, Portrait'
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/tiff".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'brightness'] = opts[:'brightness'] if !opts[:'brightness'].nil?
  query_params[:'compression'] = opts[:'compression'] if !opts[:'compression'].nil?
  query_params[:'colorDepth'] = opts[:'color_depth'] if !opts[:'color_depth'].nil?
  query_params[:'leftMargin'] = opts[:'left_margin'] if !opts[:'left_margin'].nil?
  query_params[:'rightMargin'] = opts[:'right_margin'] if !opts[:'right_margin'].nil?
  query_params[:'topMargin'] = opts[:'top_margin'] if !opts[:'top_margin'].nil?
  query_params[:'bottomMargin'] = opts[:'bottom_margin'] if !opts[:'bottom_margin'].nil?
  query_params[:'orientation'] = opts[:'orientation'] if !opts[:'orientation'].nil?
  query_params[:'skipBlankPages'] = opts[:'skip_blank_pages'] if !opts[:'skip_blank_pages'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'xResolution'] = opts[:'x_resolution'] if !opts[:'x_resolution'].nil?
  query_params[:'yResolution'] = opts[:'y_resolution'] if !opts[:'y_resolution'].nil?
  query_params[:'pageIndex'] = opts[:'page_index'] if !opts[:'page_index'].nil?
  query_params[:'pageCount'] = opts[:'page_count'] if !opts[:'page_count'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_tiff\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_xls(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLS format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xls) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25848
def put_pdf_in_storage_to_xls(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLS format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xls) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25873
def put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_xls ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_xls"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_xls"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xls".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_xls\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_xlsx(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLSX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xlsx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25939
def put_pdf_in_storage_to_xlsx(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XLSX format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xlsx) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :insert_blank_column_at_first Insert blank column at first @option opts [BOOLEAN] :minimize_the_number_of_worksheets Minimize the number of worksheets @option opts [Float] :scale_factor Scale factor @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 25964
def put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_xlsx ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_xlsx"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_xlsx"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xlsx".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'insertBlankColumnAtFirst'] = opts[:'insert_blank_column_at_first'] if !opts[:'insert_blank_column_at_first'].nil?
  query_params[:'minimizeTheNumberOfWorksheets'] = opts[:'minimize_the_number_of_worksheets'] if !opts[:'minimize_the_number_of_worksheets'].nil?
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_xlsx\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_xml(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XML format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xml) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26026
def put_pdf_in_storage_to_xml(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_xml_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_xml_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_xml_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XML format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xml) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26047
def put_pdf_in_storage_to_xml_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_xml ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_xml"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_xml"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_xml\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_pdf_in_storage_to_xps(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XPS format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xps) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26105
def put_pdf_in_storage_to_xps(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_pdf_in_storage_to_xps_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_pdf_in_storage_to_xps_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_pdf_in_storage_to_xps_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document (located on storage) to XPS format and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.xps) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26126
def put_pdf_in_storage_to_xps_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_pdf_in_storage_to_xps ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_pdf_in_storage_to_xps"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_pdf_in_storage_to_xps"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_pdf_in_storage_to_xps\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_poly_line_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document polyline annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolyLineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26185
def put_poly_line_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_poly_line_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_poly_line_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_poly_line_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document polyline annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolyLineAnnotationResponse, Fixnum, Hash)>] PolyLineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26207
def put_poly_line_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_poly_line_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_poly_line_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_poly_line_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_poly_line_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polyline/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'PolyLineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_poly_line_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_polygon_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document polygon annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PolygonAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26268
def put_polygon_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_polygon_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_polygon_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_polygon_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document polygon annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PolygonAnnotationResponse, Fixnum, Hash)>] PolygonAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26290
def put_polygon_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_polygon_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_polygon_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_polygon_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_polygon_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/polygon/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'PolygonAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_polygon_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_popup_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document popup annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [PopupAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26351
def put_popup_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_popup_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_popup_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_popup_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document popup annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(PopupAnnotationResponse, Fixnum, Hash)>] PopupAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26373
def put_popup_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_popup_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_popup_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_popup_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_popup_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/popup/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'PopupAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_popup_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_privileges(name, privileges, opts = {}) click to toggle source

Update privilege document.

@param name The document name. @param privileges Document privileges. DocumentPrivilege @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26433
def put_privileges(name, privileges, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_privileges_with_http_info(name, privileges, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_privileges_with_http_info(name, privileges, opts)
    else
      raise
    end
  return data
end
put_privileges_with_http_info(name, privileges, opts = {}) click to toggle source

Update privilege document.

@param name The document name. @param privileges Document privileges. DocumentPrivilege @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26454
def put_privileges_with_http_info(name, privileges, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_privileges ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_privileges"
  end
  # verify the required parameter 'privileges' is set
  if @api_client.config.client_side_validation && privileges.nil?
    fail ArgumentError, "Missing the required parameter 'privileges' when calling PdfApi.put_privileges"
  end
  # resource path
  local_var_path = "/pdf/{name}/privileges".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(privileges)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_privileges\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_ps_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert PS file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.ps) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26510
def put_ps_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_ps_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_ps_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_ps_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert PS file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.ps) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26531
def put_ps_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_ps_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_ps_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_ps_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/ps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_ps_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_radio_button_field(name, field_name, field, opts = {}) click to toggle source

Replace document RadioButton field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [RadioButtonFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26590
def put_radio_button_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_radio_button_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_radio_button_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_radio_button_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document RadioButton field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(RadioButtonFieldResponse, Fixnum, Hash)>] RadioButtonFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26612
def put_radio_button_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_radio_button_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_radio_button_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_radio_button_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_radio_button_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/radiobutton/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'RadioButtonFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_radio_button_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_redaction_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document redaction annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [BOOLEAN] :apply Apply redaction immediately after adding. (default to false) @return [RedactionAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26674
def put_redaction_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_redaction_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_redaction_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_redaction_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document redaction annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [BOOLEAN] :apply Apply redaction immediately after adding. @return [Array<(RedactionAnnotationResponse, Fixnum, Hash)>] RedactionAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26697
def put_redaction_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_redaction_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_redaction_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_redaction_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_redaction_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/redaction/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'apply'] = opts[:'apply'] if !opts[:'apply'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'RedactionAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_redaction_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_replace_image(name, image_id, opts = {}) click to toggle source

Replace document image.

@param name The document name. @param image_id The image ID. @param [Hash] opts the optional parameters @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :image Image file. @return [ImageResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26760
def put_replace_image(name, image_id, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_replace_image_with_http_info(name, image_id, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_replace_image_with_http_info(name, image_id, opts)
    else
      raise
    end
  return data
end
put_replace_image_with_http_info(name, image_id, opts = {}) click to toggle source

Replace document image.

@param name The document name. @param image_id The image ID. @param [Hash] opts the optional parameters @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise. @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [File] :image Image file. @return [Array<(ImageResponse, Fixnum, Hash)>] ImageResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26783
def put_replace_image_with_http_info(name, image_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_replace_image ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_replace_image"
  end
  # verify the required parameter 'image_id' is set
  if @api_client.config.client_side_validation && image_id.nil?
    fail ArgumentError, "Missing the required parameter 'image_id' when calling PdfApi.put_replace_image"
  end
  # resource path
  local_var_path = "/pdf/{name}/images/{imageId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'imageId' + '}', image_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'imageFilePath'] = opts[:'image_file_path'] if !opts[:'image_file_path'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'image'] if !opts[:'image'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'ImageResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_replace_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_screen_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document screen annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [ScreenAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26844
def put_screen_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_screen_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_screen_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_screen_annotation_data_extract(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document screen annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26927
def put_screen_annotation_data_extract(name, annotation_id, out_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_screen_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_screen_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
    else
      raise
    end
  return data
end
put_screen_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document screen annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26949
def put_screen_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_screen_annotation_data_extract ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_screen_annotation_data_extract"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_screen_annotation_data_extract"
  end
  # verify the required parameter 'out_file_path' is set
  if @api_client.config.client_side_validation && out_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_file_path' when calling PdfApi.put_screen_annotation_data_extract"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/screen/{annotationId}/data/extract".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'outFilePath'] = out_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_screen_annotation_data_extract\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_screen_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document screen annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(ScreenAnnotationResponse, Fixnum, Hash)>] ScreenAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 26866
def put_screen_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_screen_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_screen_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_screen_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_screen_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/screen/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'ScreenAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_screen_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_searchable_document(name, opts = {}) click to toggle source

Create searchable PDF document. Generate OCR layer for images in input PDF document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :lang language for OCR engine. Possible values: eng, ara, bel, ben, bul, ces, dan, deu, ell, fin, fra, heb, hin, ind, isl, ita, jpn, kor, nld, nor, pol, por, ron, rus, spa, swe, tha, tur, ukr, vie, chi_sim, chi_tra or thier combination e.g. eng,rus @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27011
def put_searchable_document(name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_searchable_document_with_http_info(name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_searchable_document_with_http_info(name, opts)
    else
      raise
    end
  return data
end
put_searchable_document_with_http_info(name, opts = {}) click to toggle source

Create searchable PDF document. Generate OCR layer for images in input PDF document.

@param name The document name. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @option opts [String] :lang language for OCR engine. Possible values: eng, ara, bel, ben, bul, ces, dan, deu, ell, fin, fra, heb, hin, ind, isl, ita, jpn, kor, nld, nor, pol, por, ron, rus, spa, swe, tha, tur, ukr, vie, chi_sim, chi_tra or thier combination e.g. eng,rus @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27032
def put_searchable_document_with_http_info(name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_searchable_document ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_searchable_document"
  end
  # resource path
  local_var_path = "/pdf/{name}/ocr".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'lang'] = opts[:'lang'] if !opts[:'lang'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_searchable_document\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_set_property(name, property_name, value, opts = {}) click to toggle source

Add/update document property.

@param name @param property_name @param value @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [DocumentPropertyResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27087
def put_set_property(name, property_name, value, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_set_property_with_http_info(name, property_name, value, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_set_property_with_http_info(name, property_name, value, opts)
    else
      raise
    end
  return data
end
put_set_property_with_http_info(name, property_name, value, opts = {}) click to toggle source

Add/update document property.

@param name @param property_name @param value @param [Hash] opts the optional parameters @option opts [String] :storage @option opts [String] :folder @return [Array<(DocumentPropertyResponse, Fixnum, Hash)>] DocumentPropertyResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27109
def put_set_property_with_http_info(name, property_name, value, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_set_property ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_set_property"
  end
  # verify the required parameter 'property_name' is set
  if @api_client.config.client_side_validation && property_name.nil?
    fail ArgumentError, "Missing the required parameter 'property_name' when calling PdfApi.put_set_property"
  end
  # verify the required parameter 'value' is set
  if @api_client.config.client_side_validation && value.nil?
    fail ArgumentError, "Missing the required parameter 'value' when calling PdfApi.put_set_property"
  end
  # resource path
  local_var_path = "/pdf/{name}/documentproperties/{propertyName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'propertyName' + '}', property_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'value'] = value
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'DocumentPropertyResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_set_property\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_signature_field(name, field_name, field, opts = {}) click to toggle source

Replace document signature field.

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SignatureFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27172
def put_signature_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_signature_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_signature_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_signature_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document signature field.

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SignatureFieldResponse, Fixnum, Hash)>] SignatureFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27194
def put_signature_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_signature_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_signature_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_signature_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_signature_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/signature/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'SignatureFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_signature_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_sound_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document sound annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SoundAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27255
def put_sound_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_sound_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_sound_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_sound_annotation_data_extract(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document sound annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27338
def put_sound_annotation_data_extract(name, annotation_id, out_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_sound_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_sound_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
    else
      raise
    end
  return data
end
put_sound_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document sound annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27360
def put_sound_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_sound_annotation_data_extract ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_sound_annotation_data_extract"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_sound_annotation_data_extract"
  end
  # verify the required parameter 'out_file_path' is set
  if @api_client.config.client_side_validation && out_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_file_path' when calling PdfApi.put_sound_annotation_data_extract"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/sound/{annotationId}/data/extract".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'outFilePath'] = out_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_sound_annotation_data_extract\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_sound_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document sound annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SoundAnnotationResponse, Fixnum, Hash)>] SoundAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27277
def put_sound_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_sound_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_sound_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_sound_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_sound_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/sound/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'SoundAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_sound_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_square_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document square annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquareAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27423
def put_square_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_square_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_square_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_square_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document square annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquareAnnotationResponse, Fixnum, Hash)>] SquareAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27445
def put_square_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_square_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_square_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_square_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_square_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/square/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'SquareAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_square_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_squiggly_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document squiggly annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [SquigglyAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27506
def put_squiggly_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_squiggly_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_squiggly_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_squiggly_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document squiggly annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(SquigglyAnnotationResponse, Fixnum, Hash)>] SquigglyAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27528
def put_squiggly_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_squiggly_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_squiggly_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_squiggly_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_squiggly_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/squiggly/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'SquigglyAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_squiggly_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_stamp_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document stamp annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StampAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27589
def put_stamp_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_stamp_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_stamp_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_stamp_annotation_data_extract(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document stamp annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27672
def put_stamp_annotation_data_extract(name, annotation_id, out_file_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_stamp_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_stamp_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts)
    else
      raise
    end
  return data
end
put_stamp_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {}) click to toggle source

Extract document stamp annotation content to storage

@param name The document name. @param annotation_id The annotation ID. @param out_file_path The output file path. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27694
def put_stamp_annotation_data_extract_with_http_info(name, annotation_id, out_file_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_stamp_annotation_data_extract ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_stamp_annotation_data_extract"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_stamp_annotation_data_extract"
  end
  # verify the required parameter 'out_file_path' is set
  if @api_client.config.client_side_validation && out_file_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_file_path' when calling PdfApi.put_stamp_annotation_data_extract"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/stamp/{annotationId}/data/extract".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'outFilePath'] = out_file_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_stamp_annotation_data_extract\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_stamp_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document stamp annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StampAnnotationResponse, Fixnum, Hash)>] StampAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27611
def put_stamp_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_stamp_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_stamp_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_stamp_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_stamp_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/stamp/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'StampAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_stamp_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_strike_out_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document StrikeOut annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [StrikeOutAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27757
def put_strike_out_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_strike_out_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_strike_out_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_strike_out_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document StrikeOut annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(StrikeOutAnnotationResponse, Fixnum, Hash)>] StrikeOutAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27779
def put_strike_out_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_strike_out_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_strike_out_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_strike_out_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_strike_out_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/strikeout/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'StrikeOutAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_strike_out_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_svg_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert SVG file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.svg) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :adjust_page_size Adjust page size @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27847
def put_svg_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_svg_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_svg_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_svg_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert SVG file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.svg) @param [Hash] opts the optional parameters @option opts [BOOLEAN] :adjust_page_size Adjust page size @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27876
def put_svg_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_svg_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_svg_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_svg_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/svg".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'adjustPageSize'] = opts[:'adjust_page_size'] if !opts[:'adjust_page_size'].nil?
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_svg_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_table(name, table_id, table, opts = {}) click to toggle source

Replace document page table.

@param name The document name. @param table_id The table ID. @param table The table. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27943
def put_table(name, table_id, table, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_table_with_http_info(name, table_id, table, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_table_with_http_info(name, table_id, table, opts)
    else
      raise
    end
  return data
end
put_table_with_http_info(name, table_id, table, opts = {}) click to toggle source

Replace document page table.

@param name The document name. @param table_id The table ID. @param table The table. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 27965
def put_table_with_http_info(name, table_id, table, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_table ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_table"
  end
  # verify the required parameter 'table_id' is set
  if @api_client.config.client_side_validation && table_id.nil?
    fail ArgumentError, "Missing the required parameter 'table_id' when calling PdfApi.put_table"
  end
  # verify the required parameter 'table' is set
  if @api_client.config.client_side_validation && table.nil?
    fail ArgumentError, "Missing the required parameter 'table' when calling PdfApi.put_table"
  end
  # resource path
  local_var_path = "/pdf/{name}/tables/{tableId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'tableId' + '}', table_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(table)
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_table\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_te_x_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28025
def put_te_x_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert TeX file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.tex) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28046
def put_te_x_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_te_x_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_te_x_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_te_x_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/tex".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_te_x_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_text_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document text annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28105
def put_text_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_text_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_text_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_text_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document text annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextAnnotationResponse, Fixnum, Hash)>] TextAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28127
def put_text_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_text_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_text_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_text_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_text_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/text/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'TextAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_text_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_text_box_field(name, field_name, field, opts = {}) click to toggle source

Replace document text box field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [TextBoxFieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28188
def put_text_box_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_text_box_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_text_box_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_text_box_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Replace document text box field

@param name The document name. @param field_name The field name. @param field The field. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(TextBoxFieldResponse, Fixnum, Hash)>] TextBoxFieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28210
def put_text_box_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_text_box_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_text_box_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_text_box_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_text_box_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/textbox/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'TextBoxFieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_text_box_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_underline_annotation(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document underline annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [UnderlineAnnotationResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28271
def put_underline_annotation(name, annotation_id, annotation, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_underline_annotation_with_http_info(name, annotation_id, annotation, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_underline_annotation_with_http_info(name, annotation_id, annotation, opts)
    else
      raise
    end
  return data
end
put_underline_annotation_with_http_info(name, annotation_id, annotation, opts = {}) click to toggle source

Replace document underline annotation

@param name The document name. @param annotation_id The annotation ID. @param annotation Annotation. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(UnderlineAnnotationResponse, Fixnum, Hash)>] UnderlineAnnotationResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28293
def put_underline_annotation_with_http_info(name, annotation_id, annotation, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_underline_annotation ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_underline_annotation"
  end
  # verify the required parameter 'annotation_id' is set
  if @api_client.config.client_side_validation && annotation_id.nil?
    fail ArgumentError, "Missing the required parameter 'annotation_id' when calling PdfApi.put_underline_annotation"
  end
  # verify the required parameter 'annotation' is set
  if @api_client.config.client_side_validation && annotation.nil?
    fail ArgumentError, "Missing the required parameter 'annotation' when calling PdfApi.put_underline_annotation"
  end
  # resource path
  local_var_path = "/pdf/{name}/annotations/underline/{annotationId}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'annotationId' + '}', annotation_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(annotation)
  auth_names = ['JWT']
  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 => 'UnderlineAnnotationResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_underline_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_update_field(name, field_name, field, opts = {}) click to toggle source

Update field.

@param name The document name. @param field_name The name of a field to be updated. @param field Field with the field data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FieldResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28354
def put_update_field(name, field_name, field, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_update_field_with_http_info(name, field_name, field, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_update_field_with_http_info(name, field_name, field, opts)
    else
      raise
    end
  return data
end
put_update_field_with_http_info(name, field_name, field, opts = {}) click to toggle source

Update field.

@param name The document name. @param field_name The name of a field to be updated. @param field Field with the field data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FieldResponse, Fixnum, Hash)>] FieldResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28376
def put_update_field_with_http_info(name, field_name, field, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_update_field ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_update_field"
  end
  # verify the required parameter 'field_name' is set
  if @api_client.config.client_side_validation && field_name.nil?
    fail ArgumentError, "Missing the required parameter 'field_name' when calling PdfApi.put_update_field"
  end
  # verify the required parameter 'field' is set
  if @api_client.config.client_side_validation && field.nil?
    fail ArgumentError, "Missing the required parameter 'field' when calling PdfApi.put_update_field"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields/{fieldName}".sub('{' + 'name' + '}', name.to_s).sub('{' + 'fieldName' + '}', field_name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(field)
  auth_names = ['JWT']
  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 => 'FieldResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_update_field\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_update_fields(name, fields, opts = {}) click to toggle source

Update fields.

@param name The document name. @param fields Fields with the fields data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [FieldsResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28436
def put_update_fields(name, fields, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_update_fields_with_http_info(name, fields, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_update_fields_with_http_info(name, fields, opts)
    else
      raise
    end
  return data
end
put_update_fields_with_http_info(name, fields, opts = {}) click to toggle source

Update fields.

@param name The document name. @param fields Fields with the fields data. @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [String] :folder The document folder. @return [Array<(FieldsResponse, Fixnum, Hash)>] FieldsResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28457
def put_update_fields_with_http_info(name, fields, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_update_fields ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_update_fields"
  end
  # verify the required parameter 'fields' is set
  if @api_client.config.client_side_validation && fields.nil?
    fail ArgumentError, "Missing the required parameter 'fields' when calling PdfApi.put_update_fields"
  end
  # resource path
  local_var_path = "/pdf/{name}/fields".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
  query_params[:'folder'] = opts[:'folder'] if !opts[:'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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  post_body = @api_client.object_to_http_body(fields)
  auth_names = ['JWT']
  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 => 'FieldsResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_update_fields\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_web_in_storage_to_pdf(name, url, opts = {}) click to toggle source

Convert web page to PDF format and upload resulting file to storage.

@param name The document name. @param url Source url @param [Hash] opts the optional parameters @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28520
def put_web_in_storage_to_pdf(name, url, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_web_in_storage_to_pdf_with_http_info(name, url, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_web_in_storage_to_pdf_with_http_info(name, url, opts)
    else
      raise
    end
  return data
end
put_web_in_storage_to_pdf_with_http_info(name, url, opts = {}) click to toggle source

Convert web page to PDF format and upload resulting file to storage.

@param name The document name. @param url Source url @param [Hash] opts the optional parameters @option opts [Float] :height Page height @option opts [Float] :width Page width @option opts [BOOLEAN] :is_landscape Is page landscaped @option opts [Float] :margin_left Page margin left @option opts [Float] :margin_bottom Page margin bottom @option opts [Float] :margin_right Page margin right @option opts [Float] :margin_top Page margin top @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28548
def put_web_in_storage_to_pdf_with_http_info(name, url, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_web_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_web_in_storage_to_pdf"
  end
  # verify the required parameter 'url' is set
  if @api_client.config.client_side_validation && url.nil?
    fail ArgumentError, "Missing the required parameter 'url' when calling PdfApi.put_web_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/web".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'url'] = url
  query_params[:'height'] = opts[:'height'] if !opts[:'height'].nil?
  query_params[:'width'] = opts[:'width'] if !opts[:'width'].nil?
  query_params[:'isLandscape'] = opts[:'is_landscape'] if !opts[:'is_landscape'].nil?
  query_params[:'marginLeft'] = opts[:'margin_left'] if !opts[:'margin_left'].nil?
  query_params[:'marginBottom'] = opts[:'margin_bottom'] if !opts[:'margin_bottom'].nil?
  query_params[:'marginRight'] = opts[:'margin_right'] if !opts[:'margin_right'].nil?
  query_params[:'marginTop'] = opts[:'margin_top'] if !opts[:'margin_top'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_web_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_xfa_pdf_in_request_to_acro_form(out_path, opts = {}) click to toggle source

Converts PDF document which contains XFA form (in request content) to PDF with AcroForm and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28612
def put_xfa_pdf_in_request_to_acro_form(out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_xfa_pdf_in_request_to_acro_form_with_http_info(out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_xfa_pdf_in_request_to_acro_form_with_http_info(out_path, opts)
    else
      raise
    end
  return data
end
put_xfa_pdf_in_request_to_acro_form_with_http_info(out_path, opts = {}) click to toggle source

Converts PDF document which contains XFA form (in request content) to PDF with AcroForm and uploads resulting file to storage.

@param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param [Hash] opts the optional parameters @option opts [String] :storage The document storage. @option opts [File] :file A file to be converted. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28632
def put_xfa_pdf_in_request_to_acro_form_with_http_info(out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_xfa_pdf_in_request_to_acro_form ..."
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_xfa_pdf_in_request_to_acro_form"
  end
  # resource path
  local_var_path = "/pdf/convert/xfatoacroform"

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  post_body =  opts[:'file'] if !opts[:'file'].nil?
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_xfa_pdf_in_request_to_acro_form\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_xfa_pdf_in_storage_to_acro_form(name, out_path, opts = {}) click to toggle source

Converts PDF document which contains XFA form (located on storage) to PDF with AcroForm and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28687
def put_xfa_pdf_in_storage_to_acro_form(name, out_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_xfa_pdf_in_storage_to_acro_form_with_http_info(name, out_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_xfa_pdf_in_storage_to_acro_form_with_http_info(name, out_path, opts)
    else
      raise
    end
  return data
end
put_xfa_pdf_in_storage_to_acro_form_with_http_info(name, out_path, opts = {}) click to toggle source

Converts PDF document which contains XFA form (located on storage) to PDF with AcroForm and uploads resulting file to storage

@param name The document name. @param out_path Full resulting filename (ex. /folder1/folder2/result.pdf) @param [Hash] opts the optional parameters @option opts [String] :folder The document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28708
def put_xfa_pdf_in_storage_to_acro_form_with_http_info(name, out_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_xfa_pdf_in_storage_to_acro_form ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_xfa_pdf_in_storage_to_acro_form"
  end
  # verify the required parameter 'out_path' is set
  if @api_client.config.client_side_validation && out_path.nil?
    fail ArgumentError, "Missing the required parameter 'out_path' when calling PdfApi.put_xfa_pdf_in_storage_to_acro_form"
  end
  # resource path
  local_var_path = "/pdf/{name}/convert/xfatoacroform".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'outPath'] = out_path
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_xfa_pdf_in_storage_to_acro_form\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_xml_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert XML file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :xsl_file_path Full XSL source filename (ex. /folder1/folder2/template.xsl) @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28767
def put_xml_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_xml_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_xml_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_xml_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert XML file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xml) @param [Hash] opts the optional parameters @option opts [String] :xsl_file_path Full XSL source filename (ex. /folder1/folder2/template.xsl) @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28789
def put_xml_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_xml_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_xml_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_xml_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/xml".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'xslFilePath'] = opts[:'xsl_file_path'] if !opts[:'xsl_file_path'].nil?
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_xml_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_xps_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert XPS file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xps) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28848
def put_xps_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_xps_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_xps_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_xps_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert XPS file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xps) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28869
def put_xps_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_xps_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_xps_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_xps_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/xps".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_xps_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
put_xsl_fo_in_storage_to_pdf(name, src_path, opts = {}) click to toggle source

Convert XslFo file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xpsfo) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [AsposeResponse]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28927
def put_xsl_fo_in_storage_to_pdf(name, src_path, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = put_xsl_fo_in_storage_to_pdf_with_http_info(name, src_path, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = put_xsl_fo_in_storage_to_pdf_with_http_info(name, src_path, opts)
    else
      raise
    end
  return data
end
put_xsl_fo_in_storage_to_pdf_with_http_info(name, src_path, opts = {}) click to toggle source

Convert XslFo file (located on storage) to PDF format and upload resulting file to storage.

@param name The document name. @param src_path Full source filename (ex. /folder1/folder2/template.xpsfo) @param [Hash] opts the optional parameters @option opts [String] :dst_folder The destination document folder. @option opts [String] :storage The document storage. @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 28948
def put_xsl_fo_in_storage_to_pdf_with_http_info(name, src_path, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.put_xsl_fo_in_storage_to_pdf ..."
  end
  # verify the required parameter 'name' is set
  if @api_client.config.client_side_validation && name.nil?
    fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_xsl_fo_in_storage_to_pdf"
  end
  # verify the required parameter 'src_path' is set
  if @api_client.config.client_side_validation && src_path.nil?
    fail ArgumentError, "Missing the required parameter 'src_path' when calling PdfApi.put_xsl_fo_in_storage_to_pdf"
  end
  # resource path
  local_var_path = "/pdf/{name}/create/xslfo".sub('{' + 'name' + '}', name.to_s)

  # query parameters
  query_params = {}
  query_params[:'srcPath'] = src_path
  query_params[:'dstFolder'] = opts[:'dst_folder'] if !opts[:'dst_folder'].nil?
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].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 = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'AsposeResponse')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#put_xsl_fo_in_storage_to_pdf\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
storage_exists(storage_name, opts = {}) click to toggle source

Check if storage exists

@param storage_name Storage name @param [Hash] opts the optional parameters @return [StorageExist]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 29003
def storage_exists(storage_name, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = storage_exists_with_http_info(storage_name, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = storage_exists_with_http_info(storage_name, opts)
    else
      raise
    end
  return data
end
storage_exists_with_http_info(storage_name, opts = {}) click to toggle source

Check if storage exists

@param storage_name Storage name @param [Hash] opts the optional parameters @return [Array<(StorageExist, Fixnum, Hash)>] StorageExist data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 29021
def storage_exists_with_http_info(storage_name, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.storage_exists ..."
  end
  # verify the required parameter 'storage_name' is set
  if @api_client.config.client_side_validation && storage_name.nil?
    fail ArgumentError, "Missing the required parameter 'storage_name' when calling PdfApi.storage_exists"
  end
  # resource path
  local_var_path = "/pdf/storage/{storageName}/exist".sub('{' + 'storageName' + '}', storage_name.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'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'StorageExist')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#storage_exists\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
upload_file(path, file, opts = {}) click to toggle source

Upload file

@param path Path where to upload including filename and extension e.g. /file.ext or /Folder 1/file.ext If the content is multipart and path does not contains the file name it tries to get them from filename parameter from Content-Disposition header.

@param file File to upload @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [FilesUploadResult]

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 29071
def upload_file(path, file, opts = {})
  @api_client.request_token_if_needed
  data, _status_code, _headers = upload_file_with_http_info(path, file, opts)
  rescue ApiError => error
    if error.code == 401
      @api_client.request_token_if_needed
      data, _status_code, _headers = upload_file_with_http_info(path, file, opts)
    else
      raise
    end
  return data
end
upload_file_with_http_info(path, file, opts = {}) click to toggle source

Upload file

@param path Path where to upload including filename and extension e.g. /file.ext or /Folder 1/file.ext If the content is multipart and path does not contains the file name it tries to get them from filename parameter from Content-Disposition header.

@param file File to upload @param [Hash] opts the optional parameters @option opts [String] :storage_name Storage name @return [Array<(FilesUploadResult, Fixnum, Hash)>] FilesUploadResult data, response status code and response headers

# File lib/aspose_pdf_cloud/api/pdf_api.rb, line 29091
def upload_file_with_http_info(path, file, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: PdfApi.upload_file ..."
  end
  # verify the required parameter 'path' is set
  if @api_client.config.client_side_validation && path.nil?
    fail ArgumentError, "Missing the required parameter 'path' when calling PdfApi.upload_file"
  end
  # verify the required parameter 'file' is set
  if @api_client.config.client_side_validation && file.nil?
    fail ArgumentError, "Missing the required parameter 'file' when calling PdfApi.upload_file"
  end
  # resource path
  local_var_path = "/pdf/storage/file/{path}".sub('{' + 'path' + '}', path.to_s)

  # query parameters
  query_params = {}
  query_params[:'storageName'] = opts[:'storage_name'] if !opts[:'storage_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(['multipart/form-data'])

  # form parameters
  form_params = {}
  # Fix header in file
  post_body = nil
  # Fix header in file
  post_body = file
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])

  # http body (model)
  # Fix header in file
  # post_body = nil
  auth_names = ['JWT']
  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 => 'FilesUploadResult')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: PdfApi#upload_file\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end