> ## Documentation Index
> Fetch the complete documentation index at: https://docs.drime.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete Entries

> Move entries to trash or delete permanently

## Overview

Deletes one or more file entries. By default, entries are moved to trash. Use `deleteForever: true` to permanently delete.

<Warning>
  Permanent deletion cannot be undone. Use with caution.
</Warning>

## Request Body

<ParamField body="entryIds" type="array" required>
  Array of entry IDs to delete
</ParamField>

<ParamField body="deleteForever" type="boolean" default="false">
  When true, permanently delete instead of moving to trash
</ParamField>

<ParamField body="emptyTrash" type="boolean" default="false">
  When true with empty entryIds, permanently deletes all items in trash
</ParamField>

## Response

<ResponseField name="status" type="string">
  Request status (`success`)
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  # Move to trash
  curl -X POST https://app.drime.cloud/api/v1/file-entries/delete \
    -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "entryIds": [123, 456],
      "deleteForever": false
    }'

  # Permanently delete
  curl -X POST https://app.drime.cloud/api/v1/file-entries/delete \
    -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "entryIds": [123, 456],
      "deleteForever": true
    }'

  # Empty trash
  curl -X POST https://app.drime.cloud/api/v1/file-entries/delete \
    -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "entryIds": [],
      "emptyTrash": true
    }'
  ```

  ```javascript JavaScript theme={null}
  // Move to trash
  const response = await fetch('https://app.drime.cloud/api/v1/file-entries/delete', {
    method: 'POST',
    headers: {
      'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      entryIds: [123, 456],
      deleteForever: false
    })
  });

  // Empty entire trash
  const emptyTrash = await fetch('https://app.drime.cloud/api/v1/file-entries/delete', {
    method: 'POST',
    headers: {
      'Authorization': 'Bearer YOUR_ACCESS_TOKEN',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      entryIds: [],
      emptyTrash: true
    })
  });
  ```

  ```python Python theme={null}
  import requests

  # Move to trash
  response = requests.post(
      'https://app.drime.cloud/api/v1/file-entries/delete',
      headers={'Authorization': 'Bearer YOUR_ACCESS_TOKEN'},
      json={
          'entryIds': [123, 456],
          'deleteForever': False
      }
  )

  # Empty trash
  response = requests.post(
      'https://app.drime.cloud/api/v1/file-entries/delete',
      headers={'Authorization': 'Bearer YOUR_ACCESS_TOKEN'},
      json={
          'entryIds': [],
          'emptyTrash': True
      }
  )
  ```
</RequestExample>

<ResponseExample>
  ```json 200 - Success theme={null}
  {
    "status": "success"
  }
  ```
</ResponseExample>
