Delete a collection and all its data.
This function ensures data consistency by attempting physical file deletion before database deletion. If physical deletion fails, the operation is aborted to prevent inconsistent state.
Args: collection_name: Name of the collection to delete
Returns: Deletion result with status, affected documents, and cleanup information
Raises: HTTPException: If physical deletion fails (prevents database deletion)
Documentation Index
Fetch the complete documentation index at: https://docs.xagent.run/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Successful Response
Response payload for collection-level management operations.
Operation status: success|partial_success|error
Collection identifier affected by the operation
Human-readable summary of the collection operation
Non-fatal issues encountered while processing the collection
Subset of documents impacted by the collection operation
Aggregated deletion counts per table when applicable