Folders operations
Get a collection of folders
To get all folders, you must execute a GET request to the following endpoint:
{baseurl}/api/default/folders
Sample request
GET http://mysite.com/api/default/folders
Sample response
NOTE: This endpoint serves all folders that are not root level libraries, regardless of whether the folder is nested inside an image album, video library, or a document library.
Get a folder
To get a single folder, you must execute a GET request to the following endpoint:
{baseurl}/api/default/folders({id})
Where id is the ID of the folder that you want to get, for example – 43d06f6a-513f-4014-a707-f2da1b10844f.
Sample request
GET http://mysite.com/api/default/folders(43d06f6a-513f-4014-a707-f2da1b10844f)
Sample response
Create a folder
To create a folder, you must execute a POST request to the following endpoint:
{baseurl}/api/default/folders
The minimal requirements to create a folder are the Title and the RootId. The UrlName is not required by the API. If left unpopulated, it will be generated by the server as a random GUID.
Sample request
POST http://mysite.com/api/default/videolibraries
Sample response
Partially update a folder
Updating a folder can be done in two ways – with a PATCH or with a PUT request. The difference between the two verbs is that PATCH allows for a partial update, whereas PUT requires all fields to be present in the request’s body.
To partially update a folder, you must execute a PATCH request to the following endpoint:
{baseurl}/api/default/folders({id})
Where id is the ID of the folder that you want to get, for example – 43d06f6a-513f-4014-a707-f2da1b10844f.
Sample request
PATCH http://mysite.com/api/default/videolibraries(288eff11-6e67-48ae-aefc-45b1c97e898b)
Sample response
Fully update a folder
Updating a folder can be done in two ways – with a PATCH or with a PUT request. The difference between the two verbs is that PATCH allows for a partial update, whereas PUT requires all fields to be present in the request’s body.
To partially update a folder, you must execute a PUT request to the following endpoint:
{baseurl}/api/default/folders({id})
Where id is the ID of the folder that you want to get, for example – 43d06f6a-513f-4014-a707-f2da1b10844f.
Sample request
PUT http://mysite.com/api/default/videolibraries(288eff11-6e67-48ae-aefc-45b1c97e898b)
Sample response
Delete folder
To delete a folder, you must execute a DELETE request to the following endpoint:
{baseurl}/api/default/folders({id})
Where id is the ID of the folder that you want to get, for example – 43d06f6a-513f-4014-a707-f2da1b10844f.
Sample request
DELETE http://mysite.com/api/default/videolibraries(288eff11-6e67-48ae-aefc-45b1c97e898b)
Sample response