1
0
Fork 0
mirror of synced 2024-09-30 09:18:14 +13:00

create-file doc with info for chunk upload

This commit is contained in:
Damodar Lohani 2021-07-08 17:11:24 +05:45
parent fc96625fd5
commit c0d204a9a4

View file

@ -1 +1,5 @@
Create a new file. The user who creates the file will automatically be assigned to read and write access unless he has passed custom values for read and write arguments.
Create a new file. The user who creates the file will automatically be assigned to read and write access unless he has passed custom values for read and write arguments.
Large file should be uploaded using multiple requests using [content-range](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Range) header to send partial request with maximum supported chunk of `2MB`. We assume that the chunk size is the chunk size used in the firs request. We assume that in `content-range` header the **range-start**, **range-end** and **size** always sent and unit is always bytes.
When first request is sent the server sends back the **File** object, and the subsequent part request must include the file's **id** in `x-appwrite-upload-id` header for the server to know the partial upload is for existing file not a new file.