Loading file to the directory
Uploading a file to the directory specified in the ID.
The file will be placed to the required directory, make sure you have enough disk space. If there already is a file with the same name in the directory, a prefix with a number will be added it it's name: (1), etc.
To upload the file, generate uuid and pass it as a unique hash value for the file's body.
To upload the entire file, use the Content-Range header with the following value: bytes 0-[size]\/[size] (for example, bytes 0-1000/1000).
You can also upload the file by parts. To do that, divide the file into equal parts of 5 MB minimum each. The last part can be of any size.
The size of each such part must be between 5 MB (5 242 880 byte) and 5 GB (5 368 709 120 byte).
Header template: bytes [range-start]-[range-end]\/[size] (for example, bytes 0-5242880/7340032 to upload the first part of 5 MB for a 7 MB file, and bytes 5242880-7340032/7340032 to upload the second part of this file).
File body ID
This request requires the use of one of following authorisation methods:
The following HTTP status codes may be returned.
The file has been loaded
The part of the file has been loaded
The error is shown as a message that describes the problem. The error message may contain the following codes: EntityTooSmall if the file is divided into parts that are too smal; InvalidPart is one of the parts was not found in storage; InvalidPartOrder if the order of the parts in the file is invalid; NoSuchUpload if the upload was not found.
Not enough disk space
No access permissions for creating a file
Server response after the file is uploaded to the directory
|Server response after the file is uploaded to the directory (Loading file to the directory)|