Update a file
File service supports modifications to file attributes with file versioning.
The attributes are updated using a PATCH request and passing the attributes you want to change in the body.
The file content is updated by creating a new minor version. The version is an updated file that is referenced as the current file version. Other versions are stored in File service for reference.
Prerequisites
Section titled “Prerequisites”- A file should be created. To know more about uploading a file refer here
Request
Section titled “Request”Using the update file by ID API Call to change file attributes:
PATCH {baseUrl}/spaces/{spaceId}/files/{fileId}-
HEADER:
- Authorization:
Bearer {tid token}
- Authorization:
-
BODY:
acl- Access control list for the filemetadata- Metadata for the file
You cannot change the public/private status on an existing file. To change the status, upload a new version using the restricted_access parameter.
Response
Section titled “Response”To know more about the update file API refer here.