Is it possible to create an image conversion via API?

Could you please tell me is it possible (and how) to add a new picture conversion to an existing picture document in Nuxeo Platform?

My use case is the following, I can upload a picture file to the platform and after some time I would like to upload via API a file containing the same picture, but in a different size or mime-type. In this case, Nuxeo should treat the uploaded file only as a conversion of the existing image and not a new asset.

I have gone through the documentation of Nuxeo but cannot seem to find the answer to my question.

0 votes

1 answers

1212 views

ANSWER



Hello,

Here are several documentation link which will probably help you:

As for the REST API calls for conversions, you need to use a web adapter: https://doc.nuxeo.com/nxdoc/rest-api-web-adapters/, so like http://NUXEO_SERVER/nuxeo/api/v1/id/{docId}/@convert?format=pdf

Regards

0 votes



Thank you for the fast reply, I will certainly dig into the proposed links.

So, just to make sure, it is not possible just to upload a file from the file system and set it to be the rendition of the asset in Nuxeo? Does it always have to go through the conversion extension?

04/26/2020

You can choose to use a specific property (of type blob) to store a file (which could be a conversion or anything else).
04/26/2020

Hi, thanks again for replying! Could you give an example of a specific property in which I can store the conversion of the document? What I tried is attaching a blob in picture:views, but this doesn't seem to be possible.
04/27/2020