File System

The File System API lets you create, read, update, move, copy, delete, download, and list files and folders in an Egnyte domain. This is one of Egnyte's core APIs, as most integrations require basic file system operations.


Base URL

https://{domain}.egnyte.com/pubapi/v1/fs
https://{domain}.egnyte.com/pubapi/v1/fs-content

Authentication

All requests require an OAuth 2.0 Bearer token in the Authorization header:

Authorization: Bearer {access_token}

See Authentication for details on obtaining a token.


Important Notes

Note: File and folder paths must be URL-encoded segment by segment. Do not encode forward slashes (/). For example, Shared/example?path/$file.txt should be encoded as Shared/example%3Fpath/%24file.txt. See Path Encoding for details.

Note: You can reference files and folders using either paths or persistent IDs. See ID-Based References for details.

Note: For file uploads larger than 100 MB, use the Chunked Upload flow.


Path Encoding

Each segment of a file or folder path must be URL-encoded separately. Forward slashes (/) separating path segments must not be encoded.

Example:

  • Original path: Shared/example?path/$file.txt
  • Encoded path: Shared/example%3Fpath/%24file.txt

ID-Based References

You can reference files and folders using persistent IDs instead of paths.

Files

  • Get file details: /pubapi/v1/fs/ids/file/{GROUP_ID}
  • Download file: /pubapi/v1/fs-content/ids/file/{GROUP_ID}
  • Download specific version: /pubapi/v1/fs-content/ids/file/{GROUP_ID}?entry_id={ENTRY_ID}
  • Delete file: /pubapi/v1/fs/ids/file/{GROUP_ID}
  • Delete specific version: /pubapi/v1/fs/ids/file/{GROUP_ID}?entry_id={ENTRY_ID}

Folders

  • Get folder details: /pubapi/v1/fs/ids/folder/{FOLDER_ID}

Note: In the Event API response, entry_id is called target_id and group_id is called target_group_id.


Create a Folder

Creates a new folder at the specified path.

Request

POST /pubapi/v1/fs/{Full Path to Folder}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FolderstringYesFull path where the folder will be created (e.g., Shared/test)

Request Body

FieldTypeRequiredDescription
actionstringYesMust be add_folder

Example Request

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/test" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "add_folder"
}'

Response

200 OK or 201 Created

FieldTypeDescription
pathstringFull path of the created folder
folder_idstringUnique ID of the created folder

Example Response

{
  "path": "/Shared/test",
  "folder_id": "4abfdc36-2a1b-44b4-8792-01bf43c0d0f9"
}

Upload a File

Creates or updates a file at the specified path.

Note: For files larger than 100 MB, use the Chunked Upload flow.

Request

POST /pubapi/v1/fs-content/{Full Path to File}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FilestringYesFull path where the file will be uploaded (e.g., Shared/Documents/test.txt)

Request Headers

HeaderTypeRequiredDescription
X-Sha512-ChecksumstringNoSHA512 hash of the entire file for validating upload integrity
Last-ModifiedstringNoLast modified date for the file (e.g., Sun, 26 Aug 2012 03:55:29 GMT). If omitted, the current time is used.

Example Request

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs-content/Shared/Documents/test.txt" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Response

200 OK or 201 Created

Returns file metadata upon successful upload.


Move File or Folder

Moves a file or folder to a new location.

Request

By Path:

POST /pubapi/v1/fs/{Full Path to File/Folder}

By ID:

POST /pubapi/v1/fs/ids/{file or folder}/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to File/FolderstringYes (by path)Full path of the file or folder to move
file or folderstringYes (by ID)Literal string file or folder
IDstringYes (by ID)group_id for files or folder_id for folders

Request Body

FieldTypeRequiredDescription
actionstringYesMust be move
destinationstringYes (by path)Full absolute destination path
destination_idstringNoDestination ID
namestringNoMay be used with the destination ID in the ID based calls to provide the destination entity name.
permissionsstringNoHow permissions are derived: keep_original or inherit_from_parent. If omitted, uses workgroup settings.
folder_options_modestringNoHow folder options are handled: keep_source or apply_destination. If omitted, uses workgroup settings.

Example Request (File)

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/fromFolder/test.txt" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "move",
  "destination": "/Shared/toFolder/test.txt"
}'

Example Request (Folder)

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/fromFolder" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "move",
  "destination": "/Shared/toFolder"
}'

Response

200 OK

When moving a folder:

{
  "path": "/Shared/toFolder",
  "folder_id": "5919b927-13ef-4f74-a735-4dac2c4c6302"
}

When moving a file:

{
  "path": "/Shared/toFolder/sample.txt",
  "group_id": "8163f6a1-09e7-488c-b95f-094c9d75ff1b"
}

Copy File or Folder

Copies a file or folder to a new location.

Request

By Path:

POST /pubapi/v1/fs/{Full Path to File/Folder}

By ID:

POST /pubapi/v1/fs/ids/{file or folder}/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to File/FolderstringYes (by path)Full path of the file or folder to copy
file or folderstringYes (by ID)Literal string file or folder
IDstringYes (by ID)group_id for files or folder_id for folders

Request Body

FieldTypeRequiredDescription
actionstringYesMust be copy
destinationstringYes (by path)Full absolute destination path. If the destination does not include the original folder name, only the contents are copied.
destination_idstringNoDestination ID
namestringNoMay be used with the destination ID in the ID based calls to provide the destination entity name.
permissionsstringNoHow permissions are derived: keep_original or inherit_from_parent. If the destination folder already exists, its permissions are preserved. If omitted, uses workgroup settings.
folder_options_modestringNoHow folder options are handled: keep_source or apply_destination. If omitted, uses workgroup settings.

Example Request (File)

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/fromFolder/test.txt" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "copy",
  "destination": "/Shared/toFolder/test.txt"
}'

Example Request (Folder)

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/fromFolder" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "copy",
  "destination": "/Shared/toFolder",
  "permissions": "inherit_from_parent"
}'

Response

200 OK

When copying a file:

{
  "path": "/Shared/toFolder/test.txt",
  "group_id": "ac086094-d21f-44d7-9e54-ba7c7066542f"
}

When copying a folder:

{
  "path": "/Shared/toFolder",
  "folder_id": "5919b927-13ef-4f74-a735-4dac2c4c6302"
}

Delete a File or Folder

Deletes a file or folder (moves it to trash).

Request

By Path:

DELETE /pubapi/v1/fs/{Full Path to File/Folder}

By ID:

DELETE /pubapi/v1/fs/ids/{file or folder}/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to File/FolderstringYes (by path)Full path of the file or folder to delete
file or folderstringYes (by ID)Literal string file or folder
IDstringYes (by ID)group_id for files or folder_id for folders

Query Parameters

ParameterTypeRequiredDescription
entry_idstringNoEntry ID of a specific file version to delete

Example Request (File)

curl -i -X DELETE "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/test/mydocument.docx" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Example Request (Folder)

curl -i -X DELETE "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/test" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Response

200 OK

{
  "parent_folder_path": "/Shared/test"
}

Download File

Downloads a file. Supports range downloads for partial file retrieval.

Request

By Path:

GET /pubapi/v1/fs-content/{Full Path to File}

By ID:

GET /pubapi/v1/fs-content/ids/file/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FilestringYes (by path)Full path of the file to download
IDstringYes (by ID)group_id of the file

Query Parameters

ParameterTypeRequiredDescription
entry_idstringNoEntry ID of a specific file version to download

Request Headers

HeaderTypeRequiredDescription
RangestringNoByte range to download (e.g., bytes=0-999). Recommended for large files or unstable connections. See RFC 2068, section 14.36.1.
If-None-MatchstringNoWhen provided with a value that matches the ID of the latest version of the file, a response with HTTP 304 status is returned to indicate that the server content hasn't changed. This is used to prevent downloading the version that the client has already downloaded. See RFC 9110, section 13.1.2

Example Request

curl -i -X GET "https://{domain}.egnyte.com/pubapi/v1/fs-content/Shared/Documents/test.txt" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Response

200 OK or 206 Partial Content (for range requests)

Response Headers

HeaderTypeDescription
X-Sha512-ChecksumstringSHA512 hash of the entire file
Last-ModifiedstringLast modified date of the file
ETagstringEntity tag for version comparison
Content-TypestringMIME type of the file
Content-LengthintegerSize of the response body in bytes

Example Response

Binary file data.


List File or Folder

Lists information about a file or folder, including folder contents and file versions.

Request

By Path:

GET /pubapi/v1/fs/{Full Path to File/Folder}

By ID:

GET /pubapi/v1/fs/ids/{file or folder}/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to File/FolderstringYes (by path)Full path of the file or folder
file or folderstringYes (by ID)Literal string file or folder
IDstringYes (by ID)group_id for files or folder_id for folders

Query Parameters

ParameterTypeRequiredDefaultDescription
list_contentbooleanNofalseIf true, includes folder contents (files and subfolders) or file versions
allowed_link_typesbooleanNofalseIf true, includes allowed_file_link_types, allowed_folder_link_types, and allow_upload_links fields
countintegerNoMaximum number of items to return (for pagination)
offsetintegerNo0Zero-based index to start returning items (for pagination)
sort_bystringNoField to sort by: name, last_modified, uploaded_by, or custom_metadata
keystringNoCustom metadata field to sort by (format: namespace.key). Required if sort_by=custom_metadata.
sort_directionstringNoSort direction: ascending or descending
permsbooleanNofalseIf true, includes a permissions key listing users/groups and their permission levels
include_permbooleanNofalseIf true, includes the current user's permission level on the folder and subfolders
list_custom_metadatabooleanNofalseIf true, includes custom metadata for each item
include_locksbooleanNofalseIf true, includes lock information (user who locked the file)
include_collaborationbooleanNofalseIf true, includes collaboration app/integration information. Requires include_locks=true.

Example Request (Folder)

curl -i -X GET "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/MyDocuments/MyFolder" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Example Request (File)

curl -i -X GET "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/MyDocuments/example.txt" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Response

200 OK

Folder Response

FieldTypeDescription
namestringName of the folder
uploadedintegerEpoch timestamp (milliseconds) when the folder was created
lastModifiedintegerEpoch timestamp (milliseconds) of the latest file modification in the folder (not subfolders)
countintegerNumber of items returned in this response
offsetintegerZero-based index of the first item returned
pathstringFull path of the folder
folder_idstringUnique ID of the folder
parent_idstringUnique ID of the parent folder
total_countintegerTotal number of items available
is_folderbooleanAlways true for folders
permissionstringPermission level. One of Owner, Full, Editor, Viewer, Viewer Only (if include_perm=true)
permissionsobjectContains users and groups specific permissions applicable to this folder (if perms=true)
folder_descriptionstringDescription set for the folder using the web interface or the folder options API
public_linksstringPublic link setting: files_folders, folders, files, or disabled
allow_linksbooleanWhether users can share links from this folder
allow_upload_linksbooleanWhether users can share upload links to this folder
allowed_file_link_typesarrayList of links that are allowed for files: anyone, password, domain, recipients
allowed_folder_link_typesarrayList of links that are allowed for folders: anyone, password, domain, recipients
restrict_move_deletebooleantrue if only admins and owners can delete/move; false if users with full permissions can also delete/move
move_delete_folder_restrictionstringA value indicating who can move or delete this folder. - ADMINS_OWNERS_OR_FULL_ACCESS_USERS Admin users or users with owner or full permission - ADMINS_OR_OWNERS Admin users or users with owner permission - ADMINS_ONLY Admin users - FORBIDDEN Not permitted for any user
custom_metadataarrayList of objects (each object's key is the name of the metadata section, value is an object of {metadata key, value}). Also included for folders and files. (if list_custom_metadata=true)
foldersarrayList of subfolders (each contains name, lastModified, uploaded, path, folder_id, parent_id, is_folder)
filesarrayList of files (see File Response below)

Example Response (Folder)

{
  "name": "MyFolder",
  "lastModified": 1554182069000,
  "uploaded": 1554178564015,
  "count": 0,
  "offset": 0,
  "path": "/Shared/MyDocuments/MyFolder",
  "folder_id": "d7d56ebc-ce31-4ba8-a6b3-292ffb43f215",
  "parent_id": "b0sceebc-2edl-ab56-lapq-fb11def11123",
  "total_count": 2,
  "is_folder": true,
  "folder_description": "Sample documents related to G & A",
  "permission": "Owner",
  "permissions": {
    "users": [
      {
        "subject": "admin",
        "permission": "Owner"
      }
    ]
  },
  "public_links": "files_folders",
  "allowed_file_link_types": [
    "anyone",
    "password",
    "domain",
    "recipients"
  ],
  "allowed_folder_link_types": [
    "anyone",
    "password",
    "domain",
    "recipients"
  ],
  "allow_upload_links": true,
  "allow_links": true,
  "restrict_move_delete": false,
  "custom_metadata": [
    {
      "smart tags": {
        "aec image tags": "[\"Concrete\"]",
        "document topics": "[\"data center\"]"
      }
    }
  ],
  "folders": [
    {
      "name": "subfolder1",
      "lastModified": 1554185307000,
      "uploaded": 1554185307326,
      "path": "/Shared/MyDocuments/MyFolder/subfolder1",
      "folder_id": "fc8cf940-1097-491e-bb9d-b55b5797331c",
      "is_folder": true,
      "parent_id": "d7d56ebc-ce31-4ba8-a6b3-292ffb43f215"
    }
  ],
  "files": [
    {
      "checksum": "244b99790dcc91ebc5862eb547c8179515b2369bb6db5aaa1ddd46bf0035e7ba3849ba1494b294b20b7c2a055a52d3a65ccab8a090f06cf40106528f6e23a91e",
      "size": 238428,
      "path": "/Shared/MyDocuments/MyFolder/info.pdf",
      "name": "info.pdf",
      "locked": false,
      "is_folder": false,
      "entry_id": "b563a343-184b-4bce-8331-25d2dfb8125a",
      "group_id": "01dd4abd-983b-4104-bff6-e2ad44bff357",
      "parent_id": "d7d56ebc-ce31-4ba8-a6b3-292ffb43f215",
      "last_modified": "Tue, 02 Apr 2019 05:12:44 GMT",
      "uploaded_by": "jsmith",
      "uploaded": 1554182069464,
      "num_versions": 1
    }
  ]
}

File Response

FieldTypeDescription
checksumstringSHA512 checksum of the current file version
sizeintegerSize of the file in bytes
pathstringFull path of the file
namestringName of the file
lockedbooleantrue if the file is locked; false otherwise
is_folderbooleanAlways false for files
entry_idstringUnique ID of the current file version
group_idstringUnique ID of the file (across all versions)
parent_idstringUnique ID of the parent folder
last_modifiedstringLast modified date of the current version
uploaded_bystringUsername of the user who uploaded the current version
uploadedintegerEpoch timestamp (milliseconds) when the current version was uploaded
permissionstringPermission level. One of Owner, Full, Editor, Viewer, Viewer Only (if include_perm=true)
num_versionsintegerTotal number of versions of this file
versionsarrayList of previous file versions (excludes current version)
lock_infoobjectLock information (if include_locks=true)
custom_metadataarrayList of objects (each object's key is the name of the metadata section, value is an object of {metadata key, value}). Also included for versions. (if list_custom_metadata=true)

Example Response (File)

{
  "checksum": "32d919f9f96d6f8e92889e68eb2c9eb8079b2327d80a70e247a9c426f9fc5049a7a7978eb6f0ab6d129720b871637d8175e047199bcf77fe36d23d15e81886a8",
  "size": 1023,
  "path": "/Shared/MyDocuments/example.txt",
  "name": "example.txt",
  "locked": false,
  "is_folder": false,
  "entry_id": "a4e2857e-9cf4-492f-9087-0a8cee324e4c",
  "group_id": "765f70fd-122f-47ed-b50d-b5e80662596b",
  "parent_id": "b0sceebc-2edl-ab56-lapq-fb11def11123",
  "last_modified": "Tue, 02 Apr 2019 05:12:44 GMT",
  "uploaded_by": "jsmith",
  "uploaded": 1554182069464,
  "num_versions": 3,
  "custom_metadata": [
    {
      "document labels": {
        "policy labels": "important"
      }
    }
  ],
  "versions": [
    {
      "is_folder": false,
      "entry_id": "0ee550e4-854a-4ebc-a2d1-0de17714957f",
      "checksum": "2aca968ceb5452f797810a67ff283eb0b72dc334868c11f16e8cb9b8ab713e30f49a30245d16a9f187293b4971fd8a1d6c588d981799283ec1fbcc84c9fe44cb",
      "last_modified": "Fri, 29 Mar 2019 16:31:53 GMT",
      "uploaded_by": "mjohnson",
      "uploaded": 1554180282161,
      "size": 1378
    },
    {
      "is_folder": false,
      "entry_id": "1eb75cc1-af4f-4331-8e56-b2f7d1ebebe5",
      "checksum": "0a6a7ba5048971d4718da58ec0f9ba51a4bfc5691f11da4c0afa38244f474f7076bb6edf48d8bfb55bbbcf128c55918fbe96485ac1178e78ac2686a6fb4a0785",
      "last_modified": "Tue, 02 Apr 2019 04:50:14 GMT",
      "uploaded_by": "jsmith",
      "uploaded": 1554180634999,
      "size": 1108
    }
  ]
}

Get Folder Statistics

Retrieves folder size and item counts, including all files and subfolders.

Request

GET /pubapi/v1/fs/ids/folder/{FOLDER_ID}/stats

Path Parameters

ParameterTypeRequiredDescription
FOLDER_IDstringYesUnique ID of the folder

Example Request

curl -i -X GET "https://{domain}.egnyte.com/pubapi/v1/fs/ids/folder/{folderId}/stats" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Response

200 OK

FieldTypeDescription
allVersionsSizeintegerTotal size of all file versions in bytes
allFilesSizeintegerTotal size of all current file versions in bytes
filesCountintegerTotal number of files
fileVersionsCountintegerTotal number of file versions
foldersCountintegerTotal number of subfolders
allVersionsSizeInKBintegerTotal size of all file versions in kilobytes
allFilesSizeInKBintegerTotal size of all current file versions in kilobytes

Example Response

{
  "allVersionsSize": 1732505,
  "allFilesSize": 1721488,
  "filesCount": 10,
  "fileVersionsCount": 12,
  "foldersCount": 9,
  "allVersionsSizeInKB": 1691
}

Lock a File

Locks a file to prevent modifications by other users.

Request

By Path:

POST /pubapi/v1/fs/{Full Path to File}

By ID:

POST /pubapi/v1/fs/ids/file/{GROUP_ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FilestringYes (by path)Full path of the file to lock
GROUP_IDstringYes (by ID)group_id of the file

Request Body

FieldTypeRequiredDescription
actionstringYesMust be lock
lock_tokenstringNoToken required to unlock the file. If omitted, a random token is generated and returned.
lock_timeoutintegerNoLock duration in seconds. Default is 3600 (1 hour). Maximum is 604800 (7 days).
collaborationstringNoCollaboration token for UI Integration Framework apps (Base64-encoded)

Example Request

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/Documents/test.txt" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "lock",
  "lock_token": "my lock token",
  "lock_timeout": 7200
}'

Response

200 OK

Returns confirmation of the lock.


Unlock a File

Unlocks a previously locked file.

Request

By Path:

POST /pubapi/v1/fs/{Full Path to File}

By ID:

POST /pubapi/v1/fs/ids/file/{GROUP_ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FilestringYes (by path)Full path of the file to unlock
GROUP_IDstringYes (by ID)group_id of the file

Request Body

FieldTypeRequiredDescription
actionstringYesMust be unlock
lock_tokenstringYesToken used when locking the file

Example Request

curl -i -X POST "https://{domain}.egnyte.com/pubapi/v1/fs/Shared/Documents/test.txt" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
     -d '{
  "action": "unlock",
  "lock_token": "my lock token"
}'

Response

200 OK

Returns confirmation of the unlock.


Chunked Upload

Uploads large files in chunks. Recommended for files larger than 100 MB.

Chunked uploads use a dedicated fs-content-chunked endpoint, and each chunk is sent as the raw request body — not as multipart/form-data (unlike the simple upload endpoint above).

Request

By Path:

POST /pubapi/v1/fs-content-chunked/{Full Path to File}

By ID:

POST /pubapi/v1/fs-content-chunked/ids/file/{ID}

Path Parameters

ParameterTypeRequiredDescription
Full Path to FilestringYes (by path)Full path where the file will be uploaded
IDstringYes (by ID)group_id of the file

Chunked Upload Process

  1. Split the file into chunks:

    • Recommended chunk size: 104857600 bytes (100 MB)
    • Minimum chunk size: 10485760 bytes (10 MB)
    • Maximum chunk size: 1073741824 bytes (1 GB)
    • All chunks must be the same size, except the last chunk
  2. Upload the first chunk:

    • Include the X-Egnyte-Chunk-Num: 1 header
    • Include the X-Egnyte-Chunk-Sha512-Checksum header with the SHA512 hash of the chunk
    • Save the X-Egnyte-Upload-Id from the response
  3. Upload remaining chunks (except the last):

    • Include the X-Egnyte-Upload-Id header from step 2
    • Include the X-Egnyte-Chunk-Num header with the chunk number
    • Include the X-Egnyte-Chunk-Sha512-Checksum header
    • Upload chunks in parallel for maximum throughput
  4. Upload the final chunk:

    • Include the X-Egnyte-Last-Chunk: true header
    • Include the X-Sha512-Checksum header with the composite whole-file checksum in the format {Version}-{NumChunks}-{ChunkSize}-{SHA512(Concatenated Chunk Checksums)} (see Calculating the Final Checksum). A plain SHA512 of the file bytes is rejected with a checksum mismatch.
    • Optionally include the Last-Modified header
  5. Chunks expire after 24 hours from the first chunk upload.

Request Headers

Common Headers (All Chunks)

HeaderTypeRequiredDescription
X-Egnyte-Chunk-NumintegerYesChunk number (starts at 1)
X-Egnyte-Chunk-Sha512-ChecksumstringYesSHA512 hash of the chunk data

First Chunk Only

No additional headers required.

Subsequent Chunks (Not Last)

HeaderTypeRequiredDescription
X-Egnyte-Upload-IdstringYesUpload ID returned from the first chunk

Last Chunk Only

HeaderTypeRequiredDescription
X-Egnyte-Upload-IdstringYesUpload ID returned from the first chunk
X-Egnyte-Last-ChunkbooleanYesMust be true
X-Sha512-ChecksumstringNoComposite whole-file checksum: {Version}-{NumChunks}-{ChunkSize}-{SHA512(Concatenated Chunk Checksums)}not a plain SHA512 of the file bytes
Last-ModifiedstringNoLast modified date (e.g., Sun, 26 Aug 2012 03:55:29 GMT)

Response Headers

HeaderTypeDescription
X-Egnyte-Upload-IdstringUpload ID (returned after first chunk)
X-Egnyte-Chunk-NumintegerChunk number that was uploaded
X-Egnyte-Chunk-Sha512-ChecksumstringSHA512 hash of the chunk (for validation)

Final Response (After Last Chunk)

200 OK

Returns a checksum in the format:

{Version}-{NumChunks}-{ChunkSize}-{SHA512(Concatenated Chunk Checksums)}

Example:

2-3-10485761-41e3a616682407fd721ef2843ac5f3966c73ae2ef0bc00fc3d8c27d69327fc3d326ce64b13163cbc7664be3e1bc1a9f8bf4c1d257fdfdab20919edbc6813f30f
  • Version: Checksum format version (currently 2)
  • NumChunks: Total number of chunks
  • ChunkSize: Size of each chunk (except the last)
  • SHA512(Concatenated Chunk Checksums): SHA512 hash of the concatenated chunk checksums

Calculating the Final Checksum

To verify the upload, compute the SHA512 hash of the concatenated chunk checksums.

Example (Bash):

CHECKSUM1="886a81ec5f9e4f66aaa77d95ccb58dc6ca4000bfb12d13351adf8cd6fb09933e0e16d057983eb8a81fffc71d71f6fc5c1649d08b20b0dc30d64ea449850b4f41"
CHECKSUM2="8ae7b487d9ad803e0ad85dee9320a1c3203f021e2fffe07573588e2869f097589eaa97923d75ada6f84a5eaeb7ad63f7f0a0ddc1e78053f570b8a6363abcd9f3"
CHECKSUM3="eef77c3e9fef9277e0a3bbc8a4faaf2727481296b3d6e0143c5c661d2cd1441eeccc54d4bc086c29ea3ee918a79dcba122bd077fe3232f30f54afc7ed452cc8d"

echo -n $CHECKSUM1$CHECKSUM2$CHECKSUM3 | openssl dgst -sha512

Example (Python):

import hashlib

m = hashlib.sha512()
m.update("886a81ec5f9e4f66aaa77d95ccb58dc6ca4000bfb12d13351adf8cd6fb09933e0e16d057983eb8a81fffc71d71f6fc5c1649d08b20b0dc30d64ea449850b4f41")
m.update("8ae7b487d9ad803e0ad85dee9320a1c3203f021e2fffe07573588e2869f097589eaa97923d75ada6f84a5eaeb7ad63f7f0a0ddc1e78053f570b8a6363abcd9f3")
m.update("eef77c3e9fef9277e0a3bbc8a4faaf2727481296b3d6e0143c5c661d2cd1441eeccc54d4bc086c29ea3ee918a79dcba122bd077fe3232f30f54afc7ed452cc8d")
print(m.hexdigest())

Expected Result:

41e3a616682407fd721ef2843ac5f3966c73ae2ef0bc00fc3d8c27d69327fc3d326ce64b13163cbc7664be3e1bc1a9f8bf4c1d257fdfdab20919edbc6813f30f

Error Codes

StatusErrorDescriptionResolution
400Bad RequestMissing parameters, file filtered out (e.g., .tmp file), or file exceeds plan size limitVerify request parameters and file type; check account storage quota
401UnauthorizedInvalid or expired OAuth tokenRefresh your OAuth token
403ForbiddenInsufficient permissions or forbidden upload location (e.g., /, /Shared, /Private)Ensure the user has the required permissions; verify the upload path is valid
404Not FoundFile or folder does not existVerify the file or folder path or ID
409ConflictFile or folder with the same name already exists, or forbidden upload locationChoose a different name or location
413Payload Too LargeFile size exceeds account limit or storage quota exceededReduce file size or upgrade account storage
429Rate LimitedToo many requestsImplement exponential backoff; check Retry-After header

Reference →Browse all endpoints