Delete a source

delete a source from a knowledge base.

DELETE https://api.centerfy.ai/webhooks/inbound/knowledge-bases/:id/sources/:sourceId

Headers

HeaderRequiredValueDescription
x-api-keyYesyour sub-account API key (cfy_…)Authenticates the request; or Authorization: Bearer <key>.

Path parameters

NameTypeRequiredDescription
idstring (uuid)YesThe knowledge base id.
sourceIdstring (uuid)YesThe source id to delete — either a file/URL source or a text/FAQ source belonging to this knowledge base; you need not know which kind.

Example

curl -X DELETE "https://api.centerfy.ai/webhooks/inbound/knowledge-bases/{id}/sources/{sourceId}" \
  -H "x-api-key: $CENTERFY_API_KEY"
import { CenterfyClient } from "@centerfy/sdk";

const centerfy = new CenterfyClient({ apiKey: process.env.CENTERFY_API_KEY! });

const result = await centerfy.knowledgeBases.deleteSource("<knowledgeBaseId>", "<sourceId>");
console.log(result);
centerfy knowledgeBases delete-source <knowledgeBaseId> <sourceId>

MCP tool: centerfy_knowledge_bases_delete_source (see MCP server)

Response

{
  "status": "success",
  "deleted": true,
  "knowledge_base_id": "<knowledge_base_id>",
  "source_id": "<source_id>",
  "source_kind": "document",
  "vectors_removed": 42
}

Errors

  • 200 — on success.

Notes

Removes the source’s vectors from the vector store (best-effort), deletes any associated file, and removes the source. source_kind is ‘document’ or ‘text_entry’. Errors: 400 (invalid knowledge base id or invalid source id), 401 (unauthenticated), 404 (knowledge base not found, or source not found in this knowledge base), 500 (delete error).

© 2026 Centerfy AI. All rights reserved.