Knowledge Base

Delete a record from the knowledge base.

Required permission:

WRITER or higher on the record's knowledge base. A READER is answered 403; a caller with no role, an unknown id and a record that is already in the trash are all answered 404. The query string and any request body are ignored.

What gets deleted:

  • Record metadata
  • Associated storage file
  • Indexed content and embeddings

Trash: With "Move Deleted Records to the Trash" on in Labs, the record goes to the trash instead: it disappears from search, chat and lists at once, its embeddings are removed, and the record and its file stay until the scheduled purge. The response then carries softDeleted: true and the batchId, and the record can be brought back with POST /knowledgeBase/record/{recordId}/restore. With the setting off, the delete is immediate and cannot be undone. A folder sent to the trash this way goes alone: the records inside it stay live and readable. DELETE /knowledgeBase/{kbId}/folder/{folderId} trashes a folder with its contents.

delete/knowledgeBase/record/{recordId}

Request

  • Base URL
    https://app.pipeshub.com/api/v1
  • URL
    https://app.pipeshub.com/api/v1/knowledgeBase/record/{recordId}
  • Auth
    • HTTP bearer
    • or OAuth 2
      Authorization code: /api/v1/oauth2/authorize
      Client credentials
      Token URL: /api/v1/oauth2/token scopes: kb:delete

Path parameters

recordIdstring required

Record ID

Response

Record deleted successfully

successtrue required
messagestring required
recordIdstring required
connectorstring nullable
timestampinteger nullable
softDeletedboolean

True when the record went to the trash instead of being removed

batchIdstring nullable

The delete batch; restoring any record in it restores all of it

vectorCleanupPendingboolean

The record is deleted, but removing its embeddings is still owed

vectorCleanupFailedRecordIdsstring[]
vectorCleanupFailedVirtualRecordIdsstring[]

Changes

    • info

      added the non-success response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status