Skip to main content

đŸ—‘ī¸ Delete File

Delete a Walrus-backed file using its file ID. The id is the UUID returned for each file in the List Files API response — it is not the same as the file CID.

Walrus storage & DataCap

Deleting a file stops Walrus from renewing storage for that blob. Your DataCap does not become available immediately it is reclaimed automatically once the file's current storage period expires.

API​

curl -X DELETE \
-H 'Authorization: Bearer API_KEY' \
'https://api.lighthouse.storage/api/user/delete_file_walrus?id=382cef6d-994e-41db-9acb-1540574dcf0e'

Sample response:

{
"message": "File deleted successfully"
}

Replace the id query parameter with the id field from the file you want to delete in the fileList returned by files_uploaded?fileType=walrus.

Note: Once deleted, the file cannot be recovered.