Delete File

Permanently delete a file, its embeddings, and chat history.

DELETE /api/v1/files/{file_id}

Permanently deletes a file from your library, including its vector embeddings and associated chat history. This action cannot be undone.

Headers

Name
Type
Description

Authorization*

string

Bearer YOUR_API_TOKEN

Path Parameters

Name
Type
Description

file_id*

string

The UUID of the file to delete

Responses

{
  "message": "File deleted successfully"
}

Examples

import requests

file_id = "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
url = f"https://api.knowbase.ai/api/v1/files/{file_id}"
headers = {"Authorization": "Bearer YOUR_API_TOKEN"}

response = requests.delete(url, headers=headers)
print(response.json())

Last updated