Skip to content

Delete a file

DELETE/v5/files/{file_id}

Delete a file by id, removing its database record.

This is a hard delete: the file’s row is removed from the database, not soft-archived. The underlying stored object is deleted only when no other file record still references the same stored content (identical checksum and MIME type); when another record shares the blob, the blob is retained. If the id refers to an incomplete multipart upload placeholder, its staged parts are aborted instead. Returns a confirmation carrying the deleted file’s id.

Path ParametersExpand Collapse
file_id: string
Header ParametersExpand Collapse
"x-project-id": optional string
ReturnsExpand Collapse
id: string
deleted: boolean
object: optional "file"

Delete a file

curl https://api.egp.scale.com/v5/files/$FILE_ID \
    -X DELETE \
    -H "x-api-key: $SGP_API_KEY"
{
  "id": "id",
  "deleted": true,
  "object": "file"
}
Returns Examples
{
  "id": "id",
  "deleted": true,
  "object": "file"
}