How to fetch docx and xlsx blobs as pdf from REST api or Java client

I am uploading docx, xlsx(excel files) and pdfs to nuxeo and able to see them in Nuxeo UI correctly.

Using the java client's method streamBlobByPath I am able to fetch the blob of document in my custom code. nuxeoClient.repository().streamBlobByPath(path, "file:content");

For the docx or xlsx files, when I use Nuxeo UI I am able to see the documents embedded in a pdf previewer.

How can I get the docx and xlsx as pdf blobs so it can be rendered by my custom pdf previewer?

I do not want the pdf previewer embedded in the blob. Just the content as pdf formatted blob.

0 votes

0 answers



I can try a suggestion: leverage the automation (or an automation chain leveraging this operation) to transform your Blob (XLSX, DOCX) to a PDF format and upload the resulting PDF using your custom PDF previewer.? The transformation from BLOB to PDF can be automated using event listeners at BLOB creation time.

Maybe a simpler solution exists…?


Patrick Abgrall thanks for your comment. Does this conversion not happen automatically? So when nuxeo ui is fetching a docx file, the server has to do the transformation in realtime?

The way I have described is in fact documented at and

Notice that gives some hints about another way to perform this via REST and a synchronous conversion in 1 URL .