> For the complete documentation index, see [llms.txt](https://pondwadermc.gitbook.io/cubed-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pondwadermc.gitbook.io/cubed-api/documentation/files/delete.md).

# delete

**.delete(SessionID, path)**

Delete a file or folder in a servers file manager.

| Parameter | Type   | Required | Description                                            |
| --------- | ------ | -------- | ------------------------------------------------------ |
| SessionID | string | true     | The session ID that you want to perform this action on |
| path      | string | true     | The path of the file/folder you wish to delete         |

**Example:**

```javascript
// Dependencies
const CubedCraft = require('cubed-api');

// Deleting the file
CubedCraft.files.delete('SessionID', '/plugins/Skript/scripts/badskript.sk');
```

{% hint style="info" %}
Read the guide on session IDs: <https://pondwadermc.gitbook.io/cubed-api/tutorials-and-guides/sessions>
{% endhint %}
