DS Server

Supported File Formats

Topic

Most endpoints of the DocumentProcessing Web API take a document as a Base64 string and return a document, page images or JSON, so the formats they accept and the formats they can return decide what your application can do with them. The tables below list them per endpoint, with the values of the returnFormat and imageFormat parameters, and the limits that apply when DS Server runs on Linux.

Document Formats

The endpoints that return a document take the format in the returnFormat query parameter. The default is PDF.

returnFormatFormatReturned by
PDFAdobe PDFconvert, merge, findandreplace, append, pdf/create
PDFAPDF/A, created as PDF/A-3bconvert, merge, findandreplace, append, pdf/create
DOCXMicrosoft Word, Office Open XMLconvert, merge, findandreplace, append
DOCMicrosoft Word 97-2003convert, merge, findandreplace, append
RTFRich Text Formatconvert, merge, findandreplace, append
HTMLHTMLconvert, merge, findandreplace, append
TXTX Text Control format, Unicodeconvert, merge, findandreplace, append
TXTPlain Unicode textconvert, merge, findandreplace, append

The ReturnFormat enumeration of the .NET package TXTextControl.DocumentServices.DocumentProcessing has the same values.

Formats per Endpoint

EndpointAcceptsReturns
document/convertRTF, DOC, DOCX, HTML, PDF, TXA document in the returnFormat
document/mergeA template in RTF, DOC, DOCX or TX, and JSON dataAn array of documents in the returnFormat, one document unless append is false
document/findandreplaceA template in RTF, DOC, DOCX or TXA document in the returnFormat
document/appendDocuments as Base64 stringsOne document in the returnFormat
document/thumbnailsDOC, DOCX, PDF, TX, XLSX, RTF, HTMLPage images in the imageFormat: PNG, JPG, GIF, BMP or SVG
document/infoA document as a Base64 stringJSON with the document properties, merge fields and merge blocks
pdf/createA document as a Base64 stringPDF or PDF/A, with optional signature, attachments and permissions
pdf/embeddedfiles, pdf/metadata, pdf/acroforms/fieldsPDFJSON with the attachments, the metadata or the form fields
barcodes/createThe barcode text and settingsA barcode image in the imageFormat: BMP, EMF, GIF, JPEG, PNG or TIFF

What the table does not show:

  • Templates for merge and findandreplace are the word processing formats RTF, DOC, DOCX and TX. HTML and PDF are accepted by convert, but not as templates.
  • XLSX is accepted by the thumbnails endpoint. The reference of the convert endpoint does not list it as an input format.
  • Thumbnails default to PNG. SVG was added in version 3.2.0. On Linux, the changelog limits the rendering of documents to SVG.
  • Barcodes default to PNG. The barcode type is set with the barcodeType parameter, for example QRCode, Code128 or Datamatrix.

Limits on Linux

When DS Server runs on Linux, the changelog of version 4.0 limits the formats:

Supported on Linux
Document formatsDOCX, HTML, PDF and XLSX
Image formats, open and savePNG, JPG and BMP
Image formats, open onlyTIFF and GIF
RenderingSVG only, no bitmap rendering

On Linux, the returnFormat values DOC, RTF, TX and TXT, and templates in the formats DOC, RTF and TX, are therefore outside the documented support. Use the Classic build on Windows for them. Core and Classic explains the two builds.

PDF and PDF/A

  • PDF/A. PDFA creates PDF/A-3b, the conformance level the PDFFormat enumeration of the .NET package names.
  • Creating PDF with options. pdf/create adds a digital signature with an X.509 certificate, embedded files, document access permissions, passwords, keywords and JavaScript actions to the PDF.
  • Reading PDF. Three endpoints read a PDF without converting it: its embedded files, its metadata and its AcroForm fields.
  • Form fields. The convert endpoint's flattenFormFields parameter replaces the form fields of a document by their values.

Document Editor and Document Viewer

The Document Editor and the Document Viewer load and save documents through their own JavaScript APIs and client packages rather than through the Web API. Their documents are processed by the same DS Server installation, so the limits on Linux apply to them as well. See the Document Editor JavaScript API and the Document Viewer JavaScript API.