mkdir
To create a new folder in the file storage, use the file/mkdir method:
svc=file/mkdir¶ms={"itemId":<long>,
"storageType":<uint>,
"path":<text>}
Parameters
| Parameter | Description |
|---|---|
| itemId | Item ID |
| storageType | Storage type: 1 — public (all users can see and download files), 2 — protected (only users with access rights can see and download files). |
| path | Relative path from the root folder to the folder you want to create. |
Response
If the request is completed successfully, an empty response is returned:
{ }
If the request hasn’t been completed, an error code is returned.
Error codes
| Code | Description |
|---|---|
| 1 | User not authorized. |
| 4 | Invalid input parameters. |
| 5 | Failed to create a folder at the specified path. |
| 7 | Insufficient rights to the item specified in the itemId parameter. |