Syncplicity Support

Search our knowledgebase to get the help you need, today

Follow

Remove permissions from the source, destination

This feature will allow the user to remove permissions from either the source or destination via the REST API. To do this, we can use the following DELETE calls to remove all, or some of the permissions as desired. This can be applied to both files and folders.

Files

This will delete all permissions on the specified file path as specified by the ID. No body is needed for this request

1

DELETE /connections/{connection}/files/{id}/permissions/all

This will delete all permissions as specified by the file path (no ID as the call above). No body is needed for this request

1

DELETE /connections/{connection}/files/permissions/all?path={filePath}

This will delete permissions to a specified file path. Also requires request body

DELETE /connections/{connection}/files/permissions?path={filePath}

This will delete permissions to a specified file path. In order to successfully remove permissions, we need to provide a body that lists the desired permissions to be removed. This can be one or many. To obtain, you may change the DELETE above to GET, and copy/paste the response from there. Example request body below:

Request Body

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

[
    {
        "sid": {
            "name": "TestUser02",
            "email": "Tuser02@company.onmicrosoft.com",
            "username": "Tuser02@company.onmicrosoft.com",
            "id": "75",
            "external_id": "i:0#.f|membership|Tuser02@company.onmicrosoft.com",
            "type": "account",
            "principal_type": 1
        },
        "rights": [
            "read_write"
        ]
    }
]

Folders

Removing permissions from Folders is much the same as Files above. Those with /all do not require bodies. Calls pointing to a specific folder do, and follow the same pattern as Files.

This will delete all permissions on the specified file path as specified by the ID. No body is needed for this request

1

DELETE /connections/{connection}/folders/{id}/permissions/all

This will delete all permissions as specified by the folder path (no ID as the call above). No body is needed for this request

1

DELETE /connections/{connection}/folders/permissions/all?path={folderPath}

This will delete permissions to a specified folder path

DELETE /connections/{connection}/folders/permissions?path={folderPath}

In order to successfully remove permissions, we need to provide a body that lists the desired permissions to be removed. See the above Files call for instruction on how to obtain this information

Powered by Zendesk