...
To get the documentUID from the document's path, you must can run a http POST against the Document.Fetch endpoint of the DMS:
...
Creating a document in the DMS is a bit more complex. In Nuxeo, a document is made up of a document container, think of it as a shell with some metadata attached to it, and the binary/binaries. To create document in the DMS, you must thus first create a container and then add the binary to it.
a) Creating the "container"
Code Block |
---|
http://<nuxeoserverip>:<nuxeoport>/nuxeo/api/v1/automation/Document.Create |
This can be called as http POST against the DMS as follows:
Code Block |
---|
curl -X POST \
http://<nuxeoserverip>:<nuxeoport>/nuxeo/api/v1/automation/Document.Create \
-H 'authorization: Basic <userAndPassEncoded>' \
-H 'content-type: application/json' \
-d '{"params":{"entity-type":"document","type":"File","name":"<docName>","properties":{"dc:title":"<docName>","pifile:docCategoryID":"<categoryID>"}},"input":"/default-domain/workspaces/Patricia/<documentPath>"}'
|
Deleting a document from the DMS
...
Code Block |
---|
http://<nuxeoserverip>:<nuxeoport>/nuxeo/api/v1/automation/Document.SetLifeCycle |
This must can be called as http POST against the DMS as follows:
...
Torben Rees of Greaves Brewster deserves great kudos for having developed an integrating tool that uploads documents to the DMS and creating an excellent piece of documentation of which we used parts above. Please see his complete document here:
View file | ||||
---|---|---|---|---|
|