Conversion API : Documents to image (multiple pages)

Hello,

I am currently using OnlyOffice conversion API.

When converting a Document (docx, pdf etc.) to Image (png, jpg etc.) only the first page of the document is returned as an image.

Is there any way to cut the file, and export an image for each page of the document?

Didn’t find the information on the documentation.

Best regards

Hello @Nicobelo

I think you might want to try this:

{
    "async": false,
    "filetype": "docx",
    "key": "Khirz6zTPdfd7",
    "outputtype": "jpg",
    "thumbnail": {
        "first": false
    },
    "title": "Example Document Title.docx",
    "url": "https://example.com/url-to-example-document.docx"
}

Parameter thumbnail.first set to false in the request body will allow you to convert whole document into image format and get the archive containing all converted pages as a result.
A bit more informative example of the request for conversion into image formats can be found on the same API page:
https://api.onlyoffice.com/editors/conversionapi#sample-thumbnail

1 Like