Options Objects

Page contains description for option objects and object fields.

DocumentInfoOptions

Provides options for retrieving attachment information.

Example DocumentInfoOptions object

{
  "password": "document password",
  "attachmentPassword": "attachment password",
  "extractText": false,
  "renderComments": false,
  "renderHiddenPages": false,
  "defaultFontName": "font name",
  "transforms": [
    "Rotate",
	"Reorder",
	"AddPrintAction"
  ],
  "watermark": {
    "text": "watermark text",
    "color": "Magenta",
    "position": "Diagonal",
    "size": 50
  },
  "cellsOptions": {
    "renderGridLines": false,
    "paginateSheets": false,
    "encoding": "utf-8",
    "internalHyperlinkPrefix": "prefix",
    "countRowsPerPage": 50,
    "textOverflowMode": "OverlayIfNextIsEmpty",
	"ignoreEmptyRows": false
  },
  "cadOptions": {
    "scaleFactor": 50,
    "width": 600,
    "height": 800,
    "renderLayouts": true,
    "layoutName": "Master",
	"layers": ["Layer1"]
  },
  "emailOptions": {
    "encoding": "utf-8"
  },
  "wordsOptions": {
    "encoding": "utf-8",
    "renderTrackedChanges": false
  },
  "pdfOptions": {
    "enablePreciseRendering": false,
    "enableInitialContentOrdering": false,
    "renderLayersSeparately": false
  },
  "slidesOptions": {
    "renderNotes": false
  },
  "projectOptions": {
    "pageSize": "unknown",
    "pageSize": "unknown"
  }
}

Info Object Fields (Click here to expand)

NameTypeDescription
PasswordstringAllows to specify document password in case when document is password-protected.
AttachmentPasswordstringAllows to specify attachment password in case when attachment is password-protected.
ExtractTextboolEnables document text extraction. For rendering document as image only.
RenderCommentsboolEnables document comments rendering.
RenderHiddenPagesboolEnables document hidden pages, sheets or slides rendering.
DefaultFontNamestringThe name of the default font. Default font name may be specified in following cases: You want to generally specify the default font to fall back on, if particular font in the document cannot be found during rendering. Your document uses fonts, that contain non-English characters and you want to make sure any missing font is replaced with one that has the same character set available.
Transformsstring[]Transforms to apply. Available transforms [“Rotate”,“Reorder”,“AddPrintAction”]. Rotate - Pages will be rotated on angle if angle was set before. Reorder - For rendering document as PDF only. Pages will be ordered according to rearrangements made before.AddPrintAction - For rendering document as PDF only. An JavaScript action will be added which opens print dialog when PDF document is opened.
WatermarkWatermark ObjectAllows to specify watermark.
CellsOptionsCellsOptions ObjectThe Spreadsheet documents rendering options.
CadOptionsCadOptions ObjectThe CAD documents rendering options.
EmailOptionsEmailOptions ObjectThe Email documents rendering options.
WordsOptionsWordsOptions ObjectThe Text documents rendering options.
PdfOptionsPdfOptions ObjectThe PDF documents rendering options.
SlidesOptionsSlidesOptions ObjectThe Presentation documents rendering options.
ProjectOptionsProjectOptions ObjectThe Microsoft Project documents rendering options.

ImageOptions

Provides options for rendering document as image.

Example ImageOptions object

{
  "format": "png",
  "quality": 90,
  "width": 0,
  "height": 0,
  "startPageNumber": 0,
  "countPages": 0,
  "password": "string",
  "attachmentPassword": "string",
  "extractText": false,
  "renderComments": false,
  "renderHiddenPages": false,	
  "defaultFontName": "string",
  "transforms": [
    "Rotate",
	"Reorder",
	"AddPrintAction"
  ],
  "watermark": {
    "text": "watermark text,
    "color": "Magenta",
    "position": "Diagonal",
    "size": 50
  },
  "cellsOptions": {
    "renderGridLines": false,
    "paginateSheets": false,
    "encoding": "utf-8",
    "internalHyperlinkPrefix": "prefix",
    "countRowsPerPage": 50,
    "textOverflowMode": "OverlayIfNextIsEmpty",
	"ignoreEmptyRows": false
  },
  "cadOptions": {
    "scaleFactor": 50,
    "width": 600,
    "height": 800,
    "renderLayouts": true,
    "layoutName": "Master",
	"layers": ["Layer1"]
  },
  "emailOptions": {
    "encoding": "utf-8"
  },
  "wordsOptions": {
    "encoding": "utf-8",
    "renderTrackedChanges": false
  },
  "pdfOptions": {
    "enablePreciseRendering": false,
    "enableInitialContentOrdering": false,
    "renderLayersSeparately": false
  },
  "slidesOptions": {
    "renderNotes": false
  },
  "projectOptions": {
    "pageSize": "unknown",
    "pageSize": "unknown"
  }
}

ImageOptions Object Fields

NameTypeDescription
FormatstringAllows to set image format (“png” or “jpg”). Default value is “png”.
QualityintAllows to specify quality when format # “jpg”. Valid values are between 1 and 100. Default value is 90.
WidthintAllows to specify output image width. Specify image width in case when you want to change output image dimensions. When Width has value and Height value is 0 then Height value will be calculated to save image proportions.
HeightintAllows to specify output image height. Specify image height in case when you want to change output image dimensions. When Height has value and Width value is 0 then Width value will be calculated to save image proportions.
PasswordstringAllows to specify document password in case when document is password-protected.
AttachmentPasswordstringAllows to specify attachment password in case when attachment is password-protected.
ExtractTextboolEnables document text extraction. For rendering document as image only.
RenderCommentsboolEnables document comments rendering.
DefaultFontNamestringThe name of the default font.
Transformsstring[]Transforms to apply. Available transforms [“Rotate”,“Reorder”,“AddPrintAction”].
WatermarkWatermark ObjectAllows to specify watermark.
CellsOptionsCellsOptions ObjectThe Spreadsheet documents rendering options.
CadOptionsCadOptions ObjectThe CAD documents rendering options.
EmailOptionsEmailOptions ObjectThe Email documents rendering options.
WordsOptionsWordsOptions ObjectThe Text documents rendering options.
PdfOptionsPdfOptions ObjectThe PDF documents rendering options.
SlidesOptionsSlidesOptions ObjectThe Presentation documents rendering options.
ProjectOptionsProjectOptions ObjectThe Microsoft Project documents rendering options.

HtmlOptions

Provides options for rendering document pages as HTML.

Example HtmlOptions object

{
  "resourcePath": "string",
  "ignoreResourcePathInResources": false
  "embedResources": false,
  "enableMinification": false,
  "enableResponsiveRendering": false,
  "excludeFonts": false,
  "excludeFontsList": ["Arial", "Calibri"],
  "startPageNumber": 0,
  "countPages": 0,
  "password": "document password",
  "attachmentPassword": "attachment password",
  "extractText": false,
  "renderComments": false,
  "defaultFontName": "string",
  "transforms": [
    "Rotate",
	"Reorder",
	"AddPrintAction"
  ],
  "watermark": {
    "text": "watermark text",
    "color": "Magenta",
    "position": "Diagonal",
    "size": 50
  },
  "cellsOptions": {
    "renderGridLines": false,
    "paginateSheets": false,
    "encoding": "utf-8",
    "internalHyperlinkPrefix": "prefix",
    "countRowsPerPage": 50,
    "textOverflowMode": "OverlayIfNextIsEmpty",
	"ignoreEmptyRows": false,
	"renderHiddenRows": false,
	"renderHiddenColumns": false,
	"renderPrintAreaOnly": false
  },
  "cadOptions": {
    "scaleFactor": 50,
    "width": 600,
    "height": 800,
    "renderLayouts": true,
    "layoutName": "Master",
	"layers": ["Layer1"]
  },
  "emailOptions": {
    "encoding": "utf-8"
  },
  "wordsOptions": {
    "encoding": "utf-8",
    "renderTrackedChanges": false
  },
  "pdfOptions": {
    "enablePreciseRendering": false,
    "enableInitialContentOrdering": false,
    "renderLayersSeparately": false,
	"imageQuality": "Low"
  },
  "slidesOptions": {
    "renderNotes": false
  },
  "projectOptions": {
    "pageSize": "unknown",
    "pageSize": "unknown"
  }
}

HtmlOptions Fields

NameTypeDescription
ResourcePathstringAllows to specify HTML resources (styles, images and fonts) path. For example when resource path is http://example.com/api/pages/{page-number}/resources/{resource-name} the {page-number} and {resource-name} templates will be replaced with page number and resource name accordingly. Ignored when EmbedResources option is set to true.
IgnoreResourcePathInResourcesboolAllows to ignore ResourcePath when processing *.css and *.svg files. When this options is enabled ResourcePath won’t be added to resource references in *.css and *.svg files.
EmbedResourcesboolControls output HTML document resources (styles, images and fonts) saving. When this options set to true all resources will be embedded into HTML document and <see cref#“ResourcePath”/> option value will be ignored.
EnableMinification (added in 18.2)boolEnables content (HTML and SVG) minification.
EnableResponsiveRendering (added in 18.2)boolIndicates whether rendering will provide responsive web pages, that look well on different device types.
ExcludeFonts (added in 18.5)boolPrevents adding fonts to the output HTML document.
ExcludeFontsList (added in 18.11)string[]The list of font names, that will be excluded from HTML. Active only when ExcludeFonts is set to false.
StartPageNumberintAllows to specify document page number as starting page to render.
CountPagesintAllows to specify count of document pages to render.
PasswordstringAllows to specify document password in case when document is password-protected.
AttachmentPasswordstringAllows to specify attachment password in case when attachment is password-protected.
ExtractTextboolEnables document text extraction. For rendering document as image only.
RenderCommentsboolEnables document comments rendering.
RenderHiddenPagesboolEnables document hidden pages, sheets or slides rendering.
DefaultFontNamestringThe name of the default font.
Transformsstring[]Transforms to apply. Available transforms [“Rotate”,“Reorder”,“AddPrintAction”].
WatermarkWatermarkAllows to specify watermark.
CellsOptionsCellsOptionsThe Spreadsheet documents rendering options.
CadOptionsCadOptionsThe CAD documents rendering options.
EmailOptionsEmailOptionsThe Email documents rendering options.
WordsOptionsWordsOptionsThe Text documents rendering options.
PdfOptionsPdfOptionsThe PDF documents rendering options.
SlidesOptionsSlidesOptionsThe Presentation documents rendering options.
ProjectOptionsProjectOptionsThe Microsoft Project documents rendering options.

PdfFileOptions

Provides options for rendering document as PDF.

Example PdfFileOptions object

{
  "password": "document password",
  "extractText": false,
  "renderComments": false,
  "renderHiddenPages": false,
  "defaultFontName": "string",
  "transforms": [
    "Rotate",
	"Reorder",
	"AddPrintAction"
  ],
  "watermark": {
    "text": "watermark text",
    "color": "Magenta",
    "position": "Diagonal",
    "size": 50
  },
  "cellsOptions": {
    "renderGridLines": false,
    "paginateSheets": false,
    "encoding": "utf-8",
    "internalHyperlinkPrefix": "prefix",
    "countRowsPerPage": 50,
    "textOverflowMode": "OverlayIfNextIsEmpty",
	"ignoreEmptyRows": false
  },
  "cadOptions": {
    "scaleFactor": 50,
    "width": 600,
    "height": 800,
    "renderLayouts": true,
    "layoutName": "Master",
	"layers": ["Layer1"]
  },
  "emailOptions": {
    "encoding": "utf-8"
  },
  "wordsOptions": {
    "encoding": "utf-8",
    "renderTrackedChanges": false
  },
  "pdfOptions": {
    "enablePreciseRendering": false,
    "enableInitialContentOrdering": false,
    "renderLayersSeparately": false
  },
  "slidesOptions": {
    "renderNotes": false
  },
  "projectOptions": {
    "pageSize": "unknown",
    "pageSize": "unknown"
  }
}

PdfFileOptions Object Fields

NameTypeDescription
PasswordstringAllows to specify document password in case when document is password-protected.
ExtractTextboolEnables document text extraction. For rendering document as image only.
RenderCommentsboolEnables document comments rendering.
RenderHiddenPagesboolEnables document hidden pages, sheets or slides rendering.
DefaultFontNamestringThe name of the default font.
Transformsstring[]Transforms to apply. Available transforms [“Rotate”,“Reorder”,“AddPrintAction”].
WatermarkWatermark ObjectAllows to specify watermark.
CellsOptionsCellsOptions ObjectThe Spreadsheet documents rendering options.
CadOptionsCadOptions ObjectThe CAD documents rendering options.
EmailOptionsEmailOptions ObjectThe Email documents rendering options.
WordsOptionsWordsOptions ObjectThe Text documents rendering options.
PdfOptionsPdfOptions ObjectThe PDF documents rendering options.
SlidesOptionsSlidesOptions ObjectThe Presentation documents rendering options.
ProjectOptionsProjectOptions ObjectThe Microsoft Project documents rendering options.

RotateOptions

Provides options for rotating document pages.

Example RotateOptions object

{
  "pageNumber": 1,
  "angle": 90,
  "password": "document password"
}

RotateOptions Object Fields

NameTypeDescription
PageNumberintThe page number which angle should be changed.
AngleintThe angle in degrees to which the page should be rotated.
PasswordstringAllows to specify document password in case when document is password-protected.

ReorderOptions

Provides options for reordering document pages.

Example ReorderOptions object


{
  "pageNumber": 1,
  "newPosition": 2,
  "password": "document password"
}

ReorderOptions Object Fields

NameTypeDescription
PageNumberintThe page number which angle should be changed.
NewPositionintThe position where page should be placed.
PasswordstringAllows to specify document password in case when document is password-protected.

Watermark

Provides options for watermarking.

Example Watermark object.

"watermark": {
  "text": "watermark text",
  "color": "Magenta",
  "position": "Diagonal",
  "size": 50
}

Watermark Object Fields

NameTypeDescription
TextstringThe watermark text.
ColorstringThe watermark color. Supported formats “Magenta”, “(112,222,11)", “(50,112,222,11)". Default value is “Red”.
PositionstringThe watermark position. Supported positions “Diagonal”, “TopLeft”, “TopCenter”, “TopRight”, “BottomLeft”, “BottomCenter” and “BottomRight”. Default value is “Diagonal”.
SizeintWatermark size in percents. Default value is 100.

CellsOptions

Provides options for rendering spreadsheet documents.

Example CellOptions object.

"cellsOptions": {
  "renderGridLines": false,
  "paginateSheets": true,
  "encoding": "utf-8",
  "internalHyperlinkPrefix": "prefix",
  "countRowsPerPage": 50,
  "textOverflowMode": "OverlayIfNextIsEmpty",
  "ignoreEmptyRows": false,
  "renderHiddenRows": false,
  "renderHiddenColumns": false,
  "renderPrintAreaOnly": false
}

CellsOptions Fields

NameTypeDescription
RenderGridLinesboolIndicates whether to render grid lines.
PaginateSheetsboolEnables worksheets pagination. By default one worksheet is rendered into one page.
EncodingstringThe text (*.csv) document encoding.
InternalHyperlinkPrefixstringPrefix for hyperlink that references worksheet inside the same document. For rendering document as HTML only.
CountRowsPerPageintThe number of rows rendered into one page when PaginateSheets # true. Default value is 50.
TextOverflowModestringText overflow mode applied when the text is too big to fit into the cell. Supported modes “Overlay”, “OverlayIfNextIsEmpty”, “HideText” and “AutoFitColumn”. Default value is OverlayIfNextIsEmpty.
IgnoreEmptyRowsboolIndicates whether empty rows should be ignored.
RenderHiddenRows (added in 18.5)boolEnables rendering of hidden rows.
RenderHiddenColumns (added in 18.5)boolEnables rendering of hidden columns.
RenderPrintAreaOnly (added in 18.5)boolEnables rendering worksheet(s) sections which is defined as print area. Renders each print area in a worksheet as a separate page.

CadOptions

Provides options for rendering CAD documents.

Example CadOptions object.

"cadOptions": {
  "scaleFactor": 50,
  "width": 600,
  "height": 800,
  "renderLayouts": true,
  "layoutName": "Master",
  "layers": ["Layer1"]
}

CadOptions Object Fields

NameTypeDescription
ScaleFactorfloatThe scale factor affects the size of an output document.
WidthintThe width of the render result in pixels.
HeightintThe height of the render result in pixels.
RenderLayoutsboolIndicates whether layouts from CAD document should be rendered.
LayoutNamestringThe name of the specific layout to render.
Layersstring[]The list of document layers to render. By default all layers will be rendered. Layer names are case sensitive. (since 18.2)

EmailOptions

Provides options for rendering Email documents.

Example EmailOptions object.

"emailOptions": {
  "encoding": "utf-8",
  "pageSize": "Unknown",
  "fieldLabels": [{"field":"From", "Label":"Sender"}]
}

EmailOptions Fileds

NameTypeDescription
EncodingstringThe document encoding e.g. “utf-8”.
PageSize (added in 18.7)stringThe size of the output page when rendering as PDF or image. Supported values {Unknown
FieldLabels (added in 18.7)array

WordsOptions

Provides options for rendering Text documents.

Example WordsOptions object.

"wordsOptions": {
  "encoding": "utf-8",
  "renderTrackedChanges": false
}

WordsOptions Object Fields

NameTypeDescription
EncodingstringThe document encoding e.g. “utf-8”.
RenderTrackedChangesboolIndicates whether Tracked Changes (Revisions) should be rendered or not.

PdfOptions Object

Provides options for rendering PDF documents.

Example PdfOptions object.

"pdfOptions": {
  "enablePreciseRendering": false,
  "enableInitialContentOrdering": false,
  "renderLayersSeparately": false,
  "imageQuality": "Low"
}

PdfOptions Fields

NameTypeDescription
EnablePreciseRenderingboolIndicates whether the PDF document is rendered in a precise mode or not. It is recommended to enable this option when rendering documents with complex content e.g. documents which contains hieroglyphs or any kind o glyphs which should be rendered separately from each other.
EnableInitialContentOrderingboolWhen this option is enabled content (graphics and text) will be added to HTML document accordingly Z-order in original PDF document. When this option is disabled content (graphics and text) will be added to a single layer.
RenderLayersSeparatelyboolWhen this option is enabled layers will be separated from each other in the HTML document.
ImageQuality (added in 18.5)stringSpecifies output image quality for image resources when rendering as HTML. The default value is Low. Supported values Low, Medium and High

SlidesOptions Object

Provides options for rendering Presentation documents.

Example SlidesOptions object.

"slidesOptions": {
  "renderNotes": false
}

SlidesOptions Object Fields

NameTypeDescription
RenderNotesboolIndicates whether slide notes should be rendered.

ProjectOptions

Provides options for rendering Microsoft Project documents.

Example ProjectOptions object.

"projectOptions": {
  "pageSize": "unknown",
  "timeUnit": "unknown",
  "startDate": "2018-10-24T00:00:00",
  "endDate": "2018-11-24T00:00:00"
}

ProjectOptions Object Fields

NameTypeDescription
PageSizestringThe size of the page.
TimeUnitstringThe time unit to use as minimal point. Supported values {Unknown
StartDateDateTimeThe start date of a Gantt Chart View to render.Supported starting from v18.11
EndDateDateTimeThe end date of a Gantt Chart View to render. Supported starting from v18.11

OutlookOptions Object

Provides options for rendering Microsoft Outlook data files (.pst|.ost).

Example of OutlookOptions

"outlookOptions": {
  "maxItemsInFolder": "1000"
}

OutlookOptions fields

NameTypeDescription
MaxItemsInFolderintThe limit of items to render in mailbox folders