API documentation
    API documentation
    • Back to home
    • File
    • List
      GET
    • Detail
      GET
    • Upload
      PUT
    • Update
      PUT
    • Download
      GET
    • Delete
      DELETE
    • Public Download
      GET
    • Share file with user
      PUT

      Delete

      DELETE
      https://api.everabyte.io/api/files/delete/k3pp2maludvi0mhw8oz0d05i
      This endpoint is used to delete a specific file.
      Endpoint: /files/delete/{fileId}
      Method: DELETE
      Path Parameters:
      fileId (required): The ID of the file to be deleted. Example: k3pp2maludvi0mhw8oz0d05i
      Request Body Parameters:
      {
        "trash": "soft" // or "hard"
      }
      trash (optional, string, default: "soft"): Specifies the type of deletion.
      "soft": Moves the folder to the trash (soft delete).
      "hard": Permanently deletes the folder (hard delete).
      Example Request (Soft Delete):
      DELETE /files/delete/k3pp2maludvi0mhw8oz0d05i
      Content-Type: application/json
      
      {
        "trash": "soft"
      }
      This request moves the folder with ID k3pp2maludvi0mhw8oz0d05i to the trash.
      Response Codes:
      200 OK: File successfully deleted.
      204 No Content: File successfully deleted (often used when no response body is needed).
      400 Bad Request: Invalid request parameters.
      404 Not Found: File not found.
      500 Internal Server Error: Server error.

      Request

      Authorization
      Provide your bearer token in the
      Authorization
      header when making requests to protected resources.
      Example:
      Authorization: Bearer ********************

      Request Code Samples

      Shell
      JavaScript
      Java
      Swift
      Go
      PHP
      Python
      HTTP
      C
      C#
      Objective-C
      Ruby
      OCaml
      Dart
      R
      Request Request Example
      Shell
      JavaScript
      Java
      Swift
      curl --location --request DELETE 'https://api.everabyte.io/api/files/delete/k3pp2maludvi0mhw8oz0d05i' \
      --header 'Authorization: Bearer <token>'

      Responses

      🟢200Success
      application/json
      Body

      Example
      {}
      Modified at 2025-07-29 17:18:04
      Previous
      Download
      Next
      Public Download
      Built with