Bulk file initialization from body IDs. This operation is necessary to complete multiple download of files via links or gettible multiple file download links.
Accepts data list for file creation. The data must include the file body ID, its name, and the ID of the directory where it will be saved.
Returns a list of structures containing the resulting file and a description of any error that occurred during the file’s initialization. The order of structures in the response corresponds to the order of files in the request.

Request

POST /pub/v1/disk/files

Request body

The resource sent in the request body is  Bulk file initialization — Request. It contains the following writable properties:

{
    "files": [
        {
            "comment": "string",
            "directory": "uuid",
            "hash": "uuid",
            "name": "string"
        }
    ]
}

Properties

Name Type Description Additional
files[] array

List of data to create files

Optional
files[].comment string

Comment to the file

Optional
files[].directory uuid

Directory where the file is placed

files[].hash uuid

Storage ID of the file body

files[].name string

File name

Authorization

This request requires the use of one of following authorisation methods: API key

Response

The following HTTP status codes may be returned:

Status code Description Resource
200 OK

Model of the response for bulk file initialization

Model of the response for bulk file initialization (Bulk file initialization)
422

Model of the response for bulk file initialization

Model of the response for bulk file initialization (Bulk file initialization)