API Documentation
|
where {collectionId}
is the ID of a folder/collection.
GET
- retrieves a list of information associated with all immediate child folders/collections contained within the folder specified by collectionId
.This API endpoint retrieves a list of information about all immediate child folders contained within a folder specified by collectionId
.
collectionId
. If this user is a collaborator on this folder, then only folders which this user is also a collaborator on are returned in the response.collectionId
value being the ID of the relevant nested folder.A folder's ID can be obtained by calling the <access-service>/api/v1/organisations/{orgId}/items API endpoint, which retrieves a list of information associated with folders that can be filtered using various 'search' criteria.
The folders returned in a response to this API endpoint can be filtered according to those which:
This API endpoint supports requests utilizing Cocoon Data user accounts with the following roles (as described in the Organisation Administrator's Guide):
{collectionId}
in the request's URL.{collectionId}
in the URL.The Cocoon Data Platform's resources available to one of these Cocoon Data users (above) is determined by the access token submitted in the header of requests to this endpoint.
The appropriate access token as the Bearer
token:
Authorization: Bearer eyJhbGciOiJSUzI1NiJ9.eyJleHAiOjE0NjcwMTY2NjYsInVzZXJfbmFtZSI6ImFsZXgub...
The following optional parameters can be sent in the URL of the GET request:
collectionId
value is 0
, which represents the root level location. ) - The ID of the organisation from which items (i.e. folders at the root level location) will be retrieved. collectionId
). Specifying this parameter filters the response to folders which the Cocoon Data user (whose access token is submitted in the request) has permission to move this item. collectionId
). Specifying this parameter filters the response to folders which the Cocoon Data user (whose access token is submitted in the request) has permission to restore this item. 0
to 100
, representing the maximum number of items (i.e. folders) to be returned in the response from the Cocoon Data Platform, where an individual item is information about a folder. A value of 0
imposes no limit on the number of items returned. If this parameter is omitted, then its value is 10
by default. 0
(i.e. the first item returned in a response). If this parameter is omitted, then its value is 0
by default. ASC
or DESC
(default is ASC
). owned-by-me
- retrieves only folders that this user currently owns. shared-with-me
- retrieves only folders that this user is a collaborator on (i.e. other people have shared these folders with this user). sharing
- retrieves only folders that this user has shared with other people. all
- retrieves all items that this user has access to. If the request succeeded, then an HTTP response status 200 OK
is returned.
For successful requests only, a JSON-formatted response containing the following members is also returned:
collectionId
of the folder/location in the URL of this request. collectionId
. A value of 0
indicates that this folder (specified by collectionId
) is located at the logical root location. collectionId
. POST
method on the <access-service>/api/v1/organisations/{orgId}/collections endpoint), this date and time should match (or be close to) that of the createdAt value below. Otherwise, if the folder has since been modified (e.g. via a PUT
method request to this endpoint), this date and time should reflect when the folder was last modified. false
. collectionId
), returned in the response to this endpoint. Each element of this array contains information about one of these folders, represented as an object containing all of the members above (except originator, count, offset and items) as well as the following members. null
. collection
, indicating that the type of item returned is a folder.