Folder

MCM module
Folder extension
Folder/GetPermission

Get permissions for a specific folder.

Parameters:folderID – the FolderID of the folder
Returns:the permissions of the folder
Return type:FolderPermission:
Folder/SetPermission

Sets the permissions for a specific user or group to a specific folder.

Authentication:
  • Logged in – You need to be logged in to use this feature
  • Folder permissions – User must have permission to update the folder
Parameters:
  • userGuid (optional) – the guid of the user whose permissions should be updated
  • groupGuid (optional) – the guid of the group whose permissions should be updated
  • folderID – the FolderID of the folder
  • permission (unsigned integer) – the new permissions for the folder
Returns:

The number of affected rows in the database

Either userGuid or groupGuid must be given.

Folder/Get

Gets a specific folder (id), all folders in a folder (parentID), or all the folders the current user has access to.

Authentication:
  • Logged in – You need to be logged in to use this feature
  • Folder permission – The user has to have permission to read the folders. (Permission.FolderPermission.Read)
Parameters:
  • id (optional) – the ID of the folder to get
  • parentID (optional) – get all folders in the folder with this ID
  • permission (optional) – Get only folders with these permissions

You may not specify both id and parentID at the same time. If neither id nor parentID is specified all folders the user has access to are returned. If permission is specified only folders with these permissions will be returned.

Folder/Delete

Deletes a folder.

Authentication:
  • Logged in – You need to be logged in to use this feature
  • Folder permission – The user has to have permission to delete the folder. (Permission.FolderPermission.Update)
Parameters:

id – the ID of the folder to delete

Returns:

The number of affected rows in the database

Folder/Update

Updates a folder.

Authentication:
  • Logged in – You need to be logged in to use this feature
  • Folder permission – The user has to have permission to update the folder. (Permission.FolderPermission.Delete)
Parameters:
  • id – the ID of the folder to update
  • newTitle (string) – the (new) title of folder
  • newFolderTypeID (optional) – the new FolderTypeID of the folder
  • newParentID (optional) – the ID of the new parent folder
Returns:

The number of affected rows in the database

If newParentID is specified the folder (with ID id) is moved to the newParentID folder.

Folder/Create

Creates a new folder.

Authentication:
  • Logged in – You need to be logged in to use this feature
Optional authentication:
 
  • Folder permission – If parentID is specified the user has to have permission to update the folder. (Permission.FolderPermission.Write)
  • Subscription permission – If subscriptionGuid is specified the has to have permission to create folders in the subscription. (SubscriptionPermission.CreateFolder))
Parameters:
  • subscriptionGuid (optional) – the GUID of the subscription the folder should belong to
  • title – the title of the new folder
  • folderTypeID – the FolderTypeID of the new folder
  • parentID (optional) – the ID of the folder the new folder should be put into
Returns:

The new folder

You must either specify either subscriptionGuid or parentID.