Get files list - Get files list v1
OVERVIEW
Note: The latest specification for Collaborate 4.1.4 and above is here
This is an API method to get a list of files from Collaborate. The file list can be filtered using a search query.
Request
GET /files
Parameters:
Parameter Name | Type | Detail | |
---|---|---|---|
limit | int | Optional | No of items to be to be returned |
offset | int | Optional | Starting point of the returned items. This should be the item ID. |
ordertype | String | Optional | can be one of name, size, author, lastModified, filetype |
orderby | string | Optional | This is the order of the items returned. Possible values are "Asc" , "desc" , Default is Desc, which means that the latest items are returned first. |
q | string | Mandatory | query to filter out results, please check the search query details for specification of the "q" parameter |
Search Query Parameters:
The search query consists of three parts
- Field : Field specifying the search criteria. e.g site
- Operator : Test or condition that has to be performed on the data to create a filter
- Value : The content of the attribute that is to be tested, e.g folderid = 217
The representation of q parameter works as under
q = "folderid=1"
Where q parameter is in double quotes and is URL encoded.
Fields | Value Type | Operator | Description |
---|---|---|---|
folderId | int | = | ID of the parent folder for which the list of files is required |
With the current implementation of the files list API the q parameter only supports folderid, this parameter will be extended in the future implementations of the file list API to support a more detailed search criteria.
Response
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
</files>
<filetotal>Total no of files satisfying this search criteria</filetotal>
<file>
<name>RRRRRRRRRR</name>
<id>868</id>
<versionid>1</versionid>
<createddate>20 Jun 2014 10:06</createddate>
<modifieddate>20 Jun 2014 10:06</modifieddate>
<type>pdf</type>
<folderid>123</folderid>
<siteid>234</siteid>
<icon>http://clientinstance.highq.com/clientinstance/images/fileicon/pdf.png</icon>
<commentscount>0</commentscount>
<likescount>0</likescount>
<createdby>
<firstname>Tom</firstname>
<lastname>Chick</lastname>
<email>user@highq.com</email>
<userid>103</userid>
</createdby>
<modifiedby>
<firstname>Tom</firstname>
<lastname>Chick</lastname>
<email>user@highq.com</email>
<userid>103</userid>
</modifiedby>
</file>
</files>
Note:
- All dates are in UTC.
- In this phase we are only supporting folderid in q parameter
- eg: q="folderid=12"
- The default value for limit is 100
- if limit>0 then (number of return data = limit)
- if limit=-1 then return all data
- if limit<-1 then default value of the limit will be returned, which is 100
- The default value of offset is 0
- if offset>0 the starting point will be the offset value.
- if offset<0 then the default value of 0 will be used by the system
- The default value of orderby parameter is descending (desc)
- The default value for ordertype parameter is creation date
Comments
0 Comments