Retrieve contents of a content library document
Use this interface to retrieve the contents of a content library document.
Service URL:
/rest/api/v1.3/clDocs/{documentPath}
Required Path Parameter:
documentPath
Request Method:
GET
Request Header:
Authorization=<AUTH_TOKEN>
Request Body:
None
Sample Response in case of success:
RESPONSE NOTE: The response contains the content of the document as it is saved in the content library. The Web Services API does not decode the content of the document before returning the response.
{
"documentPath": "/contentlibrary/abn/wsrest_cl.htm",
"content": "<html dir=\"ltr\">\r\n <head>\r\n <title><\/title>\r\n <\/head>\r\n <body>\r\n <p>test document<\/p>\r\n <p><img src=\"wsrest_cl.images/testcreate-1.png\" alt=\"\" /><\/p>\r\n <\/body>\r\n<\/html>\n\n\n",
"links": [
{
"rel": "self",
"href": "/rest/api/v1.3/clDocs/contentlibrary/abn/wsrest_cl.htm",
"method": "GET"
},
{
"rel": "deleteDocument",
"href": "/rest/api/v1.3/clDocs/contentlibrary/abn/wsrest_cl.htm",
"method": "DELETE"
},
{
"rel": "setDocumentContent",
"href": "/rest/api/v1.3/clDocs/contentlibrary/abn/wsrest_cl.htm",
"method": "POST"
},
{
"rel": "createDocument",
"href": "/rest/api/v1.3/clDocs",
"method": "POST"
}
]
}
Sample Response in case of failure:
{
"type": "",
"title": "Document not found",
"errorCode": "DOCUMENT_NOT_FOUND",
"detail": "/contentlibrary/abn/wsrest_cl.htm",
"errorDetails": []
}