This action returns the basic information about a group. Existing groups will be looked up by ID
first and then by name
.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be getInfo . | getInfo |
name | Yes, if ID is missing | The name of the group. | Research |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
Example
https://powerfolder.example.com/api/groups?action=getInfo&name=Research
{ "ID":"0B5DA216628547228F23187C17AD5407", "name":"Research", "notes":"Notes can be very helpful", "nAccounts":2, "nFolder":1, "organizationID":"0B5DA216628547228F23187C17AD5407" } |
Result Key | Description | Example |
---|---|---|
ID | Group ID | 0B5DA216628547228F23187C17AD5407 |
name | Group name | Research |
notes | Custom text notes | Notes can be very helpful |
nAccounts | Number of accounts that are member of the group | 17 |
nFolder | Number of folder that belong to the group | 5 |
organizationID | The id of the organization the group is in | 0Z5DA289628547228F23187C17CE5899 |
Get a full list of all accounts that are member of the group.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be getAccounts . | getAccounts |
name | Yes, if ID is missing | The name of the group | Research |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
Example
http://powerfolder.example.com/api/groups?action=getAccounts&name=Research
{ "ResultSet":{ "Result":[ { "username":"employee1@example.com", "ID":"Fs9ojjjRJjUorufY8kpS", "organizationID":"GhbNBZkfUHbTbCo73VbN" }, { "username":"employee2@example.com", "ID":"BtzEN9DCM7higRZkdgTW", "organizationID":"GhbNBZkfUHbTbCo73VbN" } ] } } |
Get a full list of all folders that belong to the group and the permissions granted to the members of the group.
Parameter | Mandatory | Description | Example |
---|---|---|---|
action | Yes | Must always be getFolders . | getFolders |
name | Yes, if ID is missing | The name of the group | Research |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
Example
http://powerfolder.example.com/api/groups?action=getFolders&name=Research
{ "ResultSet":{ "Result":[ { "folderName":"Documents", "folderID":"[BiLhdsJFyyxJZ9FKg55J]", "permission":"READ_WRITE" }, { "folderName":"Deployment", "folderID":"[i1hyN6hB8jz8t6WxisD]", "permission":"READ" } ] } } |
This action creates or modifies a group. If the group does not exist yet, it will be created. If an existing group is found, it will be updated. Existing groups will be searched by ID
first and then by name
.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be store | store |
name | Yes | The name of the group | Development |
newObject | No | Must be "true" for a new group | true |
ID | No | The universal unique ID of the group. Will be used to find/create the group. Can be any external ID if unique. | 1DCB5E177F3A4ACA8C7E0842159E56D5 |
notes | No | Custom text notes | R&D without the R |
organizationID | No | The Organization ID of the Group | 1DCB5E177F3A4ACA8C7E0842159E56D5 |
Example
http://powerfolder.example.com/api/groups?action=store&ID=123&name=Development¬es=R%26D%20without%20the%20R&newObject=true
{ "ID":"123", "name":"Development", "notes":"R&D without the R", "nAccounts":0, "nFolder":0, "organizationID":"3pZKEgh2UFsWwDSgGxTZ" } |
Add a user to an existing group.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be addUser | addUser |
name | Yes, if ID is missing | The name of the group | Research |
ID | Yes, if name is missing | The universal unique ID of the group | 1DCB5E177F3A4ACA8C7E0842159E56D5 |
accountID | Yes | User account ID | C13s8qtAW8StkVvbEVtf |
accountName | Yes | User account name | employee2@example.com |
createAccount | No | Create the user if not existing | true |
Example
http://powerfolder.example.com/api/groups?action=addUser&name=Research&accountID=C13s8qtAW8StkVvbEVtf&accountName=employee2@example.com&createAccount=true
{ "ID" : "C13s8qtAW8StkVvbEVtf", "username" : "employee2@example.com", "message" : "Added user 'employee2@example.com' to group 'Research'" } |
This action will remove a user out of a group.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be removeUser | removeUser |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
name | Yes, if ID is missing | The name of the group. | MyGroup |
userID | Yes, if username is missing | The ID of a user | 0C5DF216629747228F23157C17FA5488 |
username | Yes, if userID is missing | The name of a user | thomas@example.com |
Example
https://powerfolder.example.com/api/groups?action=removeUser&name=mygroup&userid=0B5DA216628547228F23187C17AD5407
{ "ID" : "0C5DF216629747228F23157C17FA5488", "username" : "thomas@example.com", "message" : "Removed user 'thomas@example.com' from group 'MyGroup'" } |
This action deletes a group and all referenzes to it.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be delete | delete |
name | No | The name of the group | Research |
ID | Yes | The ID of an existing group | 1DCB5E177F3A4ACA8C7E0842159E56D5 |
Example
http://powerfolder.example.com/api/groups?action=delete&ID=1DCB5E177F3A4ACA8C7E0842159E56D5
{ "ID":"1DCB5E177F3A4ACA8C7E0842159E56D5", "message":"Successfully deleted group Research. Removed 15 Accunts and 4 Folders." } |
This action will grant a group specified folder permissions.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be addFolder | addFolder |
ID | Yes, if name is missing | The universal unique ID of the group. | 9QusRjrxuTxqrLyjPjTz |
name | Yes, if ID is missing | The name of the group | MyGroup |
folderID | Yes | The ID of the folder | 246jRkZiDdgpFXaqe9rJ6 |
permission | Yes | The Permission the group will be granted | READ_WRITE |
Example
https://powerfolder.example.com/api/groups?groups?action=addFolder&ID=9QusRjrxuTxqrLyjPjTz&folderID=246jRkZiDdgpFXaqe9rJ6&permission=READ_WRITE
{ "ID" : "9QusRjrxuTxqrLyjPjTz", "name" : "MyGroup", "message" : "Added Folder 'Documents' to group 'MyGroup'" } |
This action will revoke specified folder permissions from a group.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be removeUser | removeFolder |
FolderID | Yes | The ID of the folder | 0C5DF216629747228F23157C17FA5488 |
name | Yes, if ID is missing | The name of the group | MyGroup |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
Permission | Yes | The Permission the group will be revoked | FolderReadWritePermission |
Example
https://powerfolder.example.com/api/groups?action=removeFolder&name=mygroup&folderid=0C5DF216629747228F23157C17FA5488&permission=FolderReadWritePermission
{ "ID" : "0B5DA216628547228F23187C17AD5407", "name" : "MyGroup", "message" : "Removed Folder 'Documents' from group 'MyGroup'" } |
This action will add multiple accounts with one request to a group.
The length of the accountID and accountName must be equal.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be removeUser | removeUser |
name | Yes, if ID is missing | The name of the group | MyGroup |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
accountID | Yes | The ID's of the accounts that should be added to the group | please take a look at the example |
accountName | Yes | The Name's of the accounts that should be added to the group | please take a look at the example |
Example
https://powerfolder.example.com/api/groups?action=saveAccountsToGroup&name=MyGroup&accountID=0C5DF216629747228F23157C17FA5488&accountName=Thomas&accountID=8E5CF216629747228F46157A17FA7845&accountName=Peter
This action will add multiple folders with one request to a group.
The length of the folderID and folderName must be equal.
Parameter | Required | Description | Example |
---|---|---|---|
action | Yes | Must always be removeUser | removeUser |
name | Yes, if ID is missing | The name of the group | MyGroup |
ID | Yes, if name is missing | The universal unique ID of the group. | 0B5DA216628547228F23187C17AD5407 |
folderID | Yes | The ID's of the accounts that should be added to the group | 0C5DF216629747228F23157C17FA5488 |
folderName | Yes | The Name's of the accounts that should be added to the group | MyFolder |
permission | Yes | The Permission that will be added to the group for the specified folder | READ |
Example
https://powerfolder.example.com/api/groups?action=saveFoldersToGroup&name=MyGroup&folderID=0C5DF216629747228F23157C17FA5488&folderName=MyFolder&permission=READ_WRITE&folderID=8E5CF216629747228F46157A17FA7845&folderName=MyOtherFolder&permission=READ