1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2024-12-21 01:50:24 +02:00
OpenIntegrations/docs/en/md/Yandex_Disk/File-and-folder-management/Delete-object.md
2024-06-05 13:35:05 +03:00

45 lines
873 B
Markdown

---
sidebar_position: 4
---
# Delete object
Deletes an object at the specified path
*Function DeleteObject(Val Token, Val Path, Val ToCart = True) Export*
| Parameter | CLI option | Type | Destination |
|-|-|-|-|
| Token | --token | String | Token |
| Path | --path | String | Path to the folder or file to be deleted |
| ToCart | --can | Boolean | To cart |
Returns: Key-Value Pair - serialized JSON response from Yandex
```bsl title="Code example"
Token = "y0_AgAAAABdylaOAA...";
Path = "/Alpaca.png"
Response = OPI_YandexDisk.DeleteObject(Token, Path); //Map
Response = OPI_Tools.JSONString(Response); //String
```
```sh title="CLI command example"
oint yadisk DeleteObject --token "y0_AgAAAABdylaOAA..." --path "/Alpaca.png" --can %can%
```
```json title="Result"
<empty string>
```