Create folder
Creates a directory on the disk
- Parameters
- Advanced call ?
Function CreateFolder(Val Token, Val Path) Export
| Parameter | CLI option | Type | Required | Description |
|---|---|---|---|---|
| Token | --token | String | ✔ | Token |
| Path | --path | String | ✔ | Path to the created folder |
Returns
Map Of KeyAndValue - serialized JSON response from Yandex
| Parameter | Description |
|---|---|
| proxy | InternetProxy or a structure with fields Protocol, Host, Port, User, Password, UseOSAuthentication |
| timeout | Request execution timeout |
| adv_response | Formats the response as a complete HTTP structure with fields code, body, and headers |
| retries | Number of HTTP request send attempts on 5** status codes or internal client errors |
| dontwait | Creates a background job and returns its data (for 1C and OneScript only) |
1C:Enterprise/OneScript code example
Token = "y0__xCOranuBRj1uTsgs8z_iRV...";
Path = "/" + String(New UUID);
Result = OPI_YandexDisk.CreateFolder(Token, Path);
- Bash
- CMD/Bat
oint yadisk CreateFolder \
--token "***" \
--path "/9d9119e5-b131-45b3-8bfd-d4ef2dd8c47c"
oint yadisk CreateFolder ^
--token "***" ^
--path "/9d9119e5-b131-45b3-8bfd-d4ef2dd8c47c"
Result
{
"path": "disk:/9d9119e5-b131-45b3-8bfd-d4ef2dd8c47c",
"type": "dir",
"name": "9d9119e5-b131-45b3-8bfd-d4ef2dd8c47c",
"created": "2026-05-26T13:58:34+00:00",
"modified": "2026-05-26T13:58:34+00:00",
"_embedded": {
"path": "disk:/9d9119e5-b131-45b3-8bfd-d4ef2dd8c47c",
"limit": 20,
"offset": 0,
"sort": "",
"total": 0,
"items": []
},
"resource_id": "1573541518:fa568632a008a64923acfb6e3b4b4ab3461b91b4d3fe7cdb8169d83e30500aea",
"revision": 1779803914875845,
"comment_ids": {
"public_resource": "1573541518:fa568632a008a64923acfb6e3b4b4ab3461b91b4d3fe7cdb8169d83e30500aea",
"private_resource": "1573541518:fa568632a008a64923acfb6e3b4b4ab3461b91b4d3fe7cdb8169d83e30500aea"
},
"exif": {}
}