Folder Options
The Folder Options API allows you to modify settings for folders in your Egnyte domain, including descriptions, link sharing permissions, move/delete restrictions, and email notification preferences.
Note: File paths must be URL-encoded segment by segment. Do not encode forward slashes (/). See Path Encoding for details.
Base URL
https://{domain}.egnyte.com/pubapi/v1/fs
Authentication
All requests require an OAuth 2.0 Bearer token in the Authorization header:
Authorization: Bearer {access_token}
The token must include the Egnyte.launch scope for web session access.
See Authentication for details on obtaining a token.
Modify Folder Options
Update configuration options for a folder, including description, link sharing permissions, move/delete restrictions, and email preferences.
Request
PATCH /pubapi/v1/fs/{path}
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
path | string | Yes | Full path to the folder (e.g., Shared/Contracts). Each segment must be URL-encoded separately. |
Request Body
At least one parameter must be included in the request.
| Field | Type | Required | Description |
|---|---|---|---|
folder_description | string | No | Text description of the folder. Maximum 200 characters. |
allow_links | boolean | No | Whether any links (both private and public) can be created for files or sub-folders within this folder. When set to false, all link creation is disabled regardless of the public_links setting. |
allow_upload_links | boolean | No | Whether upload links are allowed for this folder. |
public_links | string | No | Public link permissions. Allowed values: files_folders, folders, files, disabled. |
restrict_move_delete | boolean | No | If true, restricts move and delete operations to Admins and Owners only (equivalent to move_delete_folder_restriction set to admins_or_owners). If false, maps to admins_owners_or_full_access_users. Cannot be applied to top-level folders in /Shared or /Private. If both restrict_move_delete and move_delete_folder_restriction are provided, move_delete_folder_restriction takes precedence. |
move_delete_folder_restriction | string | No | Granular move/delete restriction level. Allowed values: admins_owners_or_full_access_users, admins_or_owners, admins_only. Cannot be applied to top-level folders in /Shared or /Private. Provides finer control than the boolean restrict_move_delete field. |
inheritance_rule | string | No | Controls how the updated settings propagate to subfolders. Allowed values: legacy (default), this_folder_only, this_folder_and_subfolders_until_overridden, this_folder_and_subfolders. this_folder_only applies settings to the current folder without propagation to subfolders. legacy uses the legacy propagation behavior, which may propagate certain settings (such as the fixed flag) differently than the other modes. |
email_preferences | object | No | Email notification settings. Contains boolean keys: content_updates, content_accessed. Setting content_accessed for a Standard User will return a 400 error. Note: notification settings are write-only through this endpoint — they are not included in the response. |
Example Request
curl -i -X PATCH "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/Contracts" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \ -d '{ "folder_description": "This folder contains all of the contracts for our construction projects." }'
Response
200 OK
Returns the updated folder metadata.
The response returns the standard folder metadata object. Note that email_preferences (notification settings) are not included in the response.
| Field | Type | Description |
|---|---|---|
name | string | Folder name. |
lastModified | integer | Last modified timestamp in milliseconds since epoch. |
uploaded | integer | Upload timestamp in milliseconds since epoch. |
path | string | Full path to the folder. |
folder_id | string | Unique identifier for the folder. |
parent_id | string | Unique identifier of the parent folder. |
folder_description | string | Text description of the folder. |
is_folder | boolean | Always true for folders. |
allow_links | boolean | Whether any links (both private and public) can be created for files or sub-folders within this folder. |
allow_upload_links | boolean | Whether upload links are allowed for this folder. |
allowed_file_link_types | array | List of allowed file link types for this folder. |
allowed_folder_link_types | array | List of allowed folder link types for this folder. |
public_links | string | Public link permission setting: files_folders, folders, files, or disabled. |
restrict_move_delete | boolean | Whether move/delete operations are restricted to Admins and Owners. |
move_delete_folder_restriction | string | Granular move/delete restriction level: admins_owners_or_full_access_users, admins_or_owners, admins_only, or forbidden. Legacy data may also return none (deprecated, equivalent to no restriction). |
Example Response
{
"name": "Contracts",
"lastModified": 1464285110000,
"uploaded": 1464285110000,
"path": "/Shared/Contracts",
"folder_id": "b6f42a4b-45f2-4e21-bab0-71f5b043f24d",
"parent_id": "a1e23b4c-56d7-8e90-fa12-34b5c6d7e8f9",
"folder_description": "This folder contains all of the contracts for our construction projects.",
"is_folder": true,
"allow_links": true,
"allow_upload_links": true,
"allowed_file_link_types": ["domain", "anyone"],
"allowed_folder_link_types": ["domain", "anyone"],
"public_links": "files_folders",
"restrict_move_delete": true,
"move_delete_folder_restriction": "admins_or_owners"
}
Error Codes
| Status | Error | Description | Resolution |
|---|---|---|---|
| 400 | FOLDER_DESCRIPTION_TOO_LONG | Folder description exceeds 200 characters | Reduce description length to 200 characters or fewer |
| 400 | Bad Request | Invalid value for public_links, move_delete_folder_restriction, or inheritance_rule | Use one of the allowed enum values |
| 400 | Bad Request | restrict_move_delete or move_delete_folder_restriction applied to a top-level folder in /Shared or /Private | These restrictions cannot be set on top-level folders |
| 400 | Bad Request | content_accessed set in email_preferences by a Standard User | Only Power Users and above can configure download notifications |
| 401 | Unauthorized | Invalid or missing authentication token | Ensure your token includes the Egnyte.launch scope and is valid |
| 403 | Forbidden | Insufficient permissions to modify workgroup folder settings | Verify the user has Admin or Modify permissions for this folder |
| 403 | Forbidden | Insufficient permissions to change public link settings | User must have Modify privilege on the folder and must not be a Standard User |
| 403 | Forbidden | Insufficient permissions to change upload link settings | Upload links must be enabled for the workgroup and the folder path must support upload links |
| 403 | Forbidden | Insufficient permissions to change folder description | User must have read-write-delete access; description cannot be changed on predefined folders |
| 403 | Forbidden | Insufficient permissions to change move/delete restriction | User must have Admin or Modify permissions for this folder |
| 404 | Not Found | Folder does not exist at the specified path | Verify the folder path is correct and the folder exists |
Code Examples
PATCH /pubapi/v1/fs/Shared/Contracts
curl -i -X PATCH "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/Contracts" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \ -d '{ "folder_description": "This folder contains all of the contracts for our construction projects.", "public_links": "files_folders", "move_delete_folder_restriction": "admins_or_owners", "allow_upload_links": true, "inheritance_rule": "this_folder_and_subfolders_until_overridden" }'
PATCH /pubapi/v1/fs/Shared/Contracts
curl -i -X PATCH "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/Contracts" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \ -d '{ "folder_description": "This folder contains all of the contracts for our construction projects.", "public_links": "files_folders", "move_delete_folder_restriction": "admins_or_owners", "allow_upload_links": true, "inheritance_rule": "this_folder_and_subfolders_until_overridden" }'
Related Resources
- File System Management API — Complete file and folder operations including listing, creating, and deleting
- Authentication — How to obtain and refresh OAuth tokens
- Links API — Create and manage file and folder links
