Knowledge Bases

Remove files from a knowledge base

Removes one or more files and the chunks indexed from them, so their content stops being retrieved. Cleanup runs in the background. Removing a file that has already been removed succeeds without doing anything.

delete/knowledge-bases/{kb_id}/files

Request

  • Base URL: https://console.hyperstack.cloud/ai/api/v1
  • URL: https://console.hyperstack.cloud/ai/api/v1/knowledge-bases/{kb_id}/files
  • Auth: API key in header api_key

Path parameters

kb_idinteger required

Numeric ID of the knowledge base. Call the List knowledge bases API to retrieve the id of an existing knowledge base.

Request body

file_idsinteger[] required

IDs of the files to remove. Call the Retrieve a knowledge base API to retrieve the id of an existing file.

Response

The files were marked for deletion.

statusstring

Always success when the request is accepted.

messagestring

Confirmation that the files were marked for deletion.

Changes

No recorded changes to this operation across all 1 revision of this API.