cancel
Showing results for 
Search instead for 
Did you mean: 

REST API to access document rendered with associated template

Emmanuel_Otton
Champ on-the-rise
Champ on-the-rise

Hi, Having created a document with the REST API, I can, on the web interface, generate a docx file rendering, using a docx template associated with this document type. Is it possible to programmatically generate this rendering, and access the docx file generated, with the REST API ? Thanks,

1 REPLY 1

Emmanuel_Otton
Champ on-the-rise
Champ on-the-rise

I answer myself, after a more thorough reading of the documentation.

The URL to get the rendered document is not in the /api/v1/etc... , but in the nxtemplate namespace; the URL nxtemplate/document-path@model-name renders the document and returns the rendered result.

Example: GET http://nuxeo.mycompany.com:8080/nuxeo/nxtemplate/default/stages-conventions/convention-test-eleve-01... ... returns a docx binary file, Where:

  • stages-conventions is a workspace directory,
  • stage-convention-modele-01 is the name of a nuxeo template containing a docx template document
  • convention-test-eleve-01 is a nuxeo document associated with the template
Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.