Skip to main content
POST
Delete a file

Authorizations

Authorization
string
header
required

Enter your API token or session token

Body

application/json

File deletion parameters

fileId
string
required
Minimum string length: 1
deleteFromR2
boolean
default:false

Also delete the file from R2 storage

Response

File deleted successfully

success
enum<boolean>
required
Available options:
true
data
object
required
requestId
string<uuid>
required

Unique request identifier for tracing

timestamp
string<date-time>
required

ISO timestamp when the response was generated

creditsCost
number

Credits consumed by this operation