Skip to main content
DELETE
/
api
/
knowledge-base
/
{documentation_id}
Delete Document
curl --request DELETE \
  --url https://api.example.com/api/knowledge-base/{documentation_id} \
  --header 'X-API-Key: <x-api-key>' \
  --header 'X-Organization-Id: <x-organization-id>'
{
  "success": true,
  "message": "Document 'Product Manual' deleted successfully"
}
Delete a knowledge base document. This removes it from storage and all agent attachments.
Cannot delete documents that are attached to agents. Detach first using the detach endpoint.

Headers

X-API-Key
string
required
Your API key for authentication.
X-Organization-Id
string
required
The organization ID.

Path Parameters

documentation_id
string
required
The unique identifier of the document to delete.

Permissions

  • kb:delete (admin, agent_manager)

Response

success
boolean
Indicates if the deletion was successful.
message
string
Human-readable success message.
{
  "success": true,
  "message": "Document 'Product Manual' deleted successfully"
}

Errors

404
object
Document not found.
403
object
Document belongs to different organization.
409
object
Cannot delete - document is attached to agents. Detach it first.