Hi Team, I am using 90 day's trial version. I am Integrating OpenText Content Storage Services API's to our existing App, can you tell me how to upload documents to a particular folder
Thanks
Kailash Singh
If there are Accepted Answers, those will be shown by default. You can switch to 'All Replies' by selecting the tab below.
{ "name": "{{tmp_file_name}}", "parent_folder_id": "{{cms_folder_id}}", "type":"cms_file", "acl_id": "{{cms_folder_acl_id}}", "description": "", "version_label": [ "INITIAL" ], "renditions":[{ "name": "{{tmp_file_name}}", "blob_id": "{{tmp_file_href}}", "rendition_type":"PRIMARY" }, { "name": "Brava rendition", "mime_type": "application/vnd.blazon+json", "rendition_type": "SECONDARY" }] }
Hi Roger,
Thanks for your reply,I am following the above steps , only passing parent folder id and acl_id of cms_root_folder(Not created a new folder) and following is my JSON for step 3
{"name":"Uploadnda1","parent_folder_id":"057a1d3a-2876-11e8-b467-0ed5f89f718b","type":"cms_file","acl_id":"057a193e-2876-11e8-b467-0ed5f89f718b","versionLabel":["INITIAL"],"renditions":[{"name":"Uploadnda1","renditionType":"PRIMARY","blobId":"https://na-1-dev.api.opentext.com/css/v2/content/cj1kZjA3NmI1My1iMTVkLTQwMjMtYTFkYi01YTY3NTFiNGExOTQmaT0zNjE3ZmI4Yy03MTE5LTRmNzEtODk4My1mNzMyZjYxYzcxZDQ=/download"},{"name":"Brava rendition","renditionType":"SECONDARY","mimeType":"application/vnd.blazon+json"}]}
but I am getting following response
{"path":"https://na-1-dev.api.opentext.com/cms/instances/file/cms_file","title":"Bad Request","status":400,"details":{"renditions":[{"validations":[{"code":"RENDITION_EXISTANCE_VALIDATION_FAILED","label":"Rendition Existence Validator","message":"One primary rendition must be specified for create operation of Uploadnda1","errorCategory":"VALIDATION"}],"value":"renditions"},{"rendition_type":{"validations":[{"code":"REQUIRED_ATTR_VALIDATION_ERROR_NAME","label":"Required Attribute Validator","message":"Required attribute (rendition_type) must be set","errorCategory":"VALIDATION"}]}},{"rendition_type":{"validations":[{"code":"REQUIRED_ATTR_VALIDATION_ERROR_NAME","label":"Required Attribute Validator","message":"Required attribute (rendition_type) must be set","errorCategory":"VALIDATION"}]}}]}}
can you help where I am going wrong .
thanks Roger, how may rendition_types available?
Hi @Lucasl , you can use 'primary' and 'secondary' as values for rendition_type. See also the request schema https://developer.opentext.com/services/products/content-metadata-service/apis/content-metadata#File/createNewInstance