Skip to main content
DELETE
Delete a file

Overview

Deletes a file immediately. A batch that has already read an input file keeps running; deleting an output file makes its results unrecoverable. Files you leave alone are deleted on their own at expires_at.

Authorizations

Authorization
string
header
required

Morph API key, passed as Authorization: Bearer sk-.... Create keys at https://www.morphllm.com/dashboard/api-keys.

Path Parameters

file_id
string
required

Identifies the file to delete. The file_ prefixed id of the file to remove.

Example:

"file_9c2c1c3e-5b6a-4f0e-8d0f-2a1b3c4d5e6f"

Response

The file was deleted.

Confirmation that a file and its content are gone.

id
string
required

Id of the file that was deleted.

Example:

"file_9c2c1c3e-5b6a-4f0e-8d0f-2a1b3c4d5e6f"

object
string
required

Always file, even on a deletion receipt.

Example:

"file"

deleted
boolean
required

Always true on success.

Example:

true