Get folder list - Get folder list v2
OVERVIEW
This is the second version of this API which was changed in Collaborate 4.1.4 and above
This API endpoint is used to obtain the folder list given the folder id.
Resource(API) EndPoint | Query Params | HTTP Method | Request XML | Response XML | Response Code |
---|---|---|---|---|---|
/folders/{folderid}/items | limit={limit} offset={offset} orderby={asc/desc} ordertype={name/author/lastModified} |
GET | Response XML | Response Code |
API Version 1
<folders>
<folder>
<id>10603</id>
<name>First</name>
<permission>UPDATE</permission> <!-- ( Permission Element in API version 1) -->
<child>1</child>
<parentFolderID>210</parentFolderID>
<accessInherited>1</accessInherited> <!-- (supported from 4.0.2 branch) -->
<createddate>19 Aug 2016 07:04</createddate>
<modifieddate>19 Aug 2016 07:04</modifieddate>
<location>folder1/folder2</location> <!-- (supported from 4.0.3 branch) -->
<createdby>
<firstname>first</firstname>
<lastname>last</lastname>
<email>first.last@domain.com</email>
<userid>368</userid>
</createdby>
<modifiedby>
<firstname>first</firstname>
<lastname>last</lastname>
<email>first.last@domain.com</email>
<userid>368</userid>
</modifiedby>
</folder>
</folders>
API Version 2 (Support from 4.0.3)
<folders>
<folder>
<id>10603</id>
<name>First</name>
<permission>
<view>1</view>
<edit>1</edit>
<delete>1</delete>
<addEditAllFiles>1</addEditAllFiles> <!-- ( Permission Element in API version 2) -->
<viewAllFiles>1</viewAllFiles>
<admin>1</admin>
</permission>
<child>1</child>
<parentFolderID>210</parentFolderID>
<accessInherited>1</accessInherited> <!-- (supported from 4.0.3 branch) -->
<createddate>19 Aug 2016 07:04</createddate>
<modifieddate>19 Aug 2016 07:04</modifieddate>
<location>folder1/folder2</location> <!-- (supported from 4.0.3 branch) -->
<createdby>
<firstname>first</firstname>
<lastname>last</lastname>
<email>first.last@domain.com</email>
<userid>368</userid>
</createdby>
<modifiedby>
<firstname>first</firstname>
<lastname>last</lastname>
<email>first.last@domain.com</email>
<userid>368</userid>
</modifiedby>
</folder>
</folders>
Notes
- The value of limit parameter behaves as following
limit =100 is the default value
if limit>0 then (number of items returned is equal to limit)
if limit=-1 then return all records
if limit <-1 then the system returns the default no of items i.e 100 - The value of Offset parameter behaves as under
(Default) offset =0
if offset > 0 then the records are returned from the offset value
if offset < 0 then offset value of 0 is set - Defalut value for orderby parameter is asc
- Default value if ordertype is creation date
- The return elements of permissions and accessInherited was added in version 4.0.3 of the API and are explained in the Get Folder Info API
- The location element has been added in Collaborate 4.0.3 and provides the folder hierarchy of the specific folder in the site.
Response Code
Code | Meaning |
---|---|
200 | Get Folder List successfully |
400 | Problem with parsing XML or JSON object (Bad Request) |
401 | Unauthorized |
403 | Validation failed/ Forbidden |
405 | Method not allowed (calling api with wrong method) |
500 | Internal error occurred |
Comments
0 Comments